cli: remove insomnia-pod binary output
This commit is contained in:
@@ -103,7 +103,7 @@ permission = "write"
|
||||
|
||||
通常の Pod 起動は Lua profile discovery/default から `PodManifest` を生成する。bundled `builtin:default` が fallback default で、user/project `profiles.toml` は profile registry と default selection だけを担う。user/project `manifest.toml` の ambient cascade は通常起動では使わない。
|
||||
|
||||
`insomnia-pod --manifest <PATH>` は explicit one-file compatibility/debug input で、指定 TOML 1 枚だけに builtin defaults を merge し、`PodManifestConfig -> PodManifest` の required validation を通す。
|
||||
`insomnia pod --manifest <PATH>` は explicit one-file compatibility/debug input で、指定 TOML 1 枚だけに builtin defaults を merge し、`PodManifestConfig -> PodManifest` の required validation を通す。
|
||||
|
||||
`PodFactory` の user/project/overlay API は低レベル構成部品として残るが、CLI の通常起動 path では generic TOML overlay を公開しない。
|
||||
|
||||
|
||||
@@ -26,14 +26,14 @@ return profile {
|
||||
Run an explicit path with:
|
||||
|
||||
```sh
|
||||
insomnia-pod --profile ./coder.lua
|
||||
insomnia pod --profile ./coder.lua
|
||||
# or through the TUI fresh-spawn dialog
|
||||
insomnia --profile ./coder.lua
|
||||
```
|
||||
|
||||
`--profile` accepts an explicit path, `path:<path>`, a discovered profile name, `default`, or a source-qualified name such as `project:coder`, `user:coder`, or `builtin:coder`. Path-like values containing `/`, starting with `.`, or ending in `.lua` are explicit paths. ``.nix` paths are no longer supported as profiles and fail with a diagnostic that points users at Lua profiles or `--manifest`.
|
||||
|
||||
`--profile` conflicts with `insomnia-pod --manifest` and with restore/session/adopt modes. Use `--profile-pod-name <name>` when a launcher needs a creation-time Pod name override without invoking `--pod` restore semantics. Profile evaluation is a creation-time path; Pod resume restores saved Pod state/resolved snapshots rather than re-evaluating the profile source.
|
||||
`--profile` conflicts with `insomnia pod --manifest` and with restore/session/adopt modes. Use `--profile-pod-name <name>` when a launcher needs a creation-time Pod name override without invoking `--pod` restore semantics. Profile evaluation is a creation-time path; Pod resume restores saved Pod state/resolved snapshots rather than re-evaluating the profile source.
|
||||
|
||||
## Controlled Lua environment
|
||||
|
||||
@@ -81,7 +81,7 @@ The fresh-spawn TUI also uses discovery. The new Pod dialog defaults to the sele
|
||||
|
||||
## One-file manifests
|
||||
|
||||
`insomnia-pod --manifest <PATH>` remains as an explicit compatibility/debug path. It reads exactly that TOML file, resolves relative paths against the file's parent directory, merges builtin defaults, and validates through the same `PodManifestConfig -> PodManifest` boundary as profile artifacts. It does not load user or project `manifest.toml` files and conflicts with `--profile`.
|
||||
`insomnia pod --manifest <PATH>` remains as an explicit compatibility/debug path. It reads exactly that TOML file, resolves relative paths against the file's parent directory, merges builtin defaults, and validates through the same `PodManifestConfig -> PodManifest` boundary as profile artifacts. It does not load user or project `manifest.toml` files and conflicts with `--profile`.
|
||||
|
||||
Ambient user/project `manifest.toml` cascade startup has been removed. Normal fresh spawns use profile discovery/default selection, with `profiles.toml` acting only as a profile registry/default selector.
|
||||
|
||||
|
||||
+1
-1
@@ -5,7 +5,7 @@
|
||||
#
|
||||
# このファイル形式は低レベル runtime manifest。通常起動は profile discovery/default
|
||||
# (`profiles.toml` と bundled builtin profile) から manifest を生成する。
|
||||
# `insomnia-pod --manifest <path>` の one-file compatibility/debug mode では、
|
||||
# `insomnia pod --manifest <path>` の one-file compatibility/debug mode では、
|
||||
# 指定した TOML 1 枚に builtin defaults を merge し、required validation を行う。
|
||||
# user/project `manifest.toml` を暗黙に merge する通常起動 cascade は使わない。
|
||||
#
|
||||
|
||||
+12
-11
@@ -1,6 +1,6 @@
|
||||
# Nix package
|
||||
|
||||
INSOMNIA provides a flake package for installing the user-facing Pod CLI and TUI binaries without relying on a source checkout at runtime.
|
||||
INSOMNIA provides a flake package for installing the user-facing `insomnia` command without relying on a source checkout at runtime. The Pod runtime still runs as a separate process through `insomnia pod ...`; the installed package does not expose a separate `insomnia-pod` command.
|
||||
|
||||
## Build
|
||||
|
||||
@@ -10,12 +10,11 @@ From the repository root:
|
||||
nix build .#
|
||||
```
|
||||
|
||||
The default package is implemented by `package.nix` and builds the Cargo packages `pod` and `tui` as installed binaries `insomnia-pod` and `insomnia`. The derivation uses the checked-in `Cargo.lock`, so Cargo dependencies are fetched by the normal Nix Rust packaging path instead of by network access during the build.
|
||||
The default package is implemented by `package.nix` and builds the Cargo package `tui` as the installed binary `insomnia`. The `pod` crate remains a library dependency that provides the Pod runtime entrypoint used by `insomnia pod ...`. The derivation uses the checked-in `Cargo.lock`, so Cargo dependencies are fetched by the normal Nix Rust packaging path instead of by network access during the build.
|
||||
|
||||
The package output contains:
|
||||
|
||||
- `bin/insomnia-pod` — Pod CLI / runtime process.
|
||||
- `bin/insomnia` — terminal UI.
|
||||
- `bin/insomnia` — terminal UI and `insomnia pod ...` runtime entrypoint.
|
||||
- `share/insomnia/resources/` — bundled runtime resources, including `resources/prompts/`.
|
||||
- `share/doc/insomnia/nix.md` — this document.
|
||||
|
||||
@@ -24,7 +23,7 @@ The package output contains:
|
||||
After `nix build`:
|
||||
|
||||
```sh
|
||||
./result/bin/insomnia-pod --help
|
||||
./result/bin/insomnia pod --help
|
||||
./result/bin/insomnia
|
||||
```
|
||||
|
||||
@@ -32,14 +31,14 @@ With flakes:
|
||||
|
||||
```sh
|
||||
nix run .#insomnia
|
||||
nix run .#insomnia-pod -- --help
|
||||
nix run .#insomnia -- pod --help
|
||||
```
|
||||
|
||||
`nix run .#` defaults to the TUI.
|
||||
|
||||
## Configuration discovery
|
||||
|
||||
The Nix package does not put user configuration, sessions, sockets, or other mutable state in the Nix store. The installed binaries keep the same path semantics as non-Nix builds:
|
||||
The Nix package does not put user configuration, sessions, sockets, or other mutable state in the Nix store. The installed binary keeps the same path semantics as non-Nix builds:
|
||||
|
||||
| Purpose | Override | `INSOMNIA_HOME` fallback | XDG / default fallback |
|
||||
| --- | --- | --- | --- |
|
||||
@@ -47,14 +46,15 @@ The Nix package does not put user configuration, sessions, sockets, or other mut
|
||||
| Persistent data (`sessions/`, Pod metadata) | `INSOMNIA_DATA_DIR` | `$INSOMNIA_HOME` | `$HOME/.insomnia` |
|
||||
| Runtime state (sockets, lock files, live registry) | `INSOMNIA_RUNTIME_DIR` | `$INSOMNIA_HOME/run` | `$XDG_RUNTIME_DIR/insomnia`, then `$HOME/.insomnia/run` |
|
||||
|
||||
Normal fresh startup is profile-based. The package ships a builtin default profile, user/project `profiles.toml` files may select or define profiles, and `insomnia-pod --manifest <PATH>` remains a one-file compatibility/debug input. `INSOMNIA_USER_MANIFEST` and ambient `.insomnia/manifest.toml` discovery are not part of normal Pod/TUI startup.
|
||||
Normal fresh startup is profile-based. The package ships a builtin default profile, user/project `profiles.toml` files may select or define profiles, and `insomnia pod --manifest <PATH>` remains a one-file compatibility/debug input. `INSOMNIA_USER_MANIFEST` and ambient `.insomnia/manifest.toml` discovery are not part of normal Pod/TUI startup.
|
||||
|
||||
## Validation
|
||||
|
||||
The package derivation has a credential-free install check that verifies:
|
||||
|
||||
- `insomnia-pod --help` starts successfully.
|
||||
- `insomnia pod --help` starts successfully.
|
||||
- `insomnia` is installed and reaches argument parsing.
|
||||
- `bin/insomnia-pod` is not installed.
|
||||
- bundled prompt resources and this Nix usage document are present in the output.
|
||||
|
||||
For full validation before handing changes to review, run:
|
||||
@@ -63,12 +63,13 @@ For full validation before handing changes to review, run:
|
||||
nix build .#
|
||||
nix flake check
|
||||
cargo fmt --check
|
||||
cargo check -p tui -p pod -p client
|
||||
```
|
||||
|
||||
This packaging change does not require provider credentials. A Rust `cargo check` is only needed if Rust source or runtime path semantics are changed.
|
||||
These checks do not require provider credentials.
|
||||
|
||||
## Known limitations
|
||||
|
||||
- The package currently installs the TUI and Pod CLI only; development-only wrappers from `devshell.nix` are not part of the installable package.
|
||||
- The package currently installs only the `insomnia` command; development-only wrappers from `devshell.nix` are not part of the installable package.
|
||||
- The TUI does not currently expose a conventional `--help` / `--version` CLI path, so the package smoke check uses an argument-parse failure path for the TUI rather than launching an interactive session.
|
||||
- Bundled resources are installed under `share/insomnia/resources/` for packaging completeness and inspection. Built-in prompt/resource loading remains governed by the existing application code and user/project override rules.
|
||||
|
||||
@@ -172,7 +172,7 @@ unique であれば workspace を指定しなくて済む。
|
||||
## Daemon-less リモート Pod 生成(SSH-only モデル)
|
||||
|
||||
リモートホスト上の Pod 生成は **daemon 無しで SSH だけで成立する**。
|
||||
remote 側に必要なのは `insomnia-pod` バイナリと SSH アクセスのみ。
|
||||
remote 側に必要なのは `insomnia` バイナリと SSH アクセスのみ。
|
||||
|
||||
### 前提
|
||||
|
||||
@@ -182,7 +182,7 @@ remote 側に必要なのは `insomnia-pod` バイナリと SSH アクセスの
|
||||
- insomnia が転送するのは**セッション(会話履歴)と manifest overlay**
|
||||
だけ。コードベースの同期は外部に委ねる
|
||||
- コンテナ内で動かすか bare metal で動かすかも insomnia は問わない。
|
||||
`insomnia-pod` バイナリが動くホストの fs 上で活動する主体がある、
|
||||
`insomnia` バイナリが動くホストの fs 上で活動する主体がある、
|
||||
それだけが前提
|
||||
|
||||
### フロー
|
||||
@@ -193,7 +193,7 @@ host_a (spawner) host_b (remote)
|
||||
│
|
||||
├── ssh: session データを転送 ────────→ ファイル書き込み
|
||||
├── ssh: profile / one-file manifest 入力を転送 ─→ 必要ならファイル書き込み
|
||||
├── ssh: `insomnia-pod --profile ... &` ───────→ Pod プロセス起動、socket 作成
|
||||
├── ssh: `insomnia pod --profile ... &` ───────→ Pod プロセス起動、socket 作成
|
||||
├── ssh -L: socket を tunnel ─────────→ Pod B の unix socket
|
||||
│
|
||||
└── localhost:tunnel に接続 ──────────→ Method::Run / Event stream
|
||||
@@ -209,7 +209,7 @@ tar cz session/ | ssh insomnia@host-b "tar xz -C ~/workspaces/task-123/store"
|
||||
scp profile.lua insomnia@host-b:~/workspaces/task-123/profile.lua
|
||||
|
||||
# 2. Pod を起動(detach)
|
||||
ssh insomnia@host-b "insomnia-pod --store ~/workspaces/task-123/store \
|
||||
ssh insomnia@host-b "insomnia pod --store ~/workspaces/task-123/store \
|
||||
--profile ~/workspaces/task-123/profile.lua &"
|
||||
|
||||
# 3. socket を tunnel で引っ張る
|
||||
|
||||
+4
-4
@@ -156,12 +156,12 @@ Profile and one-file Manifest CLI paths currently use builtin prompt assets only
|
||||
|
||||
The rendered instruction body is followed by fixed Rust-provided sections for working boundaries and, when present, `AGENTS.md`. User templates cannot remove the scope section.
|
||||
|
||||
## `insomnia-pod` CLI
|
||||
## `insomnia pod` CLI
|
||||
|
||||
Normal fresh startup uses profile discovery/default selection:
|
||||
|
||||
```text
|
||||
insomnia-pod [--profile <selector>] [--profile-pod-name <name>] [-s/--store <path>]
|
||||
insomnia pod [--profile <selector>] [--profile-pod-name <name>] [-s/--store <path>]
|
||||
```
|
||||
|
||||
| Flag | Description |
|
||||
@@ -173,8 +173,8 @@ insomnia-pod [--profile <selector>] [--profile-pod-name <name>] [-s/--store <pat
|
||||
Restore/attach uses Pod/session state and does not re-evaluate profile sources.
|
||||
|
||||
```text
|
||||
insomnia-pod --pod <name>
|
||||
insomnia-pod --session <uuid>
|
||||
insomnia pod --pod <name>
|
||||
insomnia pod --session <uuid>
|
||||
```
|
||||
|
||||
Spawn children use hidden `--spawn-config-json`, `--adopt`, and `--callback <path>` flags. These are internal handoff details used by `SpawnPod` after the parent has allocated scope and prepared the child config.
|
||||
|
||||
Reference in New Issue
Block a user