@msn-control/liftoff 0.3.4 → 0.4.1
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/README.md +82 -32
- package/assets/locks/frontend/package-lock.json +2217 -0
- package/assets/locks/frontend/package.json +19 -0
- package/assets/locks/node-backend/package-lock.json +4352 -0
- package/assets/locks/node-backend/package.json +32 -0
- package/dist/args.d.ts +42 -1
- package/dist/args.js +170 -37
- package/dist/args.js.map +1 -1
- package/dist/catalogs.d.ts +10 -1
- package/dist/catalogs.js +89 -0
- package/dist/catalogs.js.map +1 -1
- package/dist/cli.js +11 -1
- package/dist/cli.js.map +1 -1
- package/dist/commands.d.ts +9 -0
- package/dist/commands.js +832 -227
- package/dist/commands.js.map +1 -1
- package/dist/file-system.js +89 -5
- package/dist/file-system.js.map +1 -1
- package/dist/framework-adapters.d.ts +18 -0
- package/dist/framework-adapters.js +115 -0
- package/dist/framework-adapters.js.map +1 -0
- package/dist/framework-validation.d.ts +8 -0
- package/dist/framework-validation.js +83 -0
- package/dist/framework-validation.js.map +1 -0
- package/dist/init-filesystem.d.ts +102 -0
- package/dist/init-filesystem.js +762 -0
- package/dist/init-filesystem.js.map +1 -0
- package/dist/interactive.d.ts +43 -2
- package/dist/interactive.js +202 -91
- package/dist/interactive.js.map +1 -1
- package/dist/npm-template-assets.d.ts +3 -0
- package/dist/npm-template-assets.js +32 -0
- package/dist/npm-template-assets.js.map +1 -0
- package/dist/planner.d.ts +5 -0
- package/dist/planner.js +87 -21
- package/dist/planner.js.map +1 -1
- package/dist/process-runner.d.ts +28 -0
- package/dist/process-runner.js +83 -0
- package/dist/process-runner.js.map +1 -0
- package/dist/project-dependencies.d.ts +30 -0
- package/dist/project-dependencies.js +164 -0
- package/dist/project-dependencies.js.map +1 -0
- package/dist/published-verifier.js +1 -1
- package/dist/published-verifier.js.map +1 -1
- package/dist/reconcile.js +4 -1
- package/dist/reconcile.js.map +1 -1
- package/dist/runtime.d.ts +2 -0
- package/dist/runtime.js +9 -0
- package/dist/runtime.js.map +1 -0
- package/dist/standard-templates.js +3 -30
- package/dist/standard-templates.js.map +1 -1
- package/dist/templates.d.ts +9 -1
- package/dist/templates.js +110 -46
- package/dist/templates.js.map +1 -1
- package/dist/terminal.d.ts +128 -0
- package/dist/terminal.js +598 -0
- package/dist/terminal.js.map +1 -0
- package/dist/types.d.ts +38 -1
- package/dist/workstation-catalog.d.ts +20 -0
- package/dist/workstation-catalog.js +122 -0
- package/dist/workstation-catalog.js.map +1 -0
- package/dist/workstation.d.ts +76 -0
- package/dist/workstation.js +461 -0
- package/dist/workstation.js.map +1 -0
- package/package.json +8 -2
package/README.md
CHANGED
|
@@ -26,63 +26,86 @@ Versions before 0.3.0 are unsupported and must not be used for new projects. If
|
|
|
26
26
|
|
|
27
27
|
## Quick Start
|
|
28
28
|
|
|
29
|
-
Preview a
|
|
29
|
+
Preview a project and its derived workstation requirements without writing files or running installers:
|
|
30
30
|
|
|
31
31
|
```bash
|
|
32
|
-
liftoff plan --pattern rag --cloud azure --region eastus --frontend
|
|
32
|
+
liftoff plan --pattern rag --cloud azure --region eastus --frontend --agents copilot,claude
|
|
33
33
|
```
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
Initialize a named project. Liftoff probes required runtimes, the selected spec framework, cloud/development tools, and every selected AI coding agent before it writes:
|
|
36
36
|
|
|
37
37
|
```bash
|
|
38
|
-
liftoff
|
|
38
|
+
liftoff init claims-copilot --pattern rag --cloud azure --region eastus --spec openspec --agents copilot,claude --frontend --yes
|
|
39
39
|
cd claims-copilot
|
|
40
40
|
cp .env.example .env
|
|
41
41
|
liftoff validate
|
|
42
42
|
liftoff doctor
|
|
43
43
|
```
|
|
44
44
|
|
|
45
|
-
|
|
45
|
+
Add `--install-tools` only after reviewing machine-level install commands, and add `--install-dependencies` to run the generated project's locked dependency commands. These permissions are independent from `--yes`.
|
|
46
|
+
|
|
47
|
+
To initialize an existing Git worktree root in place, run `liftoff init` at that exact root. With no project name, Liftoff uses the repository directory name; a supplied name changes project identity without creating a child directory.
|
|
46
48
|
|
|
47
49
|
```bash
|
|
48
|
-
|
|
49
|
-
liftoff
|
|
50
|
+
cd existing-repository
|
|
51
|
+
liftoff init --no-genai --api node --cloud azure --region eastus --spec spec-kit --agents copilot,claude --default-agent copilot
|
|
50
52
|
```
|
|
51
53
|
|
|
52
|
-
Standard API choices are `python` (FastAPI), `node` (Fastify with TypeScript), and `go` (Huma v2 with Chi).
|
|
54
|
+
In a non-Git directory or below (but not at) a Git root, a project name creates a named child. Standard API choices are `python` (FastAPI), `node` (Fastify with TypeScript), and `go` (Huma v2 with Chi). A GenAI `--pattern` selects the Python/FastAPI/PydanticAI stack.
|
|
53
55
|
|
|
54
|
-
|
|
56
|
+
For an existing application, migration creates a fresh sibling scaffold, runs the same readiness and official-framework pipeline, stages a filtered source copy, and leaves the source byte-for-byte unchanged:
|
|
55
57
|
|
|
56
58
|
```bash
|
|
57
|
-
liftoff
|
|
58
|
-
docker compose up --build
|
|
59
|
+
liftoff migrate ../legacy-app --region eastus --agents copilot,claude --yes
|
|
59
60
|
```
|
|
60
61
|
|
|
61
|
-
|
|
62
|
+
## Terminal Interface
|
|
63
|
+
|
|
64
|
+
Interactive `init`, `migrate`, and `plan` sessions open with the Liftoff identity before discovery or the first question. Human-readable help, prompts, plans, readiness checks, consent details, maintenance results, catalogs, errors, remedies, and completion summaries use the same presentation hierarchy:
|
|
65
|
+
|
|
66
|
+
```text
|
|
67
|
+
┌──────────────────────────────────────────────────────────────────────────────┐
|
|
68
|
+
│ ██╗ ██╗███████╗████████╗ ██████╗ ███████╗███████╗ │
|
|
69
|
+
│ ██║ ██║██╔════╝╚══██╔══╝██╔═══██╗██╔════╝██╔════╝ │
|
|
70
|
+
│ ██║ ██║█████╗ ██║ ██║ ██║█████╗ █████╗ │
|
|
71
|
+
│ ██║ ██║██╔══╝ ██║ ██║ ██║██╔══╝ ██╔══╝ │
|
|
72
|
+
│ ███████╗██║██║ ██║ ╚██████╔╝██║ ██║ │
|
|
73
|
+
│ ╚══════╝╚═╝╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝ │
|
|
74
|
+
└──────────────────────────────────────────────────────────────────────────────┘
|
|
75
|
+
◆ Configure project
|
|
76
|
+
┌─ Resolved project plan ──────────────────────────────────────────────────────┐
|
|
77
|
+
│ Project claims-copilot │
|
|
78
|
+
│ Spec workflow OpenSpec │
|
|
79
|
+
│ Coding agents GitHub Copilot, Claude Code │
|
|
80
|
+
└──────────────────────────────────────────────────────────────────────────────┘
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
TTYs at least 96 columns receive the rich wordmark, Unicode sections, aligned tables, and restrained semantic color. Widths from 64 through 95 columns use the compact identity and wrapped sections. Narrow or redirected output is deterministic plain text with no ANSI sequences or decorative borders, so paths, commands, labels, values, and remedies remain copyable.
|
|
84
|
+
|
|
85
|
+
Set `NO_COLOR=1` to retain the selected layout and hierarchy without ANSI color:
|
|
62
86
|
|
|
63
87
|
```bash
|
|
64
|
-
liftoff
|
|
88
|
+
NO_COLOR=1 liftoff init
|
|
89
|
+
liftoff doctor > readiness.txt
|
|
65
90
|
```
|
|
66
91
|
|
|
67
|
-
|
|
92
|
+
Machine contracts bypass presentation. `liftoff doctor --json` and `liftoff update --json` emit only their documented JSON values, while `liftoff --version` remains exactly one line. Liftoff labels installer, framework, and dependency stages, then forwards child stdout and stderr unchanged.
|
|
68
93
|
|
|
69
|
-
|
|
94
|
+
## Lifecycle
|
|
70
95
|
|
|
71
96
|
```text
|
|
72
|
-
plan ->
|
|
97
|
+
plan -> init or migrate -> validate and doctor -> update -> dev and infra helpers
|
|
73
98
|
```
|
|
74
99
|
|
|
75
|
-
- `liftoff plan` resolves
|
|
76
|
-
- `liftoff
|
|
77
|
-
- `liftoff migrate <path>` scans a
|
|
78
|
-
- `liftoff validate` checks
|
|
79
|
-
- `liftoff doctor`
|
|
80
|
-
- `liftoff update`
|
|
81
|
-
- `liftoff
|
|
82
|
-
- `liftoff dev` prints Docker Compose helper commands such as `docker compose up --build`, `docker compose logs -f`, and `docker compose down --volumes`.
|
|
83
|
-
- `liftoff infra` prints OpenTofu helper commands such as `tofu init`, `tofu plan -var-file=environments/dev.tfvars`, and `tofu apply -var-file=environments/dev.tfvars`.
|
|
100
|
+
- `liftoff plan` resolves project decisions, previews artifacts and requirements, and has no side effects.
|
|
101
|
+
- `liftoff init` initializes a new child or the exact current Git root, checks workstation readiness, runs the pinned official OpenSpec or Spec Kit initializer in temporary staging, validates all output, and merges transactionally.
|
|
102
|
+
- `liftoff migrate <path>` scans a non-Liftoff source, requires a new or empty sibling target, and uses the same staged framework and optional dependency phases. `--force` never permits a non-empty migration target.
|
|
103
|
+
- `liftoff validate` checks the manifest's durable files plus the declared framework contract and selected-agent markers.
|
|
104
|
+
- `liftoff doctor` performs read-only plan-derived probes with blocking, advisory, authentication-health, framework, drift, runtime, and cloud layers. JSON output uses stable requirement identifiers and states.
|
|
105
|
+
- `liftoff update` is a read-only drift check by default. `liftoff update --apply` writes safe durable changes, skips conflicts unless `--force` is supplied, and reports orphans without deleting them.
|
|
106
|
+
- `liftoff dev` and `liftoff infra` print Docker Compose and OpenTofu helper commands; they do not execute them.
|
|
84
107
|
|
|
85
|
-
|
|
108
|
+
Catalog discovery remains available:
|
|
86
109
|
|
|
87
110
|
```bash
|
|
88
111
|
liftoff patterns
|
|
@@ -91,19 +114,46 @@ liftoff regions
|
|
|
91
114
|
liftoff regions search korea --cloud azure
|
|
92
115
|
```
|
|
93
116
|
|
|
94
|
-
Azure is the available V1 provider. AWS and GCP
|
|
117
|
+
Azure is the available V1 provider. AWS and GCP remain planned and are rejected before generation.
|
|
118
|
+
|
|
119
|
+
## Workstation Readiness
|
|
120
|
+
|
|
121
|
+
Liftoff automatically detects requirements derived from the full project plan:
|
|
122
|
+
|
|
123
|
+
- Blocking: Node.js 20.19+, the selected Python/Node/Go runtime, the exact tested OpenSpec or Spec Kit CLI, and every selected Copilot or Claude Code integration.
|
|
124
|
+
- Advisory: Docker and daemon health, OpenTofu, Azure CLI, and cloud authentication.
|
|
125
|
+
- Authentication: Liftoff reports observable health but never stores credentials or signs in on the developer's behalf.
|
|
126
|
+
|
|
127
|
+
On macOS, allowlisted recipes use Homebrew, npm, or `uv`; on Windows they use WinGet, npm, or `uv`. Liftoff prints each command and requires `--install-tools` or separate interactive approval. Linux system packages are never installed with automatic elevation: Liftoff gives distribution-appropriate official guidance, while npm/`uv` framework recipes remain separately consented. PATH-changing installs are re-probed and may require a new terminal.
|
|
128
|
+
|
|
129
|
+
Copilot is detected through its CLI or supported VS Code extensions. Claude Code is checked with its version and doctor commands. Both agents may be selected together; Spec Kit additionally records one selected agent as its default integration.
|
|
130
|
+
|
|
131
|
+
## Target, Ownership, And Consent Safety
|
|
132
|
+
|
|
133
|
+
Liftoff renders into a temporary staging directory, runs official framework commands there, rejects symlinks and unexpected framework roots, validates the complete tree, then computes one immutable destination preflight. Existing unrelated files are preserved. Different regular files are disclosed as one conflict set; structural collisions, symlink paths, unsafe ancestors, and an existing `liftoff.manifest.json` are non-overridable blockers. Writes are atomic and handled failures roll back created or replaced files.
|
|
134
|
+
|
|
135
|
+
The four consent flags do not imply one another:
|
|
136
|
+
|
|
137
|
+
| Flag | Authorizes | Does not authorize |
|
|
138
|
+
| --- | --- | --- |
|
|
139
|
+
| `--yes` | Project defaults and plan confirmation | File replacement, machine installs, or project dependencies |
|
|
140
|
+
| `--force` | Only listed, validated regular-file replacements | Manifest guards, symlinks, structural collisions, tools, dependencies, or non-empty migration targets |
|
|
141
|
+
| `--install-tools` | Allowlisted workstation installation commands | Project decisions, overwrites, or project dependencies |
|
|
142
|
+
| `--install-dependencies` | Locked project-local dependency commands after a successful merge | Machine tools, project decisions, or overwrites |
|
|
143
|
+
|
|
144
|
+
OpenSpec and Spec Kit core/integration output is owned by their official initializers. Liftoff validates the declared version and selected-agent markers but does not place framework-owned or one-time seed files in durable artifact hashes. Schema-v3 manifests record this contract explicitly; schema-v2 projects remain supported as legacy state without inventing framework ownership or agent selections.
|
|
95
145
|
|
|
96
146
|
## Strict Commands And Safe Recovery
|
|
97
147
|
|
|
98
148
|
Liftoff validates each command before running it. Unknown flags or subcommands, missing flag values, invalid booleans, incompatible duplicates, and extra positional arguments exit 1 without generating files or printing a fallback helper command. Use command-specific help to see the accepted syntax:
|
|
99
149
|
|
|
100
150
|
```bash
|
|
101
|
-
liftoff
|
|
151
|
+
liftoff init --help
|
|
152
|
+
liftoff migrate --help
|
|
102
153
|
liftoff update --help
|
|
103
|
-
liftoff regions --help
|
|
104
154
|
```
|
|
105
155
|
|
|
106
|
-
`liftoff
|
|
156
|
+
The former `liftoff create` command is intentionally rejected with guidance to use `liftoff init`; there is no compatibility alias.
|
|
107
157
|
|
|
108
158
|
Manifest paths must be portable path-part arrays confined to the project. Traversal, absolute, drive-qualified, UNC, embedded-separator, empty, and symlink-escaping paths are rejected before artifact access. If validation reports an unsafe or malformed manifest, restore `liftoff.manifest.json` from version control or regenerate a fresh project with the matching Liftoff version. Do not repair the issue by weakening path validation or by retaining a hand-edited unsafe path.
|
|
109
159
|
|
|
@@ -178,7 +228,7 @@ Conditional areas:
|
|
|
178
228
|
Generated projects contain two root files with different ownership models:
|
|
179
229
|
|
|
180
230
|
- `liftoff.config.json` is user-owned desired state after creation. Liftoff writes it once during generation and does not machine-rewrite it afterwards. Supported changes, such as adding an environment or enabling frontend output, are reconciled by `liftoff update`. Project type, API stack, and GenAI pattern changes are migrations and should use `liftoff migrate`.
|
|
181
|
-
- `liftoff.manifest.json` is the CLI-owned compatibility record. Manifest schema
|
|
231
|
+
- `liftoff.manifest.json` is the CLI-owned compatibility record. Manifest schema v3 records the generating `liftoffVersion`, project identity, selected agents, applicable default agent, official framework adapter and tested contract version, and durable generated artifact `logicalName`s with OS-neutral path parts and `sha256:` content hashes. V2 manifests remain readable as explicit legacy framework state.
|
|
182
232
|
|
|
183
233
|
The manifest lets `liftoff validate`, `liftoff doctor`, and `liftoff update` distinguish clean generated files from local edits. Seed content, such as the initial OpenSpec bootstrap change, is written once and intentionally omitted from the durable manifest so it can follow its own lifecycle. Treat the manifest as CLI-owned: restore or regenerate it when validation fails rather than hand-editing artifact paths or hashes.
|
|
184
234
|
|
|
@@ -186,7 +236,7 @@ The manifest lets `liftoff validate`, `liftoff doctor`, and `liftoff update` dis
|
|
|
186
236
|
|
|
187
237
|
Generated projects contain persistent files that outlive any CLI release. The following rules are the compatibility contract, enforced by `tests/contract.test.ts` where possible:
|
|
188
238
|
|
|
189
|
-
- **Manifest schema**:
|
|
239
|
+
- **Manifest schema**: writers use `artifactVersion` 3; readers support v2 legacy and v3 initialized framework state and reject other versions with a remedy. Durable artifacts retain `sha256:`-prefixed hashes, while framework-owned and seed files are validated separately.
|
|
190
240
|
- **Append-only identifiers**: artifact `logicalName`s and catalog ids (project types, API stacks, patterns, providers, environments, spec workflows) are never renamed or removed, only added. The contract test snapshots the logical-name sets.
|
|
191
241
|
- **Deterministic rendering**: artifact content depends only on the project plan and the template code, with no timestamps, randomness, or environment leakage. Verified by a double-render byte-equality test.
|
|
192
242
|
- **Reserved namespaces**: `.liftoff/` in generated projects is reserved for future CLI-managed state; no new CLI-managed root-level files beyond `liftoff.config.json` and `liftoff.manifest.json`. `liftoff.config.json` is written once at generation and never machine-written afterwards.
|