aptly 0.1.13 → 0.1.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bin/aptly.js +5 -2
- package/dist/src/cli-help.js +2 -2
- package/dist/src/doctor.d.ts +3 -0
- package/dist/src/doctor.js +26 -7
- package/dist/src/files.js +2 -2
- package/dist/src/setup.d.ts +1 -0
- package/dist/src/setup.js +93 -21
- package/dist/src/stable-runtime.d.ts +61 -0
- package/dist/src/stable-runtime.js +694 -0
- package/dist/src/version.d.ts +1 -1
- package/dist/src/version.js +1 -1
- package/docs/guide/en/configuration.md +24 -0
- package/docs/guide/ja/configuration.md +24 -0
- package/docs/guide/ko/configuration.md +24 -0
- package/docs/guide/zh-CN/configuration.md +24 -0
- package/package.json +1 -1
package/dist/src/version.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare const VERSION = "0.1.
|
|
1
|
+
export declare const VERSION = "0.1.14";
|
package/dist/src/version.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.1.
|
|
1
|
+
export const VERSION = '0.1.14';
|
|
@@ -16,6 +16,7 @@ For manual MCP configuration, see [Advanced integration](advanced.md#guide-manua
|
|
|
16
16
|
- [Configure with the CLI](#guide-cli-configuration)
|
|
17
17
|
- [Keys and restarting](#guide-keys-and-restart)
|
|
18
18
|
- [Models and environment variables](#guide-models-and-environment)
|
|
19
|
+
- [Node-version-independent launcher](#guide-stable-launcher)
|
|
19
20
|
|
|
20
21
|
<a id="guide-host-config-locations"></a>
|
|
21
22
|
|
|
@@ -66,6 +67,29 @@ A store timeout or malformed acknowledgement may occur after the OS has written
|
|
|
66
67
|
|
|
67
68
|
Restart MCP, then inspect `provider`, candidates, and `credential_status` with `get_routing_capabilities`. `os_store` means a key was loaded, not that the API authenticated it. Default and public-variable setup continue to preserve custom wrappers. API-key setup does not change host settings for an unverified launch path and restores that host's previous key where possible if storage was already attempted. Do not assume a new key automatically takes effect through an existing wrapper. These commands do not bypass Codex `/hooks` trust or host permissions.
|
|
68
69
|
|
|
70
|
+
<a id="guide-stable-launcher"></a>
|
|
71
|
+
|
|
72
|
+
## Node-version-independent launcher
|
|
73
|
+
|
|
74
|
+
This option is available starting with 0.1.14. Explicit `--launcher stable` on POSIX (macOS/Linux) preserves an executable and Aptly runtime dependencies in private storage outside versioned Node directories. It does not copy Node: an installed supported Node.js 24+ is still required. After the original Node and npm package directory disappear, the preserved launcher can locate another supported installation. Bare `node` cannot offer that guarantee when a GUI host lacks it in PATH.
|
|
75
|
+
|
|
76
|
+
Default/automatic and existing registrations keep direct Node paths. Use `aptly setup --client all --launcher stable` only for new registrations. For existing ones, inspect then migrate explicitly as below. Use `--client claude` for Claude and select the intended `CODEX_HOME` for each Codex account.
|
|
77
|
+
|
|
78
|
+
```sh
|
|
79
|
+
aptly setup --client codex --migrate-launcher --launcher stable --dry-run
|
|
80
|
+
aptly setup --client codex --migrate-launcher --launcher stable
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
Add `--include-existing` only after reviewing an eligible preserved standard launcher. Modified/custom launchers and statistics Hooks are never adopted automatically. Migration updates owned MCP and observer targets together, preserving collection state, native metadata consent, keys, policies, ledgers and statistics history. Review new Codex Hooks with `/hooks`; trust is never approved automatically.
|
|
84
|
+
|
|
85
|
+
Resolution tries the installer Node, standard locations, numeric release directories in the default `~/.nvm/versions/node`, then safe absolute PATH entries. It does not promise the newest Node; symlink/shim-based managers may be rejected even with PATH; only qualified real executable paths are supported. No shell profile, npm or network download runs at startup. Stable mode deliberately removes `NODE_OPTIONS`, `NODE_PATH` and `NODE_REPL_EXTERNAL_MODULE` to avoid inheriting common Node startup overrides; use separate certificate settings such as `NODE_EXTRA_CA_CERTS` when needed. Runtime closures requiring native addons are refused. Missing runtime or failed integrity stops MCP with a fixed error; observers stay silent and best-effort.
|
|
86
|
+
|
|
87
|
+
Normal global npm installations are the primary supported source. Redirected/writable ancestors and dependencies hoisted outside a local package cannot be verified and are refused. Windows retains direct mode and rejects the stable option. Stable mode remains sticky across later setup/migration without the flag. Run `aptly update` from the actual global npm CLI; explicitly migrate to select a new Aptly snapshot. Remove retains old/shared snapshots because other homes or running processes may still use them. Doctor observes snapshot metadata, not full execution, authentication or reload readiness.
|
|
88
|
+
|
|
89
|
+
Plain setup does not silently replace an existing snapshot. Older selected versions report `stable_snapshot_outdated` and explicit migration guidance. An exact-owned stable reference can explicitly migrate from a missing, damaged or older-format snapshot to verified source from the current CLI. A corrupt same-generation directory or incomplete lock is never overwritten/deleted automatically: inspect only that state after checking writers and other homes. Modified/custom registration is not adopted as product-owned.
|
|
90
|
+
|
|
91
|
+
Stable migration updates owned observers together; legacy direct-to-direct migration may still need separate observer refresh (`statistics_observer_migration_required`). Full snapshot checks during setup and startup add I/O overhead. Bounded runtime probes do not provide a hard wall-clock bound for all filesystem operations. This is not a sandbox against same-user programs or worker threads.
|
|
92
|
+
|
|
69
93
|
<a id="guide-keys-and-restart"></a>
|
|
70
94
|
|
|
71
95
|
## Keys and restarting
|
|
@@ -16,6 +16,7 @@ MCP の手動設定は[高度な連携](advanced.md#guide-manual-mcp-setup)を
|
|
|
16
16
|
- [CLI による設定](#guide-cli-configuration)
|
|
17
17
|
- [キーと再起動](#guide-keys-and-restart)
|
|
18
18
|
- [モデルと環境変数](#guide-models-and-environment)
|
|
19
|
+
- [Node のバージョンディレクトリに依存しないランチャー](#guide-stable-launcher)
|
|
19
20
|
|
|
20
21
|
<a id="guide-host-config-locations"></a>
|
|
21
22
|
|
|
@@ -66,6 +67,29 @@ API キーは macOS Keychain、インストール済みの Linux `secret-tool`
|
|
|
66
67
|
|
|
67
68
|
変更後は MCP を再起動し、`get_routing_capabilities` の `provider`、候補、`credential_status` を確認してください。`os_store` はキーを読み込めたことを示し、API 認証の成功を示すものではありません。デフォルト設定と公開変数の設定では、引き続き独自ラッパーを保持します。API キー設定は未確認の起動パスのホスト設定を変更せず、保存を試みていた場合は可能な限りそのホストの旧キーを復元します。既存のラッパーにも新しいキーが自動で適用されるとは想定しないでください。Codex の `/hooks` 信頼承認やホスト権限は迂回しません。
|
|
68
69
|
|
|
70
|
+
<a id="guide-stable-launcher"></a>
|
|
71
|
+
|
|
72
|
+
## Node のバージョンディレクトリに依存しないランチャー
|
|
73
|
+
|
|
74
|
+
このオプションは 0.1.14 以降で使用できます。POSIX(macOS/Linux)で `--launcher stable` を明示すると、Node のバージョンディレクトリ外の非公開領域にランチャーと Aptly の実行時依存を保存します。Node 自体はコピーしないため、対応する Node.js 24 以上のインストールが必要です。元の Node と npm パッケージが削除されても、保存済みランチャーは別の対応 Node を探せます。GUI ホストの PATH に `node` がない場合、コマンド名だけでは同じ保証は得られません。
|
|
75
|
+
|
|
76
|
+
既定・自動登録と既存登録は直接 Node パスを使います。新規登録には `aptly setup --client all --launcher stable` を使えます。既存登録は次のとおり確認後に明示して移行してください。Claude は `--client claude`、各 Codex アカウントは対象の `CODEX_HOME` で実行します。
|
|
77
|
+
|
|
78
|
+
```sh
|
|
79
|
+
aptly setup --client codex --migrate-launcher --launcher stable --dry-run
|
|
80
|
+
aptly setup --client codex --migrate-launcher --launcher stable
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
保持済みの標準ランチャーを含める場合は、確認後に `--include-existing` を追加してください。独自・変更済みランチャーや統計 Hook は自動で引き取りません。所有する MCP と観測器の実行先を同時に更新し、収集状態・native メタデータへの同意・キー・ポリシー・台帳・統計履歴を保持します。Codex の新 Hook は `/hooks` で再確認し、信頼を承認してください。自動承認は行いません。
|
|
84
|
+
|
|
85
|
+
インストール時 Node、標準パス、既定の `~/.nvm/versions/node` 内の正式版、安全な絶対 PATHを順に試します。最新 Node の選択は保証せず、シンボリックリンクや shim を使う管理方式は PATH 内でも拒否される場合があり、検証できる実際の実行ファイルパスのみ対応します。起動時にシェル設定・npm・ネットワークダウンロードは実行しません。stable モードは一般的な Node 起動設定の継承を抑えるため `NODE_OPTIONS`・`NODE_PATH`・`NODE_REPL_EXTERNAL_MODULE` を継承しません。追加 CA が必要な場合は `NODE_EXTRA_CA_CERTS` など別の証明書設定を利用してください。ネイティブアドオンが必要な依存は拒否します。対応ランタイム不在・整合性エラー時の MCP は固定エラーで停止し、観測器は既存の静かな best-effort 動作を維持します。
|
|
86
|
+
|
|
87
|
+
通常の npm グローバルインストールを主に対象とします。リダイレクト・書き込み可能な上位パスや、ローカルパッケージ外に hoist された依存などは検証できないため拒否します。Windows は直接モードを維持し stable は未対応です。stable 登録は後続のオプションなし setup/migration でも維持します。`aptly update` は実際の npm グローバル CLI で実行し、明示的な移行で新しい Aptly 副本を選択してください。他のホームや実行中プロセスのため、`remove` は古い共有副本を削除しません。`doctor` の副本メタデータ観測は、実行・認証・再読み込み完了の証明ではありません。
|
|
88
|
+
|
|
89
|
+
通常の setup は既存副本を暗黙に置き換えません。CLI より古い副本は `stable_snapshot_outdated` と明示的な移行案内を返します。所有権が完全に一致する stable 参照なら、副本の欠落・破損・旧形式から現在の CLI の検証済みソースへ明示的に移行できます。同じ generation の破損や未完了 lock は自動で上書き・削除しません。書き込みプロセスと他ホームの参照を確認し、その状態だけを手動で見直してください。独自・変更済み登録を製品所有として引き取りません。
|
|
90
|
+
|
|
91
|
+
stable 移行は所有観測器も同時に更新しますが、従来の直接モード間の移行では別途統計観測器の更新が必要な場合があります(`statistics_observer_migration_required`)。setup と起動の整合性確認には I/O 負荷があり、探索制限は全ファイルシステム操作の経過時間上限を保証しません。同じユーザーのプログラムやワーカースレッドを隔離する sandbox ではありません。
|
|
92
|
+
|
|
69
93
|
<a id="guide-keys-and-restart"></a>
|
|
70
94
|
|
|
71
95
|
## キーと再起動
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
- [CLI로 설정하기](#guide-cli-configuration)
|
|
17
17
|
- [키와 재시작](#guide-keys-and-restart)
|
|
18
18
|
- [모델과 환경변수](#guide-models-and-environment)
|
|
19
|
+
- [Node 버전 변경에 강한 실행기](#guide-stable-launcher)
|
|
19
20
|
|
|
20
21
|
<a id="guide-host-config-locations"></a>
|
|
21
22
|
|
|
@@ -66,6 +67,29 @@ API 키는 macOS Keychain, Linux의 설치된 `secret-tool`, 또는 Windows Cred
|
|
|
66
67
|
|
|
67
68
|
변경 후 MCP를 재시작하고 `get_routing_capabilities`의 `provider`, 후보 목록, `credential_status`를 확인하십시오. `os_store`는 저장소에서 키를 읽었다는 뜻이며 API 유효성 검증은 아닙니다. 기본 설정과 일반 변수 설정은 기존 사용자 지정 래퍼를 보존합니다. API 키 설정은 호환성이 확인되지 않은 실행 경로의 호스트 설정을 변경하지 않으며, 이미 저장을 시도했다면 해당 호스트의 이전 키를 가능한 경우 복원합니다. 새 키가 기존 래퍼에도 자동 적용된다고 가정하지 마십시오. 명령은 Codex의 `/hooks` 신뢰 승인이나 호스트 권한을 우회하지 않습니다.
|
|
68
69
|
|
|
70
|
+
<a id="guide-stable-launcher"></a>
|
|
71
|
+
|
|
72
|
+
## Node 버전 변경에 강한 실행기
|
|
73
|
+
|
|
74
|
+
이 옵션은 0.1.14부터 지원합니다. POSIX(macOS·Linux)에서 `--launcher stable`을 명시하면 Node 버전 폴더 밖의 비공개 위치에 실행기와 Aptly의 런타임 의존성을 보존합니다. Node 바이너리는 복사하지 않으므로 지원되는 Node.js 24 이상 설치본이 필요합니다. 기존 Node와 원본 npm 패키지 폴더가 삭제돼도 보존된 실행기는 다른 지원 설치본을 찾을 수 있습니다. 단순한 `node` 명령은 GUI 호스트의 PATH에 없을 수 있어 같은 보장을 하지 않습니다.
|
|
75
|
+
|
|
76
|
+
기본 설치·자동 등록과 기존 등록은 계속 직접 Node 경로를 사용합니다. 새 등록에만 `aptly setup --client all --launcher stable`을 사용할 수 있습니다. 기존 등록은 아래처럼 먼저 점검한 후 명시적으로 전환하십시오. Claude는 `--client claude`를 사용하고, 계정별 Codex는 의도한 `CODEX_HOME` 환경에서 실행하십시오.
|
|
77
|
+
|
|
78
|
+
```sh
|
|
79
|
+
aptly setup --client codex --migrate-launcher --launcher stable --dry-run
|
|
80
|
+
aptly setup --client codex --migrate-launcher --launcher stable
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
기존에 보존한 표준 실행기를 포함하려면 검토 후 `--include-existing`을 추가하십시오. 사용자 정의·수정된 실행기나 통계 Hook은 자동 채택하지 않습니다. 전환은 소유한 MCP와 통계 관찰자 경로를 함께 갱신하며 수집 여부·native 메타데이터 동의·키·정책·원장·통계 이력을 유지합니다. Codex의 새 Hook은 `/hooks`에서 다시 검토하고 승인하십시오.
|
|
84
|
+
|
|
85
|
+
실행기는 설치 시 Node, 표준 경로, 기본 `~/.nvm/versions/node`의 정식 버전, 안전한 절대 PATH 순으로 지원 런타임을 탐색합니다. 최신 Node의 자동 선택을 보장하지 않으며 심볼릭 링크나 shim을 쓰는 버전 관리자는 PATH에 있어도 거부될 수 있으며, 검증 가능한 실제 실행 파일 경로만 지원합니다. 셸 프로필·npm·네트워크 다운로드는 실행하지 않습니다. stable 모드는 흔한 Node 옵션 상속을 차단하기 위해 `NODE_OPTIONS`·`NODE_PATH`·`NODE_REPL_EXTERNAL_MODULE`을 상속하지 않습니다. CA 추가가 필요하면 기존 `NODE_EXTRA_CA_CERTS` 등 별도 인증서 설정을 사용하십시오. 네이티브 애드온이 필요한 런타임 묶음은 거부합니다. 런타임 부재/무결성 실패 시 MCP는 고정 오류로 중단하고 통계 관찰자는 기존 best-effort 계약대로 조용히 종료합니다.
|
|
86
|
+
|
|
87
|
+
이 기능은 일반 npm 전역 설치를 우선 지원합니다. 리다이렉트·쓰기 가능한 상위 경로와 외부로 hoist된 로컬 의존성 등 검증할 수 없는 소스는 거부합니다. Windows는 기존 직접 실행을 유지하며 stable 옵션은 지원하지 않습니다. stable 등록은 플래그 없는 후속 설정·마이그레이션에서도 유지됩니다. `aptly update`는 실제 npm 전역 CLI에서 실행하고, 새 Aptly 버전은 마이그레이션 명령으로 새 사본을 선택하십시오. 기존 사본은 다른 홈과 실행 중 프로세스가 사용할 수 있으므로 `remove`가 자동 삭제하지 않습니다. `doctor`의 사본 메타데이터 관측은 전체 실행·인증·재로딩 검증이 아닙니다.
|
|
88
|
+
|
|
89
|
+
일반 `setup`은 기존 사본을 자동 교체하지 않습니다. CLI보다 오래된 사본은 `stable_snapshot_outdated`와 명시적 마이그레이션 안내로 구분합니다. 소유권이 정확히 일치하는 기존 stable 등록은 사본이 유실·손상되거나 이전 실행기 형식이어도 새 CLI의 검증된 소스로 명시 전환할 수 있습니다. 같은 generation이 손상됐거나 미완료 lock이 남았다면 자동으로 덮어쓰거나 삭제하지 않습니다. 쓰기 프로세스와 다른 홈의 참조를 확인한 후 해당 상태만 수동 검토하십시오. 사용자 정의·변경된 등록의 소유권을 새로 채택하지 않습니다.
|
|
90
|
+
|
|
91
|
+
stable 전환은 소유 통계 Hook을 함께 갱신하지만 기존 직접 Node 런처 간 마이그레이션은 종전처럼 별도 통계 갱신이 필요할 수 있습니다(`statistics_observer_migration_required`). 설치·전환 시의 전체 사본 검증과 각 실행의 무결성 확인은 I/O 지연을 추가할 수 있으며, 런타임 탐색 제한이 전체 파일시스템의 벽시계 제한을 보장하지는 않습니다. 같은 사용자 권한의 프로그램이나 작업자 스레드를 격리하는 보안 sandbox는 아닙니다.
|
|
92
|
+
|
|
69
93
|
<a id="guide-keys-and-restart"></a>
|
|
70
94
|
|
|
71
95
|
## 키와 재시작
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
- [使用 CLI 设置](#guide-cli-configuration)
|
|
17
17
|
- [密钥与重启](#guide-keys-and-restart)
|
|
18
18
|
- [模型与环境变量](#guide-models-and-environment)
|
|
19
|
+
- [不依赖 Node 版本目录的启动器](#guide-stable-launcher)
|
|
19
20
|
|
|
20
21
|
<a id="guide-host-config-locations"></a>
|
|
21
22
|
|
|
@@ -66,6 +67,29 @@ API 密钥通过 macOS Keychain、已安装的 Linux `secret-tool` 或 Windows C
|
|
|
66
67
|
|
|
67
68
|
修改后请重启 MCP,并通过 `get_routing_capabilities` 查看 `provider`、候选和 `credential_status`。`os_store` 仅表示读到了密钥,不代表 API 已通过认证。默认设置和公开变量设置仍会保留自定义包装程序。API 密钥设置不会修改未经确认的启动路径所对应的宿主设置;如果已尝试保存,则会在可能时恢复该宿主的旧密钥。不要假定新密钥会通过现有包装程序自动生效。命令不会绕过 Codex 的 `/hooks` 信任批准或宿主权限。
|
|
68
69
|
|
|
70
|
+
<a id="guide-stable-launcher"></a>
|
|
71
|
+
|
|
72
|
+
## 不依赖 Node 版本目录的启动器
|
|
73
|
+
|
|
74
|
+
此选项自 0.1.14 起可用。在 POSIX(macOS/Linux)上显式指定 `--launcher stable`,会将启动器与 Aptly 运行时依赖保存在 Node 版本目录之外的私有位置。它不复制 Node,因此仍须安装受支持的 Node.js 24 以上版本。旧 Node 和原 npm 软件包目录被删除后,保留的启动器可寻找其他受支持安装。GUI 宿主的 PATH 可能没有 `node`,仅改成命令名无法提供相同保证。
|
|
75
|
+
|
|
76
|
+
默认安装、自动注册及既有注册仍使用直接 Node 路径。新注册可使用 `aptly setup --client all --launcher stable`;既有注册请先检查,再显式迁移。Claude 使用 `--client claude`,各 Codex 账号须选择正确的 `CODEX_HOME`。
|
|
77
|
+
|
|
78
|
+
```sh
|
|
79
|
+
aptly setup --client codex --migrate-launcher --launcher stable --dry-run
|
|
80
|
+
aptly setup --client codex --migrate-launcher --launcher stable
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
仅在审核符合条件的既有标准启动器后添加 `--include-existing`。不会自动接管自定义或已修改的启动器及统计 Hook。迁移同时更新 Aptly 所有的 MCP 和观察器目标,保留收集状态、native 元数据同意、密钥、策略、账本和统计历史。请在 Codex `/hooks` 重新审核新 Hook,不会自动批准信任。
|
|
84
|
+
|
|
85
|
+
依次尝试安装时 Node、标准路径、默认 `~/.nvm/versions/node` 中的正式版本及安全的绝对 PATH 项。不保证选择最新 Node;使用符号链接或 shim 的版本管理器即使在 PATH 中也可能被拒绝,仅支持可验证的实际可执行路径。启动时不加载 shell 配置、不运行 npm,也不下载网络内容。stable 模式主动移除 `NODE_OPTIONS`、`NODE_PATH` 和 `NODE_REPL_EXTERNAL_MODULE` 以避免继承常见 Node 启动覆盖设置;需要额外 CA 时请使用 `NODE_EXTRA_CA_CERTS` 等独立证书设置。需要原生扩展的运行时依赖会被拒绝。运行时缺失或完整性失败时 MCP 返回固定错误,统计观察器则保持静默的 best-effort 行为。
|
|
86
|
+
|
|
87
|
+
主要支持普通 npm 全局安装。重定向或可写的上级路径,以及本地软件包外被 hoist 的依赖等不可验证来源会被拒绝。Windows 保留直接模式,不支持 stable。后续不带选项的 setup/migration 保留 stable 模式。请使用实际 npm 全局 CLI 执行 `aptly update`,再显式迁移以选择新 Aptly 副本。`remove` 不自动删除其他主目录或进程仍可能使用的副本。`doctor` 仅观测副本元数据,不证明实际执行、认证或重载就绪。
|
|
88
|
+
|
|
89
|
+
普通 setup 不会静默替换既有副本。比 CLI 更旧的选定副本会报告 `stable_snapshot_outdated` 并提供显式迁移说明。所有权完全匹配的 stable 引用可从缺失、损坏或旧格式副本显式迁移到当前 CLI 的已验证来源。同代副本损坏或残留未完成 lock 时,不会自动覆盖或删除;请先检查写入者及其他主目录引用,再手动审核对应状态。不会将自定义或已修改的注册接管为产品所有。
|
|
90
|
+
|
|
91
|
+
stable 迁移同时更新所属观察器;既有直接模式之间的迁移仍可能需要另行刷新统计观察器(`statistics_observer_migration_required`)。setup 与启动的完整性检查会增加 I/O 开销,受限探测不保证全部文件系统操作的总墙钟时限。这不是隔离同用户程序或工作线程的安全 sandbox。
|
|
92
|
+
|
|
69
93
|
<a id="guide-keys-and-restart"></a>
|
|
70
94
|
|
|
71
95
|
## 密钥与重启
|