新增: - backend/venv/ - Python 虚拟环境 - backend/start.sh - 启动脚本(使用虚拟环境) - backend/requirements.txt - 依赖列表 - .gitignore - 忽略虚拟环境和缓存文件 说明: - 每个项目使用独立虚拟环境 - 避免依赖冲突 - 启动脚本自动创建和激活虚拟环境
29 lines
832 B
TypeScript
29 lines
832 B
TypeScript
export = address;
|
|
|
|
declare interface Address {
|
|
ip: string;
|
|
ipv6: string;
|
|
mac: string;
|
|
}
|
|
|
|
declare type AddressCallback = (err: Error, addr: Address) => void;
|
|
declare type MacCallback = (err: Error, addr: string) => void;
|
|
declare type DnsCallback = (err: Error, servers: string[]) => void;
|
|
|
|
declare function address(interfaceName: string, callback: AddressCallback): void;
|
|
declare function address(callback: AddressCallback): void;
|
|
|
|
declare namespace address {
|
|
const MAC_IP_RE: RegExp;
|
|
const MAC_RE: RegExp;
|
|
|
|
function dns(filepath: string, callback: DnsCallback): void;
|
|
function dns(callback: DnsCallback): void;
|
|
|
|
function ip(interfaceName?: string): any;
|
|
function ipv6(interfaceName?: string): any;
|
|
|
|
function mac(interfaceName: string, callback: MacCallback): void;
|
|
function mac(callback: MacCallback): void;
|
|
}
|