# ember-zli 中文文档

规范地址：https://npmcn.com/package/ember-zli/

版本：6\.1\.0
npm 元数据更新时间：2026-11-03T12:03:24.113Z
中文译文更新时间：2026-11-03T14:13:52.876Z
软件包许可：GPL-3\.0-or-later

本文由上游 README 机器翻译，可能存在偏差，请结合原文核对 API、命令与配置。版权与许可归原作者所有。

原始 npm 页面：https://www.npmjs.com/package/ember-zli
原文对照：https://npmcn.com/package/ember-zli/?lang=original
项目主页：https://github.com/Nerivec/ember-zli
源码仓库：https://github.com/Nerivec/ember-zli

## 关键信息（来自 npm 元数据）

- 包体积（解压后）：286 kB，48 个文件
- 模块格式：ES Module
- TypeScript 类型：包内自带
- Node.js 要求：^22\.22\.0 \|\| ^24\.12\.0 \|\| \<=26\.2\.0
- 运行依赖：10 个
- 首次发布：2024-05-20T18:24:11.878Z
- 最新版本发布：2026-11-03T12:03:23.254Z
- 已发布版本数：64（近 12 个月 15 个）

## 中文简介

使用zigbee-herdsman ‘ember’驱动程序与基于emberznet的适配器交互

## 安装

```sh
npm install ember-zli
```

也可以使用：`pnpm add ember-zli`、`yarn add ember-zli`、`bun add ember-zli`

## README

# 安贝ZLI

使用zigbee-herdsman ‘ember’驱动程序与基于emberznet的适配器交互。还支持从CPC和Spinel协议引导加载。

[![oclif](https://img.shields.io/badge/cli-oclif-brightgreen.svg)](https://oclif.io/) [![Version](https://img.shields.io/npm/v/ember-zli.svg)](https://npmjs.org/package/ember-zli) [![Downloads](https://img.shields.io/npm/dt/ember-zli.svg)](https://npmjs.org/package/ember-zli) [![ci](https://github.com/Nerivec/ember-zli/actions/workflows/ci.yml/badge.svg)](https://github.com/Nerivec/ember-zli/actions/workflows/ci.yml)

> \[!重要的) `ember-zli` 使用 `ember` 司机从 [zigbee-herdsman](https://github.com/Koenkk/zigbee-herdsman) 在引擎盖下面。因此，它的固件需求与 [Zigbee2MQTT灰烬](https://www.zigbee2mqtt.io/guide/adapters/emberznet.html);7.4固件。x最低。

### 可用的交互式菜单

看到 [https://github.com/Nerivec/ember-zli/wiki](https://github.com/Nerivec/ember-zli/wiki)

# ToC

-   [ToC](https://npmcn.com/package/ember-zli/#readme-toc)
-   [用法](https://npmcn.com/package/ember-zli/#readme-usage)
-   [命令](https://npmcn.com/package/ember-zli/#readme-commands)

# 用法

```sh-session
$ npm install -g ember-zli
$ ember-zli COMMAND
running command...
$ ember-zli (--version)
ember-zli/6.1.0 linux-x64 node-v24.22.1
$ ember-zli --help [COMMAND]
USAGE
  $ ember-zli COMMAND
...
```

# 命令

-   [`ember-zli bootloader`](https://npmcn.com/package/ember-zli/#readme-ember-zli-bootloader)
-   [`ember-zli help [COMMAND]`](https://npmcn.com/package/ember-zli/#readme-ember-zli-help-command)
-   [`ember-zli monitor`](https://npmcn.com/package/ember-zli/#readme-ember-zli-monitor)
-   [`ember-zli router`](https://npmcn.com/package/ember-zli/#readme-ember-zli-router)
-   [`ember-zli sniff`](https://npmcn.com/package/ember-zli/#readme-ember-zli-sniff)
-   [`ember-zli stack`](https://npmcn.com/package/ember-zli/#readme-ember-zli-stack)
-   [`ember-zli utils`](https://npmcn.com/package/ember-zli/#readme-ember-zli-utils)
-   [`ember-zli version`](https://npmcn.com/package/ember-zli/#readme-ember-zli-version)

## `ember-zli bootloader`

与适配器中的Gecko引导加载程序交互。

```
USAGE
  $ ember-zli bootloader

DESCRIPTION
  Interact with the Gecko bootloader in the adapter.

EXAMPLES
  $ ember-zli bootloader
```

_看代码: [src /命令/引导装载程序/ index.ts](https://github.com/Nerivec/ember-zli/blob/v6.1.0/src/commands/bootloader/index.ts)_

## `ember-zli help [COMMAND]`

显示ember-zli的帮助。

```
USAGE
  $ ember-zli help [COMMAND...] [-n]

ARGUMENTS
  [COMMAND...]  Command to show help for.

FLAGS
  -n, --nested-commands  Include all nested commands in the output.

DESCRIPTION
  Display help for ember-zli.
```

_看代码: [@oclif / plugin-help](https://github.com/oclif/plugin-help/blob/7.0.6/src/commands/help.ts)_

## `ember-zli monitor`

在控制台中监视所选端口。

```
USAGE
  $ ember-zli monitor

DESCRIPTION
  Monitor the chosen port in the console.

EXAMPLES
  $ ember-zli monitor
```

_看代码: [src /命令/监控/ index.ts](https://github.com/Nerivec/ember-zli/blob/v6.1.0/src/commands/monitor/index.ts)_

## `ember-zli router`

使用协调器固件作为路由器，并与已加入的网络进行交互。

```
USAGE
  $ ember-zli router

DESCRIPTION
  Use a coordinator firmware as a router and interact with the joined network.

EXAMPLES
  $ ember-zli router
```

_看代码: [src /命令/路由器/ index.ts](https://github.com/Nerivec/ember-zli/blob/v6.1.0/src/commands/router/index.ts)_

## `ember-zli sniff`

嗅探Zigbee流量（到Wireshark，到PCAP文件，到自定义处理程序或只是记录原始数据）。

```
USAGE
  $ ember-zli sniff

DESCRIPTION
  Sniff Zigbee traffic (to Wireshark, to PCAP file, to custom handler or just log raw data).

EXAMPLES
  $ ember-zli sniff
```

_看代码: [src /命令/闻/ index.ts](https://github.com/Nerivec/ember-zli/blob/v6.1.0/src/commands/sniff/index.ts)_

## `ember-zli stack`

与适配器中的EmberZNet堆栈交互。

```
USAGE
  $ ember-zli stack

DESCRIPTION
  Interact with the EmberZNet stack in the adapter.

EXAMPLES
  $ ember-zli stack
```

_看代码: [src /命令/栈/ index.ts](https://github.com/Nerivec/ember-zli/blob/v6.1.0/src/commands/stack/index.ts)_

## `ember-zli utils`

执行各种实用程序命令。

```
USAGE
  $ ember-zli utils

DESCRIPTION
  Execute various utility commands.

EXAMPLES
  $ ember-zli utils
```

_看代码: [src /命令/ index.ts跑龙套](https://github.com/Nerivec/ember-zli/blob/v6.1.0/src/commands/utils/index.ts)_

## `ember-zli version`

```
USAGE
  $ ember-zli version [--json] [--verbose]

FLAGS
  --verbose  Show additional information about the CLI.

GLOBAL FLAGS
  --json  Format output as json.

FLAG DESCRIPTIONS
  --verbose  Show additional information about the CLI.

    Additionally shows the architecture, node version, operating system, and versions of plugins that the CLI is using.
```

_看代码: [@oclif /扩展的版本](https://github.com/oclif/plugin-version/blob/3.0.7/src/commands/version.ts)_

## 常见问题

### ember-zli 是什么？

使用zigbee-herdsman ‘ember’驱动程序与基于emberznet的适配器交互

### 如何安装 ember-zli？

在项目目录运行 npm install ember-zli，或使用 pnpm add / yarn add / bun add。它还提供命令行工具 ember-zli，可以用 npx ember-zli 直接运行。

### ember-zli 支持 TypeScript 吗？

支持。包内自带 TypeScript 类型声明（package\.json 声明了 types 入口），安装后即可获得类型提示，无需再安装 @types 包。

### ember-zli 支持 ESM 还是 CommonJS？

以 ES Module 形式发布，推荐使用 import 引入。在 CommonJS 项目中，Node\.js 20\.19\+ / 22\.12\+ 可以直接 require\(\) 不含顶层 await 的 ES Module，更早的版本需要改用动态 import\(\)。

### ember-zli 需要什么版本的 Node\.js？

package\.json 的 engines 字段要求 Node\.js ^22\.22\.0 \|\| ^24\.12\.0 \|\| \<=26\.2\.0。版本不符时 npm 默认只给出警告，开启 engine-strict 后会拒绝安装。

### ember-zli 可以商用吗？

ember-zli 使用 GPL-3\.0-or-later 许可。强 Copyleft：分发包含该代码的软件时，整个作品需以 GPL-3\.0 兼容许可开源，并附带专利与反锁定条款。仅内部使用不触发此义务。以上为概括，不构成法律意见，请以许可原文为准。

### ember-zli 还在维护吗？

最新版本 6\.1\.0 发布于 2026/11/03（今天）；至今共发布 64 个版本，其中过去 12 个月发布了 15 个；首次发布于 2024/05/21。发布频率只是参考信号：功能稳定的工具可能很少需要更新，建议结合源码仓库的 issue 和提交记录判断。

