Files
vscode-cowriting-plugin/package.json
T
Ben Stull 911ed21671 #54 follow-up: pretest:e2e cleans out/test before recompiling
`tsc -p tsconfig.e2e.json` emits to `out/` but never removes outputs for test
sources absent on the current branch, so stale compiled
`out/test/e2e/suite/*.test.js` from other branches were picked up and run by the
suite glob (`**/*.test.js`) — this caused real cross-branch test confusion in
session 0048 (a deleted probe + another branch's tests ran on an unrelated branch).

Add a `clean:e2e` script (`fs.rmSync('out/test', {recursive, force})` via node, so
no shell `rm` dependency) and run it between `build` and `tsc` in `pretest:e2e`.
Cleans ONLY `out/test` — never `out/`, which holds the just-built esbuild bundle
(`out/extension.cjs`, `out/media`).

Verified: planting a stale `out/test/.../zz.test.js` then running `pretest:e2e`
removes it, and the E2E suite stays green (73 passing + 1 pending, both passes
exit 0).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-13 09:21:31 -07:00

232 lines
6.6 KiB
JSON

{
"name": "vscode-cowriting-plugin",
"displayName": "Cowriting (Cline SDK POC)",
"description": "Non-shippable POC: a standalone VS Code extension that drives @cline/sdk.",
"version": "0.0.1",
"private": true,
"license": "Apache-2.0",
"publisher": "benstull",
"engines": {
"vscode": "^1.90.0",
"node": ">=22"
},
"categories": [
"Other"
],
"main": "./out/extension.cjs",
"activationEvents": [
"onStartupFinished"
],
"contributes": {
"commands": [
{
"command": "cowriting.showClineSdkInfo",
"title": "Cowriting: Show Cline SDK Info",
"category": "Cowriting"
},
{
"command": "cowriting.createThread",
"title": "Cowriting: Add Coauthoring Thread on Selection",
"category": "Cowriting"
},
{
"command": "cowriting.reply",
"title": "Reply",
"category": "Cowriting"
},
{
"command": "cowriting.resolveThread",
"title": "Resolve Thread",
"category": "Cowriting"
},
{
"command": "cowriting.reopenThread",
"title": "Reopen Thread",
"category": "Cowriting"
},
{
"command": "cowriting.applyAgentEdit",
"title": "Apply Agent Edit (internal seam)",
"category": "Cowriting"
},
{
"command": "cowriting.editSelection",
"title": "Ask Claude to Edit Selection",
"category": "Cowriting"
},
{
"command": "cowriting.acceptProposal",
"title": "✓ Accept Proposal",
"category": "Cowriting"
},
{
"command": "cowriting.rejectProposal",
"title": "✗ Reject Proposal",
"category": "Cowriting"
},
{
"command": "cowriting.proposeAgentEdit",
"title": "Propose Agent Edit (internal seam)",
"category": "Cowriting"
},
{
"command": "cowriting.pinDiffBaseline",
"title": "Cowriting: Pin Review Baseline to Now",
"category": "Cowriting"
},
{
"command": "cowriting.showTrackChangesPreview",
"title": "Open Cowriting Review Panel",
"category": "Cowriting"
},
{
"command": "cowriting.editDocument",
"title": "Ask Claude to Edit Document",
"category": "Cowriting"
},
{
"command": "cowriting.acceptAllProposals",
"title": "Accept All Claude Proposals",
"category": "Cowriting"
}
],
"menus": {
"commandPalette": [
{
"command": "cowriting.applyAgentEdit",
"when": "false"
},
{
"command": "cowriting.proposeAgentEdit",
"when": "false"
},
{
"command": "cowriting.acceptProposal",
"when": "false"
},
{
"command": "cowriting.rejectProposal",
"when": "false"
},
{
"command": "cowriting.pinDiffBaseline",
"when": "editorLangId == markdown"
},
{
"command": "cowriting.editDocument",
"when": "editorLangId == markdown"
},
{
"command": "cowriting.acceptAllProposals",
"when": "editorLangId == markdown"
}
],
"editor/title": [
{
"command": "cowriting.showTrackChangesPreview",
"when": "editorLangId == markdown",
"group": "navigation@9"
}
],
"editor/title/context": [
{
"command": "cowriting.editSelection",
"when": "editorHasSelection && resourceLangId == markdown",
"group": "1_cowriting@1"
},
{
"command": "cowriting.editDocument",
"when": "!editorHasSelection && resourceLangId == markdown",
"group": "1_cowriting@1"
},
{
"command": "cowriting.showTrackChangesPreview",
"when": "resourceLangId == markdown",
"group": "1_cowriting@3"
}
],
"explorer/context": [
{
"command": "cowriting.showTrackChangesPreview",
"when": "resourceLangId == markdown",
"group": "navigation@9"
}
],
"editor/context": [
{
"command": "cowriting.editSelection",
"when": "editorHasSelection && editorLangId == markdown && (resourceScheme == file || resourceScheme == untitled)",
"group": "1_cowriting@1"
},
{
"command": "cowriting.editDocument",
"when": "!editorHasSelection && editorLangId == markdown && (resourceScheme == file || resourceScheme == untitled)",
"group": "1_cowriting@1"
},
{
"command": "cowriting.createThread",
"when": "editorHasSelection && (resourceScheme == file || resourceScheme == untitled)",
"group": "1_cowriting@2"
}
],
"comments/commentThread/context": [
{
"command": "cowriting.reply",
"group": "inline",
"when": "commentController == cowriting.threads"
}
],
"comments/commentThread/title": [
{
"command": "cowriting.resolveThread",
"group": "inline",
"when": "commentController == cowriting.threads && commentThread =~ /^open$/"
},
{
"command": "cowriting.reopenThread",
"group": "inline",
"when": "commentController == cowriting.threads && commentThread =~ /^resolved$/"
}
]
},
"keybindings": [
{
"command": "cowriting.showTrackChangesPreview",
"key": "ctrl+alt+r",
"when": "editorLangId == markdown"
}
]
},
"scripts": {
"build": "node esbuild.mjs",
"watch": "node esbuild.mjs --watch",
"typecheck": "tsc --noEmit",
"test": "vitest run",
"clean:e2e": "node -e \"require('fs').rmSync('out/test',{recursive:true,force:true})\"",
"pretest:e2e": "npm run build && npm run clean:e2e && tsc -p tsconfig.e2e.json",
"test:e2e": "node ./out/test/e2e/runTest.js",
"smoke:live": "npm run build && node scripts/smoke-live-turn.mjs",
"vscode:prepublish": "node esbuild.mjs"
},
"dependencies": {
"@cline/sdk": "0.0.46",
"diff": "^7.0.0",
"markdown-it": "^14.1.0",
"mermaid": "^11.0.0"
},
"devDependencies": {
"@types/diff": "^7.0.0",
"@types/markdown-it": "^14.1.0",
"@types/mocha": "^10.0.7",
"@types/node": "^22.0.0",
"@types/vscode": "^1.90.0",
"@vscode/test-electron": "^2.4.0",
"ajv": "^8.20.0",
"esbuild": "^0.23.0",
"glob": "^11.0.0",
"mocha": "^10.7.0",
"typescript": "^5.5.0",
"vitest": "^2.0.0"
}
}