mirror of
https://github.com/jparkerweb/plan2code.git
synced 2026-11-19 05:11:18 -08:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e5ce951b93 | ||
|
|
8658631b5d | ||
|
|
09fb4f4eec | ||
|
|
c96e1f0f52 | ||
|
|
3b09d03090 | ||
|
|
ce073cd07a | ||
|
|
65fbd1bfe1 | ||
|
|
52efac51b8 | ||
|
|
775b693583 | ||
|
|
cc7d89181d |
No files matched your search
@@ -123,7 +123,7 @@ plan2code/
|
|||||||
|
|
||||||
### Release channel
|
### Release channel
|
||||||
|
|
||||||
Install and update follow release tags, never `main`. `release-app.yml`'s `publish` job ends by fast-forwarding the `release` branch to the tag it just published (no force: a tag not ahead of the branch fails the job), and the README's first install is `npx --allow-git=all git+https://github.com/jparkerweb/plan2code.git#release`. `plan2code update` installs the newest `vX.Y.Z` tag (`newestReleaseTag()` in `src/launcher/plan2code.js`, using `latestTag()` and `runLsRemote()` from the copy of `update-check.mjs` beside it); `--main` installs the tip of `main`, `--tag <ref>` any ref (how to go back to a release); `--main` and a `--tag` naming a branch always pass `--force`, since unreleased work keeps the last release's version and the installer's `Already on` check would install nothing. `plan2code uninstall` runs the newest release's installer the same way, falling back to `main` only when no release tag can be found. The console's release check (`update-check.mjs`) and the app's notice (`versions.rs` `latest_tag()`) use the same rule: the highest plain `vX.Y.Z` in `git ls-remote --tags`, peeled and pre-release tags skipped. The app's Update skills still pins to the app's own tag.
|
Install and update follow release tags, never `main`. `release-app.yml`'s `publish` job ends by fast-forwarding the `release` branch to the tag it just published (no force: a tag not ahead of the branch fails the job), and the README's first install is `npx --allow-git=all git+https://github.com/jparkerweb/plan2code.git#release`. `plan2code update` installs the newest `vX.Y.Z` tag (`newestReleaseTag()` in `src/launcher/plan2code.js`, using `latestTag()` and `runLsRemote()` from the copy of `update-check.mjs` beside it); `--main` installs the tip of `main`, `--tag <ref>` any ref (how to go back to a release); `--main` and a `--tag` naming a branch always pass `--force`, since unreleased work keeps the last release's version and the installer's `Already on` check would install nothing. `plan2code uninstall` runs the newest release's installer the same way, falling back to `main` only when no release tag can be found. Launchers older than the channel (and install commands copied without `#release`) still fetch `main`, so `install.js` redirects itself (`redirectToRelease()`): when npx fetched it from a commit no `vX.Y.Z` tag points at (`fetchedCommit()` reads npm's hidden `node_modules/.package-lock.json`; `releaseRedirectRef()` decides), it reruns the same options from `#v<newest>`. The launcher sets `PLAN2CODE_INSTALL_REF` on every installer run (`main` for `--main`) so a deliberate ref is never redirected, a checkout is not under `node_modules` so it never is either, and anything unknown (no lock file, no network) runs in place. The redirect lives on `main` for old launchers to find, so it must stay there. The console's release check (`update-check.mjs`) and the app's notice (`versions.rs` `latest_tag()`) use the same rule: the highest plain `vX.Y.Z` in `git ls-remote --tags`, peeled and pre-release tags skipped. The app's Update skills still pins to the app's own tag.
|
||||||
|
|
||||||
### Agents file
|
### Agents file
|
||||||
|
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
U0VOQwFXeZZ2LQjdLUSSPDZ4vtw/FiDmfXw9fG8bM3nucaLO+T9XQN9U9t3VdtYnGqX/wKp/UefGXZmTT9BatYKzavI8O9yxDFbOkhu2eA8rQ+LfJ3J7H94EeD9GdEoPvoSaW9GJqyBk/zTVcqapukaBllICd/iouX0PzNk0rMOc7yfhsbWuWsYb4q9E/qn5G4SI3n2zOvsaGZqppJPVQMxWAJQvrQhk6VL+8l48ftO9L02hieVdDs8bmLqhTkF19FQkT1DzGuESlMVEcQP546QtAqtXOpTnO7twtXsCpBOguZ/jLArPFh8lAjMsM3/0LQ8WV7i98zKRyCxELlB+BYwz25BRBIUj2uJNRYloXeLuEyVqS+qC/SScOOlY5Oh2oyFcxyZ8K/ESBKai9djOB36/QlrYD69PNOv2Sb39oHcCObPUofzFSGAVydCtQOsc//my+S/aPkNhTtQEsCAwws5AuCPpuQ1UCUHjkNuWfYWOkOGRNHnlbnLjdKTjm/4ggZQYb4jeGAWqPg+da/ZMSn5Bj+ZTiKOk0d4FPQOwZQlkg6vhd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J8ZmdqHKAftkEYapJteDPCjYRDYUqinotgxIVuAqhYu67Jgt3Wo5Zi/orWwnq6ze8mURiZLDb3jU37r6ox+yOlNZDZe+EyeNwUzjyyYaq+HmubtlxzCLfutYE64y1hm0byJTaHEH+RoSkNxyuOUf/xD+9vy28aGOzzE2d9x2WkJ8KoslyB04a9QMKzRWLSsk9Wf4Z2FHrwluW3i7YUmxA407sFfYevNvv6TIRHXMld/JtT1PHaeZuPICY/sofXD5AspuecnOfts9sd1kmtCkmVGQlF0ct7UlI+q6atIBiN/xgoYWYbDyjXZF8cvbE06H9WbOR2rDsQHGPxcuxUxj6lSuH3lauzsErdg0mvwPX9hcGAk/qcZcXRw2Zlo+L6zebv65Z4jsSoOKT0j9yRaVdTe8Z12oyQXPPpCkHX+7pHsVKh+gv0geGLzmWGXZTgplV0CTh3jlG46ZjY3Fo84R4Eu8ZA/UBUMU/g7p9EtfMh2rKPtaswd/9yyJ7E65v1OdKIHEQw1mIyU8sxEEcGZXIzdkaoujUTFPezIByjvcTwuUPbYhjc5R+NGvwKNhptIIjv6DeDUCoR+Mszls6K6SHiF2xnDQxW0R/R6sfkQtpB3abKylUwgyhOMMpR2VQ5K68x7od4N+pNg3+mpR2jTVTCas+H7V2aviP4cRRIB7zZEf2TKOsFVCQuEymP5oodETVvz31CjaBIRecMGNNPdyAIT0+t12JfFT81mUeQ8sQZpxMS6kGqX3ndl6hsrwOCFE1WFvJVAKTq2vaHp1P94lOc72Wpn988Z0OICIa0RQ+cKCyXh1Line truncated
|
||||||
@@ -30,7 +30,7 @@ jobs:
|
|||||||
outputs:
|
outputs:
|
||||||
code: ${{ steps.diff.outputs.code }}
|
code: ${{ steps.diff.outputs.code }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v7.0.1
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
- id: diff
|
- id: diff
|
||||||
@@ -60,8 +60,8 @@ jobs:
|
|||||||
name: prose checks
|
name: prose checks
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v7.0.1
|
||||||
- uses: actions/setup-node@v4.4.0
|
- uses: actions/setup-node@v7.1.0
|
||||||
with:
|
with:
|
||||||
node-version: 20
|
node-version: 20
|
||||||
- name: Versions agree
|
- name: Versions agree
|
||||||
@@ -82,8 +82,8 @@ jobs:
|
|||||||
run:
|
run:
|
||||||
working-directory: plan2code-app
|
working-directory: plan2code-app
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v7.0.1
|
||||||
- uses: actions/setup-node@v4.4.0
|
- uses: actions/setup-node@v7.1.0
|
||||||
with:
|
with:
|
||||||
node-version: 20
|
node-version: 20
|
||||||
cache: npm
|
cache: npm
|
||||||
@@ -179,8 +179,8 @@ jobs:
|
|||||||
matrix:
|
matrix:
|
||||||
os: [windows-latest, macos-latest, ubuntu-latest]
|
os: [windows-latest, macos-latest, ubuntu-latest]
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v7.0.1
|
||||||
- uses: actions/setup-node@v4.4.0
|
- uses: actions/setup-node@v7.1.0
|
||||||
with:
|
with:
|
||||||
node-version: 20
|
node-version: 20
|
||||||
- name: Cache the npm downloads
|
- name: Cache the npm downloads
|
||||||
|
|||||||
@@ -27,8 +27,8 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v7.0.1
|
||||||
- uses: actions/setup-node@v4.4.0
|
- uses: actions/setup-node@v7.1.0
|
||||||
with:
|
with:
|
||||||
node-version: 20
|
node-version: 20
|
||||||
- name: Cache the npm downloads
|
- name: Cache the npm downloads
|
||||||
@@ -60,8 +60,8 @@ jobs:
|
|||||||
run:
|
run:
|
||||||
shell: bash
|
shell: bash
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v7.0.1
|
||||||
- uses: actions/setup-node@v4.4.0
|
- uses: actions/setup-node@v7.1.0
|
||||||
with:
|
with:
|
||||||
node-version: 20
|
node-version: 20
|
||||||
- name: Cache the npm downloads
|
- name: Cache the npm downloads
|
||||||
|
|||||||
@@ -64,10 +64,10 @@ jobs:
|
|||||||
run:
|
run:
|
||||||
shell: bash
|
shell: bash
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v7.0.1
|
||||||
with:
|
with:
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
- uses: actions/setup-node@v4.4.0
|
- uses: actions/setup-node@v7.1.0
|
||||||
with:
|
with:
|
||||||
node-version: 22
|
node-version: 22
|
||||||
cache: npm
|
cache: npm
|
||||||
@@ -121,7 +121,7 @@ jobs:
|
|||||||
VERSION="$(node -p "require('./plan2code-app/src-tauri/tauri.conf.json').version")"
|
VERSION="$(node -p "require('./plan2code-app/src-tauri/tauri.conf.json').version")"
|
||||||
mkdir -p dist
|
mkdir -p dist
|
||||||
cp "plan2code-app/target/release/${{ matrix.built }}" "dist/plan2code-app-${VERSION}-${{ matrix.label }}${{ matrix.suffix }}"
|
cp "plan2code-app/target/release/${{ matrix.built }}" "dist/plan2code-app-${VERSION}-${{ matrix.label }}${{ matrix.suffix }}"
|
||||||
- uses: actions/upload-artifact@v4.6.2
|
- uses: actions/upload-artifact@v7.0.2
|
||||||
with:
|
with:
|
||||||
name: app-${{ matrix.label }}
|
name: app-${{ matrix.label }}
|
||||||
path: dist/*
|
path: dist/*
|
||||||
@@ -136,8 +136,8 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ github.token }}
|
GH_TOKEN: ${{ github.token }}
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4.2.2
|
- uses: actions/checkout@v7.0.1
|
||||||
- uses: actions/download-artifact@v4.3.0
|
- uses: actions/download-artifact@v8.0.2
|
||||||
with:
|
with:
|
||||||
path: dist
|
path: dist
|
||||||
pattern: app-*
|
pattern: app-*
|
||||||
|
|||||||
@@ -208,9 +208,9 @@ origin.
|
|||||||
| Screenshots | `node scripts/capture-screenshots.mjs` (needs a local Chrome or Edge, driven through `playwright-core` from `npm install`; `PLAN2CODE_TEST_BROWSER=chrome|msedge` forces one) |
|
| Screenshots | `node scripts/capture-screenshots.mjs` (needs a local Chrome or Edge, driven through `playwright-core` from `npm install`; `PLAN2CODE_TEST_BROWSER=chrome|msedge` forces one) |
|
||||||
| Dependencies | none at runtime. `marked` 15.0.7 (MIT) is vendored for its lexer only, and CodeMirror 6 (MIT) for the notebook's editor as one bundled file, `public/vendor/codemirror.esm.js`, made by the dev-only `node scripts/vendor-codemirror.mjs` from a pinned lock (about 500 KB, loaded only when the Notebook is first opened); the page's policy blocks the `<style>` element CodeMirror writes, so the editor lives in a shadow root where it adopts its rules as a constructed stylesheet (steps in the architecture doc's Notebook point) |
|
| Dependencies | none at runtime. `marked` 15.0.7 (MIT) is vendored for its lexer only, and CodeMirror 6 (MIT) for the notebook's editor as one bundled file, `public/vendor/codemirror.esm.js`, made by the dev-only `node scripts/vendor-codemirror.mjs` from a pinned lock (about 500 KB, loaded only when the Notebook is first opened); the page's policy blocks the `<style>` element CodeMirror writes, so the editor lives in a shadow root where it adopts its rules as a constructed stylesheet (steps in the architecture doc's Notebook point) |
|
||||||
|
|
||||||
Edit `src/` only. `skills/` is a committed build artifact: regenerate it with
|
Edit `src/` only. `skills/` is gitignored build output: the installer and
|
||||||
`npm run build:skills` and commit it with the source change, since `npm test`
|
`npm test` (via `--build-skills`) regenerate it, and `npm run build:skills`
|
||||||
(via `--verify-skills`) fails when it drifts from `src/`.
|
rebuilds it by hand.
|
||||||
|
|
||||||
### Driving it by hand
|
### Driving it by hand
|
||||||
|
|
||||||
|
|||||||
@@ -4,6 +4,26 @@ All notable changes to Plan2Code will be documented in this file.
|
|||||||
|
|
||||||
<!-- Format from 3.1.0 on: `## vX.Y.Z (YYYY-MM-DD)` with the date from version.json; a minor release opens with a three-bullet `### Highlights`; sections run Added, Changed, Fixed; game changes sit under one Activities line; tooling and test lines go under "For contributors". Older headings have no date and are not backfilled. -->
|
<!-- Format from 3.1.0 on: `## vX.Y.Z (YYYY-MM-DD)` with the date from version.json; a minor release opens with a three-bullet `### Highlights`; sections run Added, Changed, Fixed; game changes sit under one Activities line; tooling and test lines go under "For contributors". Older headings have no date and are not backfilled. -->
|
||||||
|
|
||||||
|
## v3.1.3 (2026-11-18)
|
||||||
|
|
||||||
|
### 🔧 Changed
|
||||||
|
|
||||||
|
- **For contributors**: the CI workflows use the Node.js 24 versions of the checkout, setup-node and artifact actions, two tests that always failed on macOS are fixed, and four page tests no longer depend on redraw timing.
|
||||||
|
|
||||||
|
### 🐛 Fixed
|
||||||
|
|
||||||
|
- **web console**: on a finished screen, a press that nothing ever collects now shows its way out (Start a New Session in the app, or the command to run in a browser) together with the "Plan2Code is not running" line; before, it appeared only if something else happened to redraw the card.
|
||||||
|
|
||||||
|
## v3.1.2 (2026-11-18)
|
||||||
|
|
||||||
|
### 🔧 Changed
|
||||||
|
|
||||||
|
- **web console**: the git board now walks you through four steps, Save, Share, Review and Tidy, with one task card for the step you are on; the Changes, Branches and Sync tabs are folded into **All branches and tools**.
|
||||||
|
|
||||||
|
### 🐛 Fixed
|
||||||
|
|
||||||
|
- **installer**: an install, update or uninstall started by a launcher older than the release channel, or by an install command copied from an older README, no longer gets unfinished work from `main`: the installer notices, says so and switches to the newest release. `plan2code update --main` still takes `main`.
|
||||||
|
|
||||||
## v3.1.1 (2026-11-17)
|
## v3.1.1 (2026-11-17)
|
||||||
|
|
||||||
### ✨ Added
|
### ✨ Added
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
|
|
||||||
Plan2Code is a spec-driven workflow for AI coding agents. You work through it on a page in your browser: the dashboard lists every step as a card, and each step's questions, progress and sign-offs arrive on that same page while your agent does the work. An approved plan becomes phase documents, and the agent builds to them one phase at a time.
|
Plan2Code is a spec-driven workflow for AI coding agents. You work through it on a page in your browser: the dashboard lists every step as a card, and each step's questions, progress and sign-offs arrive on that same page while your agent does the work. An approved plan becomes phase documents, and the agent builds to them one phase at a time.
|
||||||
|
|
||||||
Version 3.1.1 · Apache 2.0 · 📖 [plan2code.jparkerweb.com](https://plan2code.jparkerweb.com)
|
Version 3.1.3 · Apache 2.0 · 📖 [plan2code.jparkerweb.com](https://plan2code.jparkerweb.com)
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
+95
-11
@@ -3817,20 +3817,90 @@ async function update({ steps = UPDATE_STEPS, cleanShims = removeLegacyLoopShims
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ============================================================================
|
||||||
|
// RELEASE REDIRECT
|
||||||
|
// ============================================================================
|
||||||
|
//
|
||||||
|
// Launchers older than the release channel run `plan2code update` (and uninstall) as
|
||||||
|
// `npx git+<repo> --update`, which is the tip of main, and so does an install command copied from
|
||||||
|
// an older README. Without this, those people would get unreleased work. When this copy came from
|
||||||
|
// an npx fetch of a commit that no `vX.Y.Z` tag points at, it hands the same command to the
|
||||||
|
// newest release instead. Any run the current launcher starts says which ref it picked on purpose
|
||||||
|
// (PLAN2CODE_INSTALL_REF, `--main` included), and a checkout (`node install.js`) is never under
|
||||||
|
// node_modules, so neither is redirected. Anything unknown (no lock file, no network) also means
|
||||||
|
// no redirect: the run goes on exactly as before.
|
||||||
|
|
||||||
|
/** The commit npx fetched this copy from (from npm's hidden lock file beside it), or null. */
|
||||||
|
function fetchedCommit(dir = __dirname) {
|
||||||
|
const modules = path.dirname(dir);
|
||||||
|
if (path.basename(modules) !== 'node_modules') return null;
|
||||||
|
try {
|
||||||
|
const lock = JSON.parse(fs.readFileSync(path.join(modules, '.package-lock.json'), 'utf8'));
|
||||||
|
const entry = lock && lock.packages && lock.packages[`node_modules/${path.basename(dir)}`];
|
||||||
|
const m = entry && typeof entry.resolved === 'string' ? /#([0-9a-f]{40})$/i.exec(entry.resolved) : null;
|
||||||
|
return m ? m[1].toLowerCase() : null;
|
||||||
|
} catch {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The release tag to hand this run to, as `vX.Y.Z`, or null to run here. `lsRemote` is
|
||||||
|
* `git ls-remote --tags` output and `newest` its newest release (update-check.mjs's pick). A
|
||||||
|
* commit any release tag points at (peeled or not) stays, so an older launcher's
|
||||||
|
* `update --tag v3.0.2` and the `#release` branch are left alone.
|
||||||
|
*/
|
||||||
|
function releaseRedirectRef({ commit, lsRemote, newest, env = process.env }) {
|
||||||
|
if (env.PLAN2CODE_INSTALL_REF || !commit || !newest || typeof lsRemote !== 'string') return null;
|
||||||
|
for (const line of lsRemote.split(/\r?\n/)) {
|
||||||
|
const m = /^([0-9a-f]{40})\s+refs\/tags\/v\d+\.\d+\.\d+(\^\{\})?$/i.exec(line.trim());
|
||||||
|
if (m && m[1].toLowerCase() === commit) return null;
|
||||||
|
}
|
||||||
|
return `v${newest}`;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Run the newest release's installer with the same options when this copy is unreleased work
|
||||||
|
* fetched by an older launcher. Resolves the child's exit code, or null to carry on here.
|
||||||
|
*/
|
||||||
|
async function redirectToRelease(argv) {
|
||||||
|
if (!argv.every((a) => /^--[a-z]+$/.test(a))) return null;
|
||||||
|
const commit = fetchedCommit();
|
||||||
|
if (!commit || process.env.PLAN2CODE_INSTALL_REF) return null;
|
||||||
|
let ref = null;
|
||||||
|
try {
|
||||||
|
const checker = await import(pathToFileURL(UPDATE_CHECK_SRC).href);
|
||||||
|
const stub = process.env.PLAN2CODE_LS_REMOTE_FILE;
|
||||||
|
const lsRemote = stub ? fs.readFileSync(stub, 'utf8') : await checker.runLsRemote();
|
||||||
|
ref = releaseRedirectRef({ commit, lsRemote, newest: checker.latestTag(lsRemote) });
|
||||||
|
} catch {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
if (!ref) return null;
|
||||||
|
console.log(`This installer is unreleased work from main, so Plan2Code is switching to the newest release, ${ref}.`);
|
||||||
|
console.log(`${COLORS.DIM}Fetching it can take a minute or two.${COLORS.RESET}`);
|
||||||
|
const command = ['npx', '--yes', '--allow-git=all', `git+https://github.com/jparkerweb/plan2code.git#${ref}`, ...argv].join(' ');
|
||||||
|
return new Promise((resolve) => {
|
||||||
|
let child;
|
||||||
|
try {
|
||||||
|
child = spawn(command, { shell: true, stdio: 'inherit', env: { ...process.env, PLAN2CODE_INSTALL_REF: ref } });
|
||||||
|
} catch {
|
||||||
|
resolve(null);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// The child owns the terminal now: Ctrl+C reaches it, and this process waits for its code.
|
||||||
|
for (const signal of ['SIGINT', 'SIGTERM', 'SIGHUP']) process.on(signal, () => {});
|
||||||
|
child.on('error', () => resolve(null));
|
||||||
|
child.on('exit', (code) => resolve(code ?? 1));
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
// ============================================================================
|
// ============================================================================
|
||||||
// MAIN
|
// MAIN
|
||||||
// ============================================================================
|
// ============================================================================
|
||||||
|
|
||||||
// Run only when invoked directly; requiring the file (the update tests do) is load-only.
|
function runCommand(argv) {
|
||||||
if (require.main === module) {
|
if (argv[0] === '--update' && argv.slice(1).every((a) => a === '--force')) {
|
||||||
// Non-interactive build hooks for the generated skills/ artifact.
|
|
||||||
const argv = process.argv.slice(2);
|
|
||||||
|
|
||||||
if (argv.includes('--build-skills')) {
|
|
||||||
process.exit(buildSkills() ? 0 : 1);
|
|
||||||
} else if (argv.includes('--verify-skills')) {
|
|
||||||
process.exit(verifySkillsSync() ? 0 : 1);
|
|
||||||
} else if (argv[0] === '--update' && argv.slice(1).every((a) => a === '--force')) {
|
|
||||||
update({ force: argv.includes('--force') }).then((code) => process.exit(code));
|
update({ force: argv.includes('--force') }).then((code) => process.exit(code));
|
||||||
} else if (argv[0] === '--uninstall' && argv.slice(1).every((a) => a === '--yes' || a === '--purge')) {
|
} else if (argv[0] === '--uninstall' && argv.slice(1).every((a) => a === '--yes' || a === '--purge')) {
|
||||||
uninstall({ yes: argv.includes('--yes'), purge: argv.includes('--purge') }).then((code) => process.exit(code));
|
uninstall({ yes: argv.includes('--yes'), purge: argv.includes('--purge') }).then((code) => process.exit(code));
|
||||||
@@ -3844,4 +3914,18 @@ if (require.main === module) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = { printKeptData, uninstallSkillsPiece, removeSkillsDirectly, removeConsoleFolders, uninstallStatusLine, listKeptData, newUninstallReport, printUninstallReport, UNINSTALL_STEPS, UNINSTALL_PROBES, PIECE_LABELS, createSpinner, printGettingStarted, pathFixLine, fullCommandPath, desktopAppState, detectAgents, agentInstallLine, writeLauncherShim, isOurLauncherShim, LAUNCHER_MARKER, NO_TERMINAL_MESSAGE, appAllowLine, APP_GUIDE_URL, formatBytes, nodeVersionProblem, appWebviewDirs, purgeAppWebview, appRunning, uninstall, uninstallAll, purgeData, installSharedConsole, sweepOldConsoles, consoleHomeDir, CONSOLE_SHARED_DIR, update, installDesktopApp, offerDesktopApp, recordSkipped, appAssetName, checksumFor, APP_DEST, UPDATE_STEPS, INSTALL_RECORD, INSTALL_PIECES, readInstallRecord, recordInstalled, forgetInstalled, SOURCE_PROMPTS, generateSkillName };
|
// Run only when invoked directly; requiring the file (the update tests do) is load-only.
|
||||||
|
if (require.main === module) {
|
||||||
|
const argv = process.argv.slice(2);
|
||||||
|
|
||||||
|
// Non-interactive build hooks for the generated skills/ artifact.
|
||||||
|
if (argv.includes('--build-skills')) {
|
||||||
|
process.exit(buildSkills() ? 0 : 1);
|
||||||
|
} else if (argv.includes('--verify-skills')) {
|
||||||
|
process.exit(verifySkillsSync() ? 0 : 1);
|
||||||
|
} else {
|
||||||
|
redirectToRelease(argv).then((code) => (code === null ? runCommand(argv) : process.exit(code)));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module.exports = { fetchedCommit, releaseRedirectRef, printKeptData, uninstallSkillsPiece, removeSkillsDirectly, removeConsoleFolders, uninstallStatusLine, listKeptData, newUninstallReport, printUninstallReport, UNINSTALL_STEPS, UNINSTALL_PROBES, PIECE_LABELS, createSpinner, printGettingStarted, pathFixLine, fullCommandPath, desktopAppState, detectAgents, agentInstallLine, writeLauncherShim, isOurLauncherShim, LAUNCHER_MARKER, NO_TERMINAL_MESSAGE, appAllowLine, APP_GUIDE_URL, formatBytes, nodeVersionProblem, appWebviewDirs, purgeAppWebview, appRunning, uninstall, uninstallAll, purgeData, installSharedConsole, sweepOldConsoles, consoleHomeDir, CONSOLE_SHARED_DIR, update, installDesktopApp, offerDesktopApp, recordSkipped, appAssetName, checksumFor, APP_DEST, UPDATE_STEPS, INSTALL_RECORD, INSTALL_PIECES, readInstallRecord, recordInstalled, forgetInstalled, SOURCE_PROMPTS, generateSkillName };
|
||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "plan2code",
|
"name": "plan2code",
|
||||||
"version": "3.1.1",
|
"version": "3.1.3",
|
||||||
"private": true,
|
"private": true,
|
||||||
"license": "Apache-2.0",
|
"license": "Apache-2.0",
|
||||||
"engines": {
|
"engines": {
|
||||||
|
|||||||
Generated
+2
-2
@@ -957,7 +957,7 @@ dependencies = [
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "fake-agent"
|
name = "fake-agent"
|
||||||
version = "3.1.1"
|
version = "3.1.3"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"serde_json",
|
"serde_json",
|
||||||
"terminal_size",
|
"terminal_size",
|
||||||
@@ -2647,7 +2647,7 @@ checksum = "f6b464fbc74e149a392436b17d523f769e057cb6877f6a5c4618bc6f11800548"
|
|||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "plan2code-app"
|
name = "plan2code-app"
|
||||||
version = "3.1.1"
|
version = "3.1.3"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"chrono",
|
"chrono",
|
||||||
"libc",
|
"libc",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "fake-agent"
|
name = "fake-agent"
|
||||||
version = "3.1.1"
|
version = "3.1.3"
|
||||||
description = "A stand-in agent program for the Plan2Code app's tests"
|
description = "A stand-in agent program for the Plan2Code app's tests"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
publish = false
|
publish = false
|
||||||
|
|||||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "plan2code-app",
|
"name": "plan2code-app",
|
||||||
"version": "3.1.1",
|
"version": "3.1.3",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "plan2code-app",
|
"name": "plan2code-app",
|
||||||
"version": "3.1.1",
|
"version": "3.1.3",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@tauri-apps/api": "2.12.4",
|
"@tauri-apps/api": "2.12.4",
|
||||||
"@xterm/addon-fit": "0.11.0",
|
"@xterm/addon-fit": "0.11.0",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "plan2code-app",
|
"name": "plan2code-app",
|
||||||
"version": "3.1.1",
|
"version": "3.1.3",
|
||||||
"private": true,
|
"private": true,
|
||||||
"description": "Plan2Code desktop app (Tauri). Separate from the repo root so the root and the web console stay dependency-free.",
|
"description": "Plan2Code desktop app (Tauri). Separate from the repo root so the root and the web console stay dependency-free.",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
[package]
|
[package]
|
||||||
name = "plan2code-app"
|
name = "plan2code-app"
|
||||||
version = "3.1.1"
|
version = "3.1.3"
|
||||||
description = "Plan2Code desktop app"
|
description = "Plan2Code desktop app"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
publish = false
|
publish = false
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"$schema": "https://schema.tauri.app/config/2",
|
"$schema": "https://schema.tauri.app/config/2",
|
||||||
"productName": "Plan2Code",
|
"productName": "Plan2Code",
|
||||||
"version": "3.1.1",
|
"version": "3.1.3",
|
||||||
"identifier": "com.plan2code.desktop",
|
"identifier": "com.plan2code.desktop",
|
||||||
"build": {
|
"build": {
|
||||||
"frontendDist": "../ui",
|
"frontendDist": "../ui",
|
||||||
|
|||||||
@@ -312,6 +312,93 @@ test("install.js --update: an option other than --force is refused", () => {
|
|||||||
assert.match(refused.stderr, /Unknown option\(s\): --update --nope/);
|
assert.match(refused.stderr, /Unknown option\(s\): --update --nope/);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const SHA_RELEASE = "a".repeat(40);
|
||||||
|
const SHA_OLD_RELEASE = "b".repeat(40);
|
||||||
|
const SHA_MAIN = "c".repeat(40);
|
||||||
|
const TAGS = [`${SHA_OLD_RELEASE}\trefs/tags/v3.0.2`, `${SHA_RELEASE}\trefs/tags/v3.1.2`, `${"d".repeat(40)}\trefs/tags/nightly`].join("\n");
|
||||||
|
|
||||||
|
test("release redirect: unreleased work goes to the newest release; a release commit, a chosen ref or an unknown stays", () => {
|
||||||
|
const ref = (commit, extra = {}) => installer.releaseRedirectRef({ commit, lsRemote: TAGS, newest: "3.1.2", env: {}, ...extra });
|
||||||
|
assert.equal(ref(SHA_MAIN), "v3.1.2");
|
||||||
|
assert.equal(ref(SHA_RELEASE), null, "the newest release (and the release branch on it) stays");
|
||||||
|
assert.equal(ref(SHA_OLD_RELEASE), null, "an older launcher's update --tag v3.0.2 stays on v3.0.2");
|
||||||
|
assert.equal(ref("d".repeat(40)), "v3.1.2", "a tag that is not vX.Y.Z is not a release");
|
||||||
|
assert.equal(ref(SHA_MAIN, { env: { PLAN2CODE_INSTALL_REF: "main" } }), null, "the current launcher's --main stays on main");
|
||||||
|
assert.equal(ref(null), null);
|
||||||
|
assert.equal(ref(SHA_MAIN, { newest: null }), null);
|
||||||
|
assert.equal(ref(SHA_MAIN, { lsRemote: null }), null);
|
||||||
|
// An annotated tag's commit is on its peeled line.
|
||||||
|
assert.equal(ref(SHA_MAIN, { lsRemote: `${"e".repeat(40)}\trefs/tags/v3.1.2\n${SHA_MAIN}\trefs/tags/v3.1.2^{}` }), null);
|
||||||
|
});
|
||||||
|
|
||||||
|
/** install.js laid out as npx leaves a git package: node_modules/plan2code beside npm's hidden lock file. */
|
||||||
|
function npxCopy(commit) {
|
||||||
|
const dir = fs.mkdtempSync(path.join(os.tmpdir(), "p2c-npx-copy-"));
|
||||||
|
const pkg = path.join(dir, "node_modules", "plan2code");
|
||||||
|
fs.mkdirSync(path.join(pkg, "src", "web-console"), { recursive: true });
|
||||||
|
fs.copyFileSync(INSTALL, path.join(pkg, "install.js"));
|
||||||
|
fs.copyFileSync(path.join(ROOT, "version.json"), path.join(pkg, "version.json"));
|
||||||
|
fs.copyFileSync(path.join(ROOT, "src", "web-console", "update-check.mjs"), path.join(pkg, "src", "web-console", "update-check.mjs"));
|
||||||
|
if (commit) {
|
||||||
|
const resolved = `git+ssh://git@github.com/jparkerweb/plan2code.git#${commit}`;
|
||||||
|
fs.writeFileSync(path.join(dir, "node_modules", ".package-lock.json"), JSON.stringify({ packages: { "node_modules/plan2code": { version: VERSION, resolved } } }));
|
||||||
|
}
|
||||||
|
fs.writeFileSync(path.join(dir, "ls-remote.txt"), TAGS + "\n");
|
||||||
|
// A stand-in npx that records its arguments and the ref the redirect handed it.
|
||||||
|
const bin = path.join(dir, "bin");
|
||||||
|
fs.mkdirSync(bin);
|
||||||
|
const recorder = path.join(bin, "record.js");
|
||||||
|
fs.writeFileSync(
|
||||||
|
recorder,
|
||||||
|
'require("fs").writeFileSync(require("path").join(__dirname, "npx.json"), JSON.stringify({ args: process.argv.slice(2), ref: process.env.PLAN2CODE_INSTALL_REF }));\nprocess.exitCode = 5;\n'
|
||||||
|
);
|
||||||
|
if (process.platform === "win32") fs.writeFileSync(path.join(bin, "npx.cmd"), `@"${process.execPath}" "${recorder}" %*\r\n`);
|
||||||
|
else {
|
||||||
|
fs.writeFileSync(path.join(bin, "npx"), `#!/bin/sh\nexec "${process.execPath}" "${recorder}" "$@"\n`);
|
||||||
|
fs.chmodSync(path.join(bin, "npx"), 0o755);
|
||||||
|
}
|
||||||
|
const run = (args, env = {}) => {
|
||||||
|
const runEnv = { ...process.env, HOME, USERPROFILE: HOME, PLAN2CODE_LS_REMOTE_FILE: path.join(dir, "ls-remote.txt"), ...env };
|
||||||
|
delete runEnv.PLAN2CODE_INSTALL_REF;
|
||||||
|
for (const key of Object.keys(runEnv)) if (key.toUpperCase() === "PATH") delete runEnv[key];
|
||||||
|
runEnv.PATH = bin + path.delimiter + (process.env.PATH || process.env.Path || "");
|
||||||
|
Object.assign(runEnv, env);
|
||||||
|
return spawnSync(process.execPath, [path.join(pkg, "install.js"), ...args], { encoding: "utf8", env: runEnv, input: "" });
|
||||||
|
};
|
||||||
|
const npx = () => (fs.existsSync(path.join(bin, "npx.json")) ? JSON.parse(fs.readFileSync(path.join(bin, "npx.json"), "utf8")) : null);
|
||||||
|
return { dir, run, npx, cleanup: () => fs.rmSync(dir, { recursive: true, force: true }) };
|
||||||
|
}
|
||||||
|
|
||||||
|
test("release redirect: an old launcher's update from main runs the newest release's installer with the same options", (t) => {
|
||||||
|
const copy = npxCopy(SHA_MAIN);
|
||||||
|
t.after(copy.cleanup);
|
||||||
|
const result = copy.run(["--update", "--force"]);
|
||||||
|
assert.equal(result.status, 5, "the release installer's exit code is passed through\n" + result.stderr);
|
||||||
|
assert.match(result.stdout, /switching to the newest release, v3\.1\.2/);
|
||||||
|
const { args, ref } = copy.npx();
|
||||||
|
assert.deepEqual(args, ["--yes", "--allow-git=all", "git+https://github.com/jparkerweb/plan2code.git#v3.1.2", "--update", "--force"]);
|
||||||
|
assert.equal(ref, "v3.1.2", "the handed-off run is marked, so it never redirects again");
|
||||||
|
});
|
||||||
|
|
||||||
|
test("release redirect: a release copy, a run the launcher chose, or a copy with no lock file is not redirected", (t) => {
|
||||||
|
for (const [commit, env] of [[SHA_RELEASE, {}], [SHA_MAIN, { PLAN2CODE_INSTALL_REF: "main" }], [null, {}]]) {
|
||||||
|
const copy = npxCopy(commit);
|
||||||
|
t.after(copy.cleanup);
|
||||||
|
// An unknown option shows the run carried on here: the usage error, and no npx.
|
||||||
|
const result = copy.run(["--update", "--nope"], env);
|
||||||
|
assert.equal(result.status, 1, result.stdout + result.stderr);
|
||||||
|
assert.match(result.stderr, /Unknown option\(s\)/);
|
||||||
|
assert.equal(copy.npx(), null);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
test("release redirect: an interactive install from main is handed to the newest release too", (t) => {
|
||||||
|
const copy = npxCopy(SHA_MAIN);
|
||||||
|
t.after(copy.cleanup);
|
||||||
|
assert.equal(copy.run([]).status, 5);
|
||||||
|
assert.deepEqual(copy.npx().args.slice(-1), ["git+https://github.com/jparkerweb/plan2code.git#v3.1.2"]);
|
||||||
|
});
|
||||||
|
|
||||||
test("update: the real status line step keeps a custom statusLine without asking", async () => {
|
test("update: the real status line step keeps a custom statusLine without asking", async () => {
|
||||||
const claudeDir = path.join(HOME, ".claude");
|
const claudeDir = path.join(HOME, ".claude");
|
||||||
const settingsFile = path.join(claudeDir, "settings.json");
|
const settingsFile = path.join(claudeDir, "settings.json");
|
||||||
|
|||||||
@@ -58,6 +58,8 @@ function sandbox(clis, { installed, project = true, lookup = true, agents } = {}
|
|||||||
fs.writeFileSync(
|
fs.writeFileSync(
|
||||||
recorder,
|
recorder,
|
||||||
'require("fs").writeFileSync(require("path").join(__dirname, process.argv[2] + ".json"), JSON.stringify(process.argv.slice(3)));\n' +
|
'require("fs").writeFileSync(require("path").join(__dirname, process.argv[2] + ".json"), JSON.stringify(process.argv.slice(3)));\n' +
|
||||||
|
// The ref the launcher marks its installer runs with, so install.js never redirects them.
|
||||||
|
'if (process.env.PLAN2CODE_INSTALL_REF) require("fs").writeFileSync(require("path").join(__dirname, process.argv[2] + ".ref"), process.env.PLAN2CODE_INSTALL_REF);\n' +
|
||||||
"process.exitCode = Number(process.env.P2C_TEST_EXIT || 0);\n"
|
"process.exitCode = Number(process.env.P2C_TEST_EXIT || 0);\n"
|
||||||
);
|
);
|
||||||
for (const cli of clis) {
|
for (const cli of clis) {
|
||||||
@@ -503,6 +505,7 @@ test("launcher: update installs the newest release tag, by version and not by na
|
|||||||
assert.ok(args.includes("--update"), args.join(" "));
|
assert.ok(args.includes("--update"), args.join(" "));
|
||||||
assert.ok(args.includes(`${REPO}#v3.10.0`), args.join(" "));
|
assert.ok(args.includes(`${REPO}#v3.10.0`), args.join(" "));
|
||||||
assert.ok(!args.includes("--force"), args.join(" "));
|
assert.ok(!args.includes("--force"), args.join(" "));
|
||||||
|
assert.equal(fs.readFileSync(path.join(box.dir, "bin", "npx.ref"), "utf8"), "v3.10.0", "the run is marked with the ref it picked");
|
||||||
assert.equal(box.argsOf("claude"), null);
|
assert.equal(box.argsOf("claude"), null);
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -518,6 +521,8 @@ test("launcher: update --main installs the tip of main, as it always did", (t) =
|
|||||||
// Unreleased work on main carries the last release's version, so the installer's "Already on"
|
// Unreleased work on main carries the last release's version, so the installer's "Already on"
|
||||||
// check would stop it: --main always reinstalls.
|
// check would stop it: --main always reinstalls.
|
||||||
assert.ok(args.includes("--force"), args.join(" "));
|
assert.ok(args.includes("--force"), args.join(" "));
|
||||||
|
// Marked as chosen, so install.js's redirect for older launchers leaves it on main.
|
||||||
|
assert.equal(fs.readFileSync(path.join(box.dir, "bin", "npx.ref"), "utf8"), "main");
|
||||||
});
|
});
|
||||||
|
|
||||||
test("launcher: update --tag reinstalls for a branch, and not for a release tag", (t) => {
|
test("launcher: update --tag reinstalls for a branch, and not for a release tag", (t) => {
|
||||||
|
|||||||
@@ -374,7 +374,8 @@ test("wait reads --seconds 6s as six seconds, not as nothing", () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
test("only an installed console's open leaves the console-dir pointer; status, help, a bad command and a source checkout's open do not", () => {
|
test("only an installed console's open leaves the console-dir pointer; status, help, a bad command and a source checkout's open do not", () => {
|
||||||
const home = fs.mkdtempSync(path.join(os.tmpdir(), "p2c-pointer-"));
|
// macOS hands out a temp folder under the /var link, and the console writes the real path.
|
||||||
|
const home = fs.realpathSync(fs.mkdtempSync(path.join(os.tmpdir(), "p2c-pointer-")));
|
||||||
const env = { PLAN2CODE_CONSOLE_HOME: home, PLAN2CODE_MODELS_DIR: path.join(home, "plan2code") };
|
const env = { PLAN2CODE_CONSOLE_HOME: home, PLAN2CODE_MODELS_DIR: path.join(home, "plan2code") };
|
||||||
const pointer = path.join(home, "console-dir");
|
const pointer = path.join(home, "console-dir");
|
||||||
fs.writeFileSync(path.join(home, "update-check.json"), JSON.stringify({ checkedAt: Date.now(), latest: null }));
|
fs.writeFileSync(path.join(home, "update-check.json"), JSON.stringify({ checkedAt: Date.now(), latest: null }));
|
||||||
|
|||||||
@@ -96,7 +96,7 @@ test("a press in the empty part of the answer box selects like a textarea: Shift
|
|||||||
const range = () => host.evaluate((el) => [el.field.selectionStart, el.field.selectionEnd]);
|
const range = () => host.evaluate((el) => [el.field.selectionStart, el.field.selectionEnd]);
|
||||||
const box = await host.boundingBox();
|
const box = await host.boundingBox();
|
||||||
const low = { x: box.x + box.width / 2, y: box.y + box.height - 12 };
|
const low = { x: box.x + box.width / 2, y: box.y + box.height - 12 };
|
||||||
assert.equal(await host.evaluate((el) => getComputedStyle(el).cursor), "text", "the whole box shows the text pointer");
|
assert.equal(await styleOf(host, "cursor"), "text", "the whole box shows the text pointer");
|
||||||
|
|
||||||
await s.page.keyboard.press("Home");
|
await s.page.keyboard.press("Home");
|
||||||
// page.mouse takes no modifiers option: hold Shift on the keyboard.
|
// page.mouse takes no modifiers option: hold Shift on the keyboard.
|
||||||
@@ -621,7 +621,7 @@ test("a note box over the git board grows no box, and the card flows at its own
|
|||||||
project: dir,
|
project: dir,
|
||||||
payload: { reread: true, board: { describe: "export-more" }, items: [confirm] },
|
payload: { reread: true, board: { describe: "export-more" }, items: [confirm] },
|
||||||
});
|
});
|
||||||
await git.page.getByRole("tablist").waitFor();
|
await git.page.locator(".git-step").first().waitFor();
|
||||||
const gitCard = itemCard(git.page, "y1");
|
const gitCard = itemCard(git.page, "y1");
|
||||||
await gitCard.waitFor();
|
await gitCard.waitFor();
|
||||||
const note = gitCard.locator(".md-host").first();
|
const note = gitCard.locator(".md-host").first();
|
||||||
|
|||||||
@@ -91,6 +91,14 @@ test("each git tab keeps its own scroll place, across a tab switch and an agent
|
|||||||
await tab("Changes").click();
|
await tab("Changes").click();
|
||||||
await page.getByRole("tabpanel").getByText(/in the Save step above/).waitFor();
|
await page.getByRole("tabpanel").getByText(/in the Save step above/).waitFor();
|
||||||
await scrollCard(page.locator("#main"), 120);
|
await scrollCard(page.locator("#main"), 120);
|
||||||
|
// The tabs sit below this short window, so a click on one scrolls the column to it first:
|
||||||
|
// a scroll like the person's own, which the board notes. Make it now and give the page a
|
||||||
|
// moment to note it, so the place Changes is left at is known before the switch.
|
||||||
|
// Done in the page in one step: a redraw may swap the tab for a new one at any moment.
|
||||||
|
await page.evaluate(() => {
|
||||||
|
document.getElementById("git-tab-branches").scrollIntoView({ block: "center" });
|
||||||
|
return new Promise((r) => requestAnimationFrame(() => requestAnimationFrame(r)));
|
||||||
|
});
|
||||||
const changesAt = await column();
|
const changesAt = await column();
|
||||||
assert.ok(changesAt > 0, "the board's column scrolls");
|
assert.ok(changesAt > 0, "the board's column scrolls");
|
||||||
// Another tab opens at its own place, not where Changes was left.
|
// Another tab opens at its own place, not where Changes was left.
|
||||||
|
|||||||
@@ -544,7 +544,7 @@ test("each tab keeps its own text and pictures, and switching never saves into t
|
|||||||
const notes = idOf(s, "Notes");
|
const notes = idOf(s, "Notes");
|
||||||
const ideas = idOf(s, "Ideas");
|
const ideas = idOf(s, "Ideas");
|
||||||
// The new tab opens with its heading and the editor focused: clear it to start from empty.
|
// The new tab opens with its heading and the editor focused: clear it to start from empty.
|
||||||
await s.page.keyboard.press("Control+a");
|
await s.page.keyboard.press("ControlOrMeta+a");
|
||||||
await s.page.keyboard.press("Delete");
|
await s.page.keyboard.press("Delete");
|
||||||
await until(() => readNotepad(s.project, notes).text === "notes text" && readNotepad(s.project, ideas).text === "", 4000);
|
await until(() => readNotepad(s.project, notes).text === "notes text" && readNotepad(s.project, ideas).text === "", 4000);
|
||||||
await typeInto(s, "ideas text");
|
await typeInto(s, "ideas text");
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import test from "node:test";
|
|||||||
import assert from "node:assert/strict";
|
import assert from "node:assert/strict";
|
||||||
import fs from "node:fs";
|
import fs from "node:fs";
|
||||||
import path from "node:path";
|
import path from "node:path";
|
||||||
import { pageSuite, openSession, itemCard, drawn, textOf, tempProject , fillBox, boxValue, sendAsk, styleOf } from "./page-test-helpers.mjs";
|
import { pageSuite, openSession, itemCard, drawn, textOf, tempProject , fillBox, boxValue, sendAsk, styleOf, quiet } from "./page-test-helpers.mjs";
|
||||||
import { cli, until, HOME } from "./web-console-test-helpers.mjs";
|
import { cli, until, HOME } from "./web-console-test-helpers.mjs";
|
||||||
import { STOP_HANDOFF_REPLY, HOME_REPLY } from "../src/web-console/public/answers.js";
|
import { STOP_HANDOFF_REPLY, HOME_REPLY } from "../src/web-console/public/answers.js";
|
||||||
import { CHAT_OFFLINE_TEXT } from "../src/web-console/public/chat.js";
|
import { CHAT_OFFLINE_TEXT } from "../src/web-console/public/chat.js";
|
||||||
@@ -818,6 +818,10 @@ test("the quiet, not running and not connected lines offer What to check, openin
|
|||||||
// Answered and sent, never collected, and nobody listening: the saved line.
|
// Answered and sent, never collected, and nobody listening: the saved line.
|
||||||
await s.page.clock.setSystemTime(Date.now());
|
await s.page.clock.setSystemTime(Date.now());
|
||||||
s.post({ agent: { status: "waiting" } });
|
s.post({ agent: { status: "waiting" } });
|
||||||
|
// The post redraws the question: an answer typed before that redraw lands is lost with the
|
||||||
|
// old box, and Send then stays off. Wait for the page to show the post and go quiet.
|
||||||
|
await lineSays(s, /^Your turn: 1 question waiting\./);
|
||||||
|
await quiet(s.page);
|
||||||
await fillBox(itemCard(s.page, "q1").locator(".md-host, input[type=text]").first(), "audit-export");
|
await fillBox(itemCard(s.page, "q1").locator(".md-host, input[type=text]").first(), "audit-export");
|
||||||
await s.page.click("#btn-send");
|
await s.page.click("#btn-send");
|
||||||
await lineSays(s, /^Sent\. Waiting for Plan2Code\./);
|
await lineSays(s, /^Sent\. Waiting for Plan2Code\./);
|
||||||
@@ -1156,6 +1160,9 @@ async function strandedFinish(t, opts) {
|
|||||||
const main = s.page.locator("#main");
|
const main = s.page.locator("#main");
|
||||||
await main.getByRole("button", { name: "Review it now" }).click();
|
await main.getByRole("button", { name: "Review it now" }).click();
|
||||||
await main.getByRole("button", { name: "Review requested…" }).waitFor();
|
await main.getByRole("button", { name: "Review requested…" }).waitFor();
|
||||||
|
// Let the page hear the press is saved while it is still fresh, as it does for a person:
|
||||||
|
// the way out then has to appear by time alone, with no frame to draw it.
|
||||||
|
await quiet(s.page, { quietMs: 1000 });
|
||||||
await s.page.clock.fastForward(200_000);
|
await s.page.clock.fastForward(200_000);
|
||||||
await s.page.waitForFunction(() => document.body.innerText.includes("Plan2Code is not running"));
|
await s.page.waitForFunction(() => document.body.innerText.includes("Plan2Code is not running"));
|
||||||
return { s, main };
|
return { s, main };
|
||||||
|
|||||||
@@ -1700,6 +1700,7 @@ async function runUpdate({ tag, main, force } = {}) {
|
|||||||
}
|
}
|
||||||
console.log(ref === undefined ? 'Updating Plan2Code to the newest work on main...' : `Updating Plan2Code to ${ref}...`);
|
console.log(ref === undefined ? 'Updating Plan2Code to the newest work on main...' : `Updating Plan2Code to ${ref}...`);
|
||||||
console.log(c.dim('One update covers the skills, the plan2code command and the desktop app (when installed).'));
|
console.log(c.dim('One update covers the skills, the plan2code command and the desktop app (when installed).'));
|
||||||
|
console.log(c.dim('npx fetches it quietly first, which can take a minute or two.'));
|
||||||
const unreleased = main || (tag !== undefined && !/^v\d+\.\d+\.\d+$/.test(tag));
|
const unreleased = main || (tag !== undefined && !/^v\d+\.\d+\.\d+$/.test(tag));
|
||||||
return runInstaller(['--update', ...(force || unreleased ? ['--force'] : [])], ref);
|
return runInstaller(['--update', ...(force || unreleased ? ['--force'] : [])], ref);
|
||||||
}
|
}
|
||||||
@@ -1745,7 +1746,10 @@ function runInstaller(installerArgs, tag) {
|
|||||||
return process.exit(127);
|
return process.exit(127);
|
||||||
}
|
}
|
||||||
const spec = tag ? `git+${REPO_URL}#${tag}` : `git+${REPO_URL}`;
|
const spec = tag ? `git+${REPO_URL}#${tag}` : `git+${REPO_URL}`;
|
||||||
const child = spawnCommand(npx, ['--yes', '--allow-git=all', spec, ...installerArgs], { stdio: 'inherit' });
|
// The ref was picked on purpose (main included): install.js's release redirect, there for
|
||||||
|
// launchers older than the release channel, must leave this run where it is.
|
||||||
|
const env = { ...process.env, PLAN2CODE_INSTALL_REF: tag || 'main' };
|
||||||
|
const child = spawnCommand(npx, ['--yes', '--allow-git=all', spec, ...installerArgs], { stdio: 'inherit', env });
|
||||||
for (const signal of ['SIGINT', 'SIGTERM', 'SIGHUP']) {
|
for (const signal of ['SIGINT', 'SIGTERM', 'SIGHUP']) {
|
||||||
process.on(signal, () => {});
|
process.on(signal, () => {});
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -54,7 +54,7 @@ One-line JSON, only what changed; the patch merges (`items`, `topics`, `docs` an
|
|||||||
Every item: `id` (new for each question, whole session), `kind`, `title` (2 to 4 plain words), `body` (markdown: the question and why it matters), optional `topic`, `doc`, `required:false` (adds Skip), `token` (`{"A":"approved"}`: the typed word an answer stands for).
|
Every item: `id` (new for each question, whole session), `kind`, `title` (2 to 4 plain words), `body` (markdown: the question and why it matters), optional `topic`, `doc`, `required:false` (adds Skip), `token` (`{"A":"approved"}`: the typed word an answer stands for).
|
||||||
|
|
||||||
- `choice`: `{"id":"q1","kind":"choice","title":"Export format","body":"Which format?","options":[{"text":"CSV","detail":"Opens in Excel","recommended":true},{"text":"JSON","detail":"For scripts"}]}`. Back: `{k}` or `{text}`; `allowOther:false` drops the free-text row.
|
- `choice`: `{"id":"q1","kind":"choice","title":"Export format","body":"Which format?","options":[{"text":"CSV","detail":"Opens in Excel","recommended":true},{"text":"JSON","detail":"For scripts"}]}`. Back: `{k}` or `{text}`; `allowOther:false` drops the free-text row.
|
||||||
- `text`: `{"id":"q2","kind":"text","title":"Who uses it","body":"Who, and for what?","placeholder":"For example: reviewers, in Excel every Monday."}`. Back: `{text}`. `pattern` plus `patternHint` checks shape (kebab-case). The placeholder is an offer, so write a whole answer. On the fresh-idea card in Pathfinder, Plan and Quick Task add `"templates":"idea"` (also when the idea came as the argument, with a one-line summary in `placeholder`; a resumed map, PLAN-DRAFT or checkpoint gets no idea card; never mention templates in the terminal); a Notebook tab fills a box marked `"fill":"note"`.
|
- `text`: `{"id":"q2","kind":"text","title":"Who uses it","body":"Who, and for what?","placeholder":"For example: reviewers, in Excel every Monday."}`. Back: `{text}`. `pattern` plus `patternHint` checks shape (kebab-case). The placeholder is an offer: write a whole answer. On the fresh-idea card in Pathfinder, Plan and Quick Task add `"templates":"idea"` (also when the idea came as the argument, with a one-line summary in `placeholder`; a resumed map, PLAN-DRAFT or checkpoint gets no idea card; never mention templates in the terminal); a Notebook tab fills a box marked `"fill":"note"`.
|
||||||
- `confirm`: `{"id":"q3","kind":"confirm","title":"Keep going","body":"Continue?","yesLabel":"Yes","noLabel":"Not yet"}`. Back: `{yes,text?}`.
|
- `confirm`: `{"id":"q3","kind":"confirm","title":"Keep going","body":"Continue?","yesLabel":"Yes","noLabel":"Not yet"}`. Back: `{yes,text?}`.
|
||||||
- `recap`: `{"id":"q4","kind":"recap","title":"What we heard","body":"Is this right?","summary":"- ..."}`. Back: `{ok,text?}`.
|
- `recap`: `{"id":"q4","kind":"recap","title":"What we heard","body":"Is this right?","summary":"- ..."}`. Back: `{ok,text?}`.
|
||||||
- `menu`: `{"id":"q5","kind":"menu","title":"Next step","body":"What now?","options":[{"text":"Plan it"}],"command":"/plan2code-1-plan"}`. Back: `{k}`.
|
- `menu`: `{"id":"q5","kind":"menu","title":"Next step","body":"What now?","options":[{"text":"Plan it"}],"command":"/plan2code-1-plan"}`. Back: `{k}`.
|
||||||
@@ -65,7 +65,7 @@ Every item: `id` (new for each question, whole session), `kind`, `title` (2 to 4
|
|||||||
| `review` | read, then approve | `doc` (required), `summary`, `verdicts:[{id,label,danger?}]`, `nothingYet` (false once the change is on disk) | `{verdict,text?}` |
|
| `review` | read, then approve | `doc` (required), `summary`, `verdicts:[{id,label,danger?}]`, `nothingYet` (false once the change is on disk) | `{verdict,text?}` |
|
||||||
| `checklist` | steps only they can do | `steps`, `valuesLabel` | `{done?,state?,text?}` |
|
| `checklist` | steps only they can do | `steps`, `valuesLabel` | `{done?,state?,text?}` |
|
||||||
| `list` | reorder or edit a breakdown | `rows:[{id,title,body}]` | `{rows}` or `{text}` |
|
| `list` | reorder or edit a breakdown | `rows:[{id,title,body}]` | `{rows}` or `{text}` |
|
||||||
| `lessons` | approve noted lessons | `rows`, `opening`, `firstAsk` (from `lessons.mjs list`), `suggested` (row id to a choice: outlined, not picked) | `{decisions}` or `{firstAsk}` |
|
| `lessons` | approve lessons | `rows`, `opening`, `firstAsk` (`lessons.mjs list`), `suggested` | `{decisions}` or `{firstAsk}` |
|
||||||
| `notice` | read, no answer | none | none |
|
| `notice` | read, no answer | none | none |
|
||||||
|
|
||||||
Items show in the order sent, so send them in answering order.
|
Items show in the order sent, so send them in answering order.
|
||||||
|
|||||||
@@ -2616,6 +2616,7 @@ export function wireChrome() {
|
|||||||
// render and nothing was triggering one. Watch the flip and draw the rest.
|
// render and nothing was triggering one. Watch the flip and draw the rest.
|
||||||
let wasAdrift = false;
|
let wasAdrift = false;
|
||||||
let wasPastGrace = false;
|
let wasPastGrace = false;
|
||||||
|
let wasPressStranded = false;
|
||||||
|
|
||||||
export function startClock() {
|
export function startClock() {
|
||||||
setInterval(checkIn, 5000);
|
setInterval(checkIn, 5000);
|
||||||
@@ -2637,6 +2638,14 @@ export function startClock() {
|
|||||||
wasPastGrace = past;
|
wasPastGrace = past;
|
||||||
if (page.S) renderFooter();
|
if (page.S) renderFooter();
|
||||||
}
|
}
|
||||||
|
// A finished screen's press goes stranded by time alone, with no frame to say so: draw
|
||||||
|
// the card again so its way out (Start a New Session, or the command) appears with the
|
||||||
|
// status line that names it.
|
||||||
|
const strandedNow = pressStranded();
|
||||||
|
if (strandedNow !== wasPressStranded) {
|
||||||
|
wasPressStranded = strandedNow;
|
||||||
|
if (page.S) render();
|
||||||
|
}
|
||||||
// The agent coming or going changes whether the chat can be used, with no
|
// The agent coming or going changes whether the chat can be used, with no
|
||||||
// frame to say so: redraw the Ask pane when that flips. Even mid-typing:
|
// frame to say so: redraw the Ask pane when that flips. Even mid-typing:
|
||||||
// the draft is saved on every keystroke and withFocus() keeps the caret,
|
// the draft is saved on every keystroke and withFocus() keeps the caret,
|
||||||
|
|||||||
+1
-1
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "Plan2Code",
|
"name": "Plan2Code",
|
||||||
"version": "3.1.1",
|
"version": "3.1.3",
|
||||||
"description": "A structured workflow of six steps (Pathfinder, Plan, Document, Implement, Review, Finalize) for AI-assisted software development",
|
"description": "A structured workflow of six steps (Pathfinder, Plan, Document, Implement, Review, Finalize) for AI-assisted software development",
|
||||||
"keywords": [
|
"keywords": [
|
||||||
"ai",
|
"ai",
|
||||||
|
|||||||
Reference in new issue
Block a user