# atlisp-cli **Repository Path**: atlisp/atlisp-cli ## Basic Information - **Project Name**: atlisp-cli - **Description**: atlisp 命令行工具 - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2026-07-14 - **Last Updated**: 2026-07-14 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # @atlisp/cli — @lisp 命令行工具 在 AutoCAD、ZWCAD、GStarCAD、BricsCAD 中管理 AutoLISP 包、构建内核、运行测试的命令行工具。 ## 安装 ```sh npm install -g @atlisp/cli ``` ## 用法 ```sh atlisp <命令> [参数] ``` ### 包管理 | 命令 | 说明 | |------|------| | `atlisp install` | 安装 @lisp Core 到 CAD | | `atlisp pull <包名>` | 安装一个包 | | `atlisp remove <包名>` | 卸载一个包 | | `atlisp list` | 列出本地包 | | `atlisp search <关键词>` | 搜索远程包 | ### 内核开发 | 命令 | 说明 | |------|------| | `atlisp build` | 构建 `@lisp_u.lsp`(需要 `ATLISP_KERNEL_SRC`) | | `atlisp build-module <名>` | 构建单个模块 | | `atlisp watch` | 监听源文件变更自动构建 | | `atlisp lint` | AutoLISP 代码检查 | | `atlisp test` | 在 SBCL 中运行语法测试 | | `atlisp test --platform cad` | 在 CAD 中运行测试(需 CAD + MCP) | | `atlisp init --template module <名>` | 创建新模块脚手架 | ### 配置与诊断 | 命令 | 说明 | |------|------| | `atlisp config list` | 查看配置 | | `atlisp config set ` | 设置配置 | | `atlisp login` | 登录 atlisp.cn | | `atlisp doctor` | 环境诊断 | | `atlisp check` | CAD 连接检查 | ### 工具 | 命令 | 说明 | |------|------| | `atlisp batch --path --expr ` | 批量 DWG 处理 | | `atlisp find --name ` | 在 DWG 中搜索元素 | | `atlisp qrcode ` | 生成 QR 码 | | `atlisp dcl-migrate ` | 转换 DCL 到 DSL 格式 | ## 环境变量 | 变量 | 说明 | 默认值 | |------|------|--------| | `ATLISP_KERNEL_SRC` | 内核源码目录 | `~/atlisp/kernel/src` | | `ATLISP_KERNEL_TEST` | 内核测试目录 | `~/atlisp/kernel/test` | | `ATLISP_KERNEL_ROOT` | 内核根目录 | `~/atlisp/kernel` | ## 开发 ```sh git clone https://gitee.com/atlisp/atlisp-cli.git cd atlisp-cli npm install npm test # 运行 Jest 测试 node atlisp.js # 交互模式 ``` ## 从 kernel 仓库迁移 `@atlisp/cli` 原来位于 `atlisp/kernel/tools/cli/atlisp/`。现已独立为单独项目。 迁移后,kernel 仓库不再自带 CLI 工具,但可通过以下方式使用: 1. **全局安装**:`npm install -g @atlisp/cli` 2. **npx 直接使用**:`npx @atlisp/cli build` 3. **原位使用**:kernel 仓库的 Makefile 会自动探测可用方式 ## 许可证 ISC