@rasensio/aidlc 2.37.0 → 2.39.0
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 +10 -5
- package/dist/autopilot/main-ci.d.ts +64 -0
- package/dist/autopilot/main-ci.d.ts.map +1 -0
- package/dist/autopilot/main-ci.js +113 -0
- package/dist/autopilot/main-ci.js.map +1 -0
- package/dist/commands/autopilot.d.ts.map +1 -1
- package/dist/commands/autopilot.js +8 -1
- package/dist/commands/autopilot.js.map +1 -1
- package/dist/commands/cost.d.ts.map +1 -1
- package/dist/commands/cost.js +15 -5
- package/dist/commands/cost.js.map +1 -1
- package/dist/commands/hook.d.ts +7 -3
- package/dist/commands/hook.d.ts.map +1 -1
- package/dist/commands/hook.js +31 -10
- package/dist/commands/hook.js.map +1 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +7 -1
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/metrics.d.ts +2 -0
- package/dist/commands/metrics.d.ts.map +1 -1
- package/dist/commands/metrics.js +13 -7
- package/dist/commands/metrics.js.map +1 -1
- package/dist/compile/adapters/codex.d.ts.map +1 -1
- package/dist/compile/adapters/codex.js +2 -7
- package/dist/compile/adapters/codex.js.map +1 -1
- package/dist/compile/adapters/copilot.d.ts +85 -0
- package/dist/compile/adapters/copilot.d.ts.map +1 -0
- package/dist/compile/adapters/copilot.js +336 -0
- package/dist/compile/adapters/copilot.js.map +1 -0
- package/dist/compile/adapters/index.d.ts +5 -2
- package/dist/compile/adapters/index.d.ts.map +1 -1
- package/dist/compile/adapters/index.js +10 -5
- package/dist/compile/adapters/index.js.map +1 -1
- package/dist/compile/adapters/list-in-words.d.ts +10 -0
- package/dist/compile/adapters/list-in-words.d.ts.map +1 -0
- package/dist/compile/adapters/list-in-words.js +14 -0
- package/dist/compile/adapters/list-in-words.js.map +1 -0
- package/dist/core/types.d.ts +1 -1
- package/dist/core/types.d.ts.map +1 -1
- package/dist/cost/hooks/arm.d.ts.map +1 -1
- package/dist/cost/hooks/arm.js +5 -0
- package/dist/cost/hooks/arm.js.map +1 -1
- package/dist/cost/sessions.d.ts +16 -0
- package/dist/cost/sessions.d.ts.map +1 -1
- package/dist/cost/sessions.js +32 -1
- package/dist/cost/sessions.js.map +1 -1
- package/dist/cost/sync.d.ts.map +1 -1
- package/dist/cost/sync.js +4 -2
- package/dist/cost/sync.js.map +1 -1
- package/dist/doctor/migrations/outdated-approval-guard.d.ts.map +1 -1
- package/dist/doctor/migrations/outdated-approval-guard.js +28 -9
- package/dist/doctor/migrations/outdated-approval-guard.js.map +1 -1
- package/dist/hooks/approval-guard.d.ts +31 -3
- package/dist/hooks/approval-guard.d.ts.map +1 -1
- package/dist/hooks/approval-guard.js +186 -23
- package/dist/hooks/approval-guard.js.map +1 -1
- package/dist/hooks/install.d.ts +30 -16
- package/dist/hooks/install.d.ts.map +1 -1
- package/dist/hooks/install.js +154 -53
- package/dist/hooks/install.js.map +1 -1
- package/dist/hooks/node-runner.d.ts +15 -3
- package/dist/hooks/node-runner.d.ts.map +1 -1
- package/dist/hooks/node-runner.js +16 -5
- package/dist/hooks/node-runner.js.map +1 -1
- package/dist/operational/packagers.d.ts +1 -1
- package/dist/operational/packagers.d.ts.map +1 -1
- package/dist/operational/packagers.js +33 -1
- package/dist/operational/packagers.js.map +1 -1
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"metrics.js","sourceRoot":"","sources":["../../src/commands/metrics.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpC,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAE,cAAc,EAAsB,MAAM,sBAAsB,CAAC;AAC1E,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAEtC,SA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AAC;YACzC,KAAK,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,MAAM,MAAM,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC;QAC1C,CAAC;IACH,CAAC;IACD,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC;AACjC,CAAC;AAED,MAAM,UAAU,eAAe,CAAC,OAAgB;IAC9C,OAAO;SACJ,OAAO,CAAC,SAAS,CAAC;SAClB,WAAW,CAAC,gEAAgE,CAAC;SAC7E,MAAM,CAAC,QAAQ,EAAE,8BAA8B,CAAC;SAChD,MAAM,CAAC,CAAC,IAAwB,EAAE,EAAE;QACnC,MAAM,WAAW,GAAG,kBAAkB,EAAE,CAAC;QACzC,MAAM,MAAM,GAAG,cAAc,CAAC,WAAW,CAAC,CAAC;QAC3C,MAAM,MAAM,GAAG,cAAc,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC;QACnD,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC;YACd,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC,GAAG,IAAI,CAAC,CAAC;QAC/D,CAAC;aAAM,CAAC;YACN,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,WAAW,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC,CAAC;QACzD,CAAC;IACH,CAAC,CAAC,CAAC;AACP,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"codex.d.ts","sourceRoot":"","sources":["../../../src/compile/adapters/codex.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EACV,eAAe,EACf,eAAe,EACf,KAAK,EAMN,MAAM,qBAAqB,CAAC;
|
|
1
|
+
{"version":3,"file":"codex.d.ts","sourceRoot":"","sources":["../../../src/compile/adapters/codex.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EACV,eAAe,EACf,eAAe,EACf,KAAK,EAMN,MAAM,qBAAqB,CAAC;AAe7B;;;;;;;GAOG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAEjD;AAED;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,KAAK,EAAE,UAAU,GAAE,MAAM,EAAO,GAAG,MAAM,CAYhF;AAqCD;;;;;;;GAOG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAOtD;AAED;;;;;;;GAOG;AACH,wBAAgB,cAAc,CAAC,KAAK,EAAE,eAAe,GAAG,MAAM,CAO7D;AAED;;;;;;;;;;;;;GAaG;AACH,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,eAAe,GAAG,MAAM,GAAG,IAAI,CAatE;AAqHD;;GAEG;AACH,eAAO,MAAM,YAAY,EAAE,eAiF1B,CAAC"}
|
|
@@ -17,6 +17,7 @@
|
|
|
17
17
|
* @module
|
|
18
18
|
*/
|
|
19
19
|
import { AGENT_MARKER_TEXT, findAgent } from '../agents.js';
|
|
20
|
+
import { listInWords } from './list-in-words.js';
|
|
20
21
|
import { canonicalSkillFilename, normalizeSkillName } from '../naming.js';
|
|
21
22
|
import { formatCanonicalSkill } from '../skill-format.js';
|
|
22
23
|
import { takesPhaseDirectives } from '../skill-metadata.js';
|
|
@@ -115,12 +116,6 @@ export function formatCodexPolicy(skill) {
|
|
|
115
116
|
'',
|
|
116
117
|
].join('\n');
|
|
117
118
|
}
|
|
118
|
-
/** `a`, `a and b`, `a, b and c`. */
|
|
119
|
-
function joinNames(names) {
|
|
120
|
-
if (names.length <= 1)
|
|
121
|
-
return names.join('');
|
|
122
|
-
return `${names.slice(0, -1).join(', ')} and ${names[names.length - 1]}`;
|
|
123
|
-
}
|
|
124
119
|
/**
|
|
125
120
|
* The line that hands a skill to its agent (native-reviewer-agent/AC-16).
|
|
126
121
|
*
|
|
@@ -200,7 +195,7 @@ function buildAgentsBlock(skills, caps, ctx) {
|
|
|
200
195
|
// (native-skill-metadata/AC-21, AC-23).
|
|
201
196
|
const implicit = skills.filter(isImplicit).map((s) => `\`${skillDirName(s)}\``);
|
|
202
197
|
lines.push('Installed as skills under `.agents/skills/`. ' +
|
|
203
|
-
`Codex picks ${implicit.length > 0 ?
|
|
198
|
+
`Codex picks ${implicit.length > 0 ? listInWords(implicit) : 'none of them'} on its own; ` +
|
|
204
199
|
'start any other by name with `$<skill>`, or pick one from `/skills`. When a skill sends ' +
|
|
205
200
|
'you to another one Codex has not offered, read `.agents/skills/<skill>/SKILL.md` and ' +
|
|
206
201
|
'follow it.');
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"codex.js","sourceRoot":"","sources":["../../../src/compile/adapters/codex.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAYH,OAAO,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAC5D,OAAO,EAAE,sBAAsB,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAC1E,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAE,oBAAoB,EAAE,MAAM,sBAAsB,CAAC;AAE5D;;;GAGG;AACH,SAAS,aAAa,CAAC,KAAY;IACjC,OAAO,sBAAsB,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACjD,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,YAAY,CAAC,KAAY;IACvC,OAAO,kBAAkB,CAAC,KAAK,CAAC,IAAI,CAAC,IAAI,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC,CAAC;AAC/D,CAAC;AAED;;;;;;;;;;;;;;GAcG;AACH,MAAM,UAAU,gBAAgB,CAAC,KAAY,EAAE,aAAuB,EAAE;IACtE,MAAM,KAAK,GAAa,CAAC,KAAK,CAAC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
|
+
/**
|
|
2
|
+
* GitHub Copilot platform adapter.
|
|
3
|
+
*
|
|
4
|
+
* Generates:
|
|
5
|
+
* - Canonical skill bodies copied to `.aidlc/skills/`
|
|
6
|
+
* - One Copilot agent skill per lifecycle skill at
|
|
7
|
+
* `.github/skills/<dir>/SKILL.md`, carrying the FULL canonical body
|
|
8
|
+
* - An `aidlc` merge-block in `.github/copilot-instructions.md`
|
|
9
|
+
*
|
|
10
|
+
* Restored from `e2cccc2`, which v2.0.0 deleted for lack of a user, not for a
|
|
11
|
+
* defect, then brought level with what the other adapters gained since
|
|
12
|
+
* (bring-back-copilot, design C2).
|
|
13
|
+
*
|
|
14
|
+
* Two path choices deserve their reasons recorded, because both had a cheaper
|
|
15
|
+
* wrong answer:
|
|
16
|
+
*
|
|
17
|
+
* **`.github/skills/`, not `.claude/skills/` or `.agents/skills/`.** Copilot
|
|
18
|
+
* searches all three, so reusing an existing platform's directory would have made
|
|
19
|
+
* this adapter a no-op alias. That is wrong twice over: `.claude/skills/` receives
|
|
20
|
+
* *shims* (`claude-code.ts` emits a pointer sentence, not a body), which is the
|
|
21
|
+
* second-class packaging `agent-portability` removed for Codex; and
|
|
22
|
+
* `.agents/skills/` is Codex's own path, paired with an `AGENTS.md` instruction
|
|
23
|
+
* surface that fewer Copilot clients read. `.github/skills/` is Copilot's
|
|
24
|
+
* first-party location, so this adapter owns its output outright and depends on no
|
|
25
|
+
* other vendor's directory.
|
|
26
|
+
*
|
|
27
|
+
* **`.github/copilot-instructions.md`, not `AGENTS.md`.** Per GitHub's own
|
|
28
|
+
* support matrix, `copilot-instructions.md` is the only customization type read by
|
|
29
|
+
* every Copilot client — web chat, cloud agent, code review, VS Code, Visual
|
|
30
|
+
* Studio, JetBrains, Xcode, Eclipse and the CLI. `AGENTS.md` is narrower. This
|
|
31
|
+
* adapter deliberately writes no other vendor's entry file (bring-back-copilot/AC-4).
|
|
32
|
+
*
|
|
33
|
+
* The emitted body is the canonical body itself, never a pointer to it: a pointer
|
|
34
|
+
* forces the agent to open a second file before it can act, which is precisely
|
|
35
|
+
* what made Codex second-class before `agent-portability`.
|
|
36
|
+
*
|
|
37
|
+
* Requirements: bring-back-copilot/AC-1, AC-2, AC-3, AC-4, AC-5, AC-6, AC-7,
|
|
38
|
+
* AC-8, AC-10, AC-12
|
|
39
|
+
*
|
|
40
|
+
* @module
|
|
41
|
+
*/
|
|
42
|
+
import type { AgentDefinition, PlatformAdapter, Skill } from '../../core/types.js';
|
|
43
|
+
/** Copilot's first-party project skill directory. */
|
|
44
|
+
export declare const COPILOT_SKILLS_DIR = ".github/skills";
|
|
45
|
+
/** The instruction file every Copilot client reads. */
|
|
46
|
+
export declare const COPILOT_INSTRUCTIONS_PATH = ".github/copilot-instructions.md";
|
|
47
|
+
/** Merge-block id inside the instruction file. */
|
|
48
|
+
export declare const COPILOT_BLOCK_ID = "aidlc";
|
|
49
|
+
/**
|
|
50
|
+
* Copilot's documented limit on a skill's `description`. Kept here rather than in
|
|
51
|
+
* a shared limits module, because nothing else uses it (design C2).
|
|
52
|
+
*/
|
|
53
|
+
export declare const COPILOT_MAX_DESCRIPTION_CHARS = 1024;
|
|
54
|
+
/**
|
|
55
|
+
* Directory name for a Copilot skill: `aidlc-<name>`, or bare `aidlc` for the
|
|
56
|
+
* entry point.
|
|
57
|
+
*
|
|
58
|
+
* Uses the shared helper, whose charset substitution and 64-character truncation
|
|
59
|
+
* happen to be exactly Copilot's documented name constraints.
|
|
60
|
+
*/
|
|
61
|
+
export declare function skillDirName(skill: Skill): string;
|
|
62
|
+
/**
|
|
63
|
+
* The paragraph that stands in for a read-only reviewer agent (design C2, gain 3).
|
|
64
|
+
*
|
|
65
|
+
* Copilot gets no agent file, so nothing enforces read-only. The paragraph says
|
|
66
|
+
* so rather than let a review claim an independence it does not have — the same
|
|
67
|
+
* fallback the Codex directive uses when its agent is not loaded.
|
|
68
|
+
*/
|
|
69
|
+
export declare function copilotAgentDirective(agent: AgentDefinition): string;
|
|
70
|
+
/**
|
|
71
|
+
* A Copilot agent skill file.
|
|
72
|
+
*
|
|
73
|
+
* `name` must equal the directory name and `description` is what Copilot matches
|
|
74
|
+
* a request against — so the trigger words have to live in it. A skill whose name
|
|
75
|
+
* is invalid, or whose name and directory disagree, fails to load with no error
|
|
76
|
+
* message at all, which is why `validate` checks both.
|
|
77
|
+
*
|
|
78
|
+
* The metadata keys mirror Claude Code's where Copilot reads the same key:
|
|
79
|
+
* `argument-hint` and `disable-model-invocation`. `trigger` is not written —
|
|
80
|
+
* Claude Code's `when_to_use` has no Copilot equivalent, and the description
|
|
81
|
+
* already carries the trigger words (design C2, gain 1).
|
|
82
|
+
*/
|
|
83
|
+
export declare function formatCopilotSkill(skill: Skill, dirName: string, directives?: string[]): string;
|
|
84
|
+
export declare const copilotAdapter: PlatformAdapter;
|
|
85
|
+
//# sourceMappingURL=copilot.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"copilot.d.ts","sourceRoot":"","sources":["../../../src/compile/adapters/copilot.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAEH,OAAO,KAAK,EACV,eAAe,EACf,eAAe,EACf,KAAK,EAQN,MAAM,qBAAqB,CAAC;AAiB7B,qDAAqD;AACrD,eAAO,MAAM,kBAAkB,mBAAmB,CAAC;AAEnD,uDAAuD;AACvD,eAAO,MAAM,yBAAyB,oCAAoC,CAAC;AAE3E,kDAAkD;AAClD,eAAO,MAAM,gBAAgB,UAAU,CAAC;AAExC;;;GAGG;AACH,eAAO,MAAM,6BAA6B,OAAO,CAAC;AAgBlD;;;;;;GAMG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,KAAK,GAAG,MAAM,CAEjD;AAED;;;;;;GAMG;AACH,wBAAgB,qBAAqB,CAAC,KAAK,EAAE,eAAe,GAAG,MAAM,CAWpE;AAED;;;;;;;;;;;;GAYG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,UAAU,GAAE,MAAM,EAAO,GAAG,MAAM,CAqBnG;AAsID,eAAO,MAAM,cAAc,EAAE,eAqH5B,CAAC"}
|
|
@@ -0,0 +1,336 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GitHub Copilot platform adapter.
|
|
3
|
+
*
|
|
4
|
+
* Generates:
|
|
5
|
+
* - Canonical skill bodies copied to `.aidlc/skills/`
|
|
6
|
+
* - One Copilot agent skill per lifecycle skill at
|
|
7
|
+
* `.github/skills/<dir>/SKILL.md`, carrying the FULL canonical body
|
|
8
|
+
* - An `aidlc` merge-block in `.github/copilot-instructions.md`
|
|
9
|
+
*
|
|
10
|
+
* Restored from `e2cccc2`, which v2.0.0 deleted for lack of a user, not for a
|
|
11
|
+
* defect, then brought level with what the other adapters gained since
|
|
12
|
+
* (bring-back-copilot, design C2).
|
|
13
|
+
*
|
|
14
|
+
* Two path choices deserve their reasons recorded, because both had a cheaper
|
|
15
|
+
* wrong answer:
|
|
16
|
+
*
|
|
17
|
+
* **`.github/skills/`, not `.claude/skills/` or `.agents/skills/`.** Copilot
|
|
18
|
+
* searches all three, so reusing an existing platform's directory would have made
|
|
19
|
+
* this adapter a no-op alias. That is wrong twice over: `.claude/skills/` receives
|
|
20
|
+
* *shims* (`claude-code.ts` emits a pointer sentence, not a body), which is the
|
|
21
|
+
* second-class packaging `agent-portability` removed for Codex; and
|
|
22
|
+
* `.agents/skills/` is Codex's own path, paired with an `AGENTS.md` instruction
|
|
23
|
+
* surface that fewer Copilot clients read. `.github/skills/` is Copilot's
|
|
24
|
+
* first-party location, so this adapter owns its output outright and depends on no
|
|
25
|
+
* other vendor's directory.
|
|
26
|
+
*
|
|
27
|
+
* **`.github/copilot-instructions.md`, not `AGENTS.md`.** Per GitHub's own
|
|
28
|
+
* support matrix, `copilot-instructions.md` is the only customization type read by
|
|
29
|
+
* every Copilot client — web chat, cloud agent, code review, VS Code, Visual
|
|
30
|
+
* Studio, JetBrains, Xcode, Eclipse and the CLI. `AGENTS.md` is narrower. This
|
|
31
|
+
* adapter deliberately writes no other vendor's entry file (bring-back-copilot/AC-4).
|
|
32
|
+
*
|
|
33
|
+
* The emitted body is the canonical body itself, never a pointer to it: a pointer
|
|
34
|
+
* forces the agent to open a second file before it can act, which is precisely
|
|
35
|
+
* what made Codex second-class before `agent-portability`.
|
|
36
|
+
*
|
|
37
|
+
* Requirements: bring-back-copilot/AC-1, AC-2, AC-3, AC-4, AC-5, AC-6, AC-7,
|
|
38
|
+
* AC-8, AC-10, AC-12
|
|
39
|
+
*
|
|
40
|
+
* @module
|
|
41
|
+
*/
|
|
42
|
+
import { findAgent } from '../agents.js';
|
|
43
|
+
import { BARE_ENTRY_POINT, MAX_SKILL_NAME_LENGTH, SKILL_NAME_RE, canonicalSkillFilename, normalizeSkillName, } from '../naming.js';
|
|
44
|
+
import { formatCanonicalSkill } from '../skill-format.js';
|
|
45
|
+
import { resolveActivation, validateCapabilityMap } from '../capability-resolve.js';
|
|
46
|
+
import { takesPhaseDirectives, yamlString } from '../skill-metadata.js';
|
|
47
|
+
// ---------------------------------------------------------------------------
|
|
48
|
+
// Constants
|
|
49
|
+
// ---------------------------------------------------------------------------
|
|
50
|
+
/** Copilot's first-party project skill directory. */
|
|
51
|
+
export const COPILOT_SKILLS_DIR = '.github/skills';
|
|
52
|
+
/** The instruction file every Copilot client reads. */
|
|
53
|
+
export const COPILOT_INSTRUCTIONS_PATH = '.github/copilot-instructions.md';
|
|
54
|
+
/** Merge-block id inside the instruction file. */
|
|
55
|
+
export const COPILOT_BLOCK_ID = 'aidlc';
|
|
56
|
+
/**
|
|
57
|
+
* Copilot's documented limit on a skill's `description`. Kept here rather than in
|
|
58
|
+
* a shared limits module, because nothing else uses it (design C2).
|
|
59
|
+
*/
|
|
60
|
+
export const COPILOT_MAX_DESCRIPTION_CHARS = 1024;
|
|
61
|
+
/**
|
|
62
|
+
* Hint shown in the chat input when the entry point is invoked as `/aidlc`.
|
|
63
|
+
*
|
|
64
|
+
* The entry-point skill accepts free text ("continue my-feature", "check
|
|
65
|
+
* status") and declares no `arguments` of its own, and without a hint a Copilot
|
|
66
|
+
* user has no way to discover that.
|
|
67
|
+
*/
|
|
68
|
+
const ENTRY_POINT_ARGUMENT_HINT = '[what you want to do — e.g. "continue my-feature", "start something new", "status"]';
|
|
69
|
+
// ---------------------------------------------------------------------------
|
|
70
|
+
// Helpers
|
|
71
|
+
// ---------------------------------------------------------------------------
|
|
72
|
+
/**
|
|
73
|
+
* Directory name for a Copilot skill: `aidlc-<name>`, or bare `aidlc` for the
|
|
74
|
+
* entry point.
|
|
75
|
+
*
|
|
76
|
+
* Uses the shared helper, whose charset substitution and 64-character truncation
|
|
77
|
+
* happen to be exactly Copilot's documented name constraints.
|
|
78
|
+
*/
|
|
79
|
+
export function skillDirName(skill) {
|
|
80
|
+
return normalizeSkillName(skill.meta.name, { prefix: true });
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* The paragraph that stands in for a read-only reviewer agent (design C2, gain 3).
|
|
84
|
+
*
|
|
85
|
+
* Copilot gets no agent file, so nothing enforces read-only. The paragraph says
|
|
86
|
+
* so rather than let a review claim an independence it does not have — the same
|
|
87
|
+
* fallback the Codex directive uses when its agent is not loaded.
|
|
88
|
+
*/
|
|
89
|
+
export function copilotAgentDirective(agent) {
|
|
90
|
+
const commands = agent.commands.length > 0
|
|
91
|
+
? ` It may run only ${agent.commands.map((c) => `\`${c}\``).join(', ')}.`
|
|
92
|
+
: '';
|
|
93
|
+
return (`Run this skill as the \`${agent.name}\` reviewer: if Copilot offers a sub-agent, start a ` +
|
|
94
|
+
'fresh one, give it the instance and artifact, and tell it to edit nothing.' +
|
|
95
|
+
commands +
|
|
96
|
+
' Say in the review that it was read-only by request, not enforced: Copilot has no ' +
|
|
97
|
+
'read-only agent for AIDLC to install.');
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* A Copilot agent skill file.
|
|
101
|
+
*
|
|
102
|
+
* `name` must equal the directory name and `description` is what Copilot matches
|
|
103
|
+
* a request against — so the trigger words have to live in it. A skill whose name
|
|
104
|
+
* is invalid, or whose name and directory disagree, fails to load with no error
|
|
105
|
+
* message at all, which is why `validate` checks both.
|
|
106
|
+
*
|
|
107
|
+
* The metadata keys mirror Claude Code's where Copilot reads the same key:
|
|
108
|
+
* `argument-hint` and `disable-model-invocation`. `trigger` is not written —
|
|
109
|
+
* Claude Code's `when_to_use` has no Copilot equivalent, and the description
|
|
110
|
+
* already carries the trigger words (design C2, gain 1).
|
|
111
|
+
*/
|
|
112
|
+
export function formatCopilotSkill(skill, dirName, directives = []) {
|
|
113
|
+
const lines = ['---'];
|
|
114
|
+
lines.push(`name: ${dirName}`);
|
|
115
|
+
lines.push(`description: ${skill.meta.description}`);
|
|
116
|
+
if (skill.meta.arguments) {
|
|
117
|
+
lines.push(`argument-hint: ${yamlString(skill.meta.arguments)}`);
|
|
118
|
+
}
|
|
119
|
+
else if (dirName === BARE_ENTRY_POINT) {
|
|
120
|
+
lines.push(`argument-hint: ${yamlString(ENTRY_POINT_ARGUMENT_HINT)}`);
|
|
121
|
+
}
|
|
122
|
+
// `routed` and `auto` write nothing, as on Claude Code.
|
|
123
|
+
if (skill.meta.invocation === 'user')
|
|
124
|
+
lines.push('disable-model-invocation: true');
|
|
125
|
+
lines.push('---');
|
|
126
|
+
lines.push('');
|
|
127
|
+
for (const directive of directives) {
|
|
128
|
+
lines.push(directive);
|
|
129
|
+
lines.push('');
|
|
130
|
+
}
|
|
131
|
+
lines.push(skill.body);
|
|
132
|
+
return lines.join('\n');
|
|
133
|
+
}
|
|
134
|
+
/**
|
|
135
|
+
* A skill's capability-map line on Copilot, or null.
|
|
136
|
+
*
|
|
137
|
+
* The same rule as `claude-code.ts`: a skill declaring `activation: none` takes
|
|
138
|
+
* no phase line unless its own hint names one. That is what keeps plan mode off
|
|
139
|
+
* the entry, roadmap and constitution skills (bring-back-copilot/AC-10, design C3).
|
|
140
|
+
*/
|
|
141
|
+
function copilotActivation(skill, phaseMap) {
|
|
142
|
+
return takesPhaseDirectives(skill) || skill.meta.native_mode_hint?.copilot
|
|
143
|
+
? resolveActivation(skill, 'copilot', phaseMap)
|
|
144
|
+
: null;
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
147
|
+
* Build the `.github/copilot-instructions.md` managed block.
|
|
148
|
+
*
|
|
149
|
+
* Context docs and guidance layers are listed as PATHS ONLY. Inlining a guidance
|
|
150
|
+
* body here would duplicate the single source every other platform points at, and
|
|
151
|
+
* a duplicated layer drifts from the file it was copied out of.
|
|
152
|
+
*/
|
|
153
|
+
function buildInstructionsBlock(skills, phaseMap, ctx) {
|
|
154
|
+
const lines = [];
|
|
155
|
+
lines.push('# AIDLC Framework');
|
|
156
|
+
lines.push('');
|
|
157
|
+
lines.push('This project uses the AI Development Lifecycle (AIDLC) framework. ' +
|
|
158
|
+
'Follow the lifecycle phases and state protocol below.');
|
|
159
|
+
lines.push('');
|
|
160
|
+
lines.push('## State Protocol');
|
|
161
|
+
lines.push('');
|
|
162
|
+
lines.push('- Lifecycle state: `.aidlc/state/<instance>/instance.yaml`');
|
|
163
|
+
lines.push('- Phase state: `.aidlc/state/<instance>/phase-<name>.yaml`');
|
|
164
|
+
lines.push('- Transition log: `.aidlc/state/<instance>/transitions.log` (NDJSON)');
|
|
165
|
+
lines.push('- Before mutating state, claim the instance');
|
|
166
|
+
lines.push('- Read the overview skill for the full protocol: `.aidlc/skills/aidlc-overview.md`');
|
|
167
|
+
lines.push('- Use `aidlc status` to see current progress across all instances');
|
|
168
|
+
lines.push('');
|
|
169
|
+
// The lifecycle records which platform ran the work from `AIDLC_AGENT`. Without
|
|
170
|
+
// it a Copilot claim resolves as `unknown`, and its cost report cannot say why
|
|
171
|
+
// there is no data (bring-back-copilot/AC-21, design C7).
|
|
172
|
+
lines.push('## Running aidlc in Copilot');
|
|
173
|
+
lines.push('');
|
|
174
|
+
lines.push('- Run `aidlc` commands with `AIDLC_AGENT=copilot` set, for example ' +
|
|
175
|
+
'`AIDLC_AGENT=copilot aidlc claim <instance>`, so the lifecycle records that Copilot ran the work.');
|
|
176
|
+
lines.push('');
|
|
177
|
+
// A user-only skill is not offered to the model, so a route to it needs a path
|
|
178
|
+
// to read instead (native-skill-metadata/AC-23; bring-back-copilot design C2, gain 6).
|
|
179
|
+
lines.push('## Skills');
|
|
180
|
+
lines.push('');
|
|
181
|
+
lines.push('- When an AIDLC skill sends you to another one that is not offered to you, read ' +
|
|
182
|
+
`\`${COPILOT_SKILLS_DIR}/<skill>/SKILL.md\` (for example ` +
|
|
183
|
+
`\`${COPILOT_SKILLS_DIR}/aidlc-autopilot/SKILL.md\`) and follow it.`);
|
|
184
|
+
lines.push('');
|
|
185
|
+
lines.push('## Phase Skills');
|
|
186
|
+
lines.push('');
|
|
187
|
+
lines.push(`Installed as Copilot agent skills under \`${COPILOT_SKILLS_DIR}/\`. ` +
|
|
188
|
+
'Copilot selects one automatically by matching your request against its description, ' +
|
|
189
|
+
'or you can invoke one directly as a slash command — type `/` to list them. ' +
|
|
190
|
+
'The entry point is `/aidlc`.');
|
|
191
|
+
lines.push('');
|
|
192
|
+
for (const skill of skills) {
|
|
193
|
+
const dirName = skillDirName(skill);
|
|
194
|
+
const activation = copilotActivation(skill, phaseMap);
|
|
195
|
+
let entry = `- **${skill.meta.phase}**: \`/${dirName}\``;
|
|
196
|
+
if (activation) {
|
|
197
|
+
entry += ` — ${activation}`;
|
|
198
|
+
}
|
|
199
|
+
lines.push(entry);
|
|
200
|
+
}
|
|
201
|
+
lines.push('');
|
|
202
|
+
const contextNames = Object.keys(ctx.contextDocs);
|
|
203
|
+
if (contextNames.length > 0) {
|
|
204
|
+
lines.push('## Context Documents');
|
|
205
|
+
lines.push('');
|
|
206
|
+
for (const name of contextNames.sort()) {
|
|
207
|
+
lines.push(`- \`.aidlc/context/${ctx.contextDocs[name]}\` — ${name}`);
|
|
208
|
+
}
|
|
209
|
+
lines.push('');
|
|
210
|
+
}
|
|
211
|
+
const layerNames = Object.keys(ctx.guidanceLayers);
|
|
212
|
+
if (layerNames.length > 0) {
|
|
213
|
+
lines.push('## Guidance Layers');
|
|
214
|
+
lines.push('');
|
|
215
|
+
for (const name of layerNames.sort()) {
|
|
216
|
+
lines.push(`- \`.aidlc/guidance/${ctx.guidanceLayers[name]}\` — ${name}`);
|
|
217
|
+
}
|
|
218
|
+
lines.push('');
|
|
219
|
+
}
|
|
220
|
+
// Knowledge graph context (KG Req 6.4) — omitted when the project has no graph
|
|
221
|
+
if (ctx.knowledgeSection) {
|
|
222
|
+
lines.push(ctx.knowledgeSection);
|
|
223
|
+
lines.push('');
|
|
224
|
+
}
|
|
225
|
+
return lines.join('\n');
|
|
226
|
+
}
|
|
227
|
+
/** Read one top-level `key:` value out of a SKILL.md frontmatter block, if present. */
|
|
228
|
+
function frontmatterValue(content, key) {
|
|
229
|
+
if (!content.startsWith('---\n'))
|
|
230
|
+
return null;
|
|
231
|
+
const endIdx = content.indexOf('\n---\n', 4);
|
|
232
|
+
if (endIdx === -1)
|
|
233
|
+
return null;
|
|
234
|
+
const match = content.slice(4, endIdx).match(new RegExp(`^${key}:\\s*(.+)$`, 'm'));
|
|
235
|
+
return match ? match[1].trim() : null;
|
|
236
|
+
}
|
|
237
|
+
// ---------------------------------------------------------------------------
|
|
238
|
+
// Adapter Implementation
|
|
239
|
+
// ---------------------------------------------------------------------------
|
|
240
|
+
export const copilotAdapter = {
|
|
241
|
+
id: 'copilot',
|
|
242
|
+
plan(skills, caps, ctx) {
|
|
243
|
+
const ops = [];
|
|
244
|
+
const warnings = [];
|
|
245
|
+
let phaseMap = null;
|
|
246
|
+
if (caps) {
|
|
247
|
+
phaseMap = validateCapabilityMap(caps, warnings);
|
|
248
|
+
}
|
|
249
|
+
// 1. Canonical bodies, as every adapter emits them.
|
|
250
|
+
for (const skill of skills) {
|
|
251
|
+
ops.push({
|
|
252
|
+
kind: 'create',
|
|
253
|
+
path: `.aidlc/skills/${canonicalSkillFilename(skill.meta.name)}`,
|
|
254
|
+
content: formatCanonicalSkill(skill),
|
|
255
|
+
});
|
|
256
|
+
}
|
|
257
|
+
// 2. One Copilot agent skill per lifecycle skill, carrying the full body. A
|
|
258
|
+
// skill run by an agent gets the reviewer paragraph and no phase line, as on
|
|
259
|
+
// Claude Code: the review skill's phase would otherwise hand a reviewer a
|
|
260
|
+
// plan-mode directive.
|
|
261
|
+
for (const skill of skills) {
|
|
262
|
+
const dirName = skillDirName(skill);
|
|
263
|
+
const agent = findAgent(ctx, skill.meta.agent);
|
|
264
|
+
const activation = agent ? null : copilotActivation(skill, phaseMap);
|
|
265
|
+
const directives = [
|
|
266
|
+
...(agent ? [copilotAgentDirective(agent)] : []),
|
|
267
|
+
...(activation ? [activation] : []),
|
|
268
|
+
];
|
|
269
|
+
ops.push({
|
|
270
|
+
kind: 'create',
|
|
271
|
+
path: `${COPILOT_SKILLS_DIR}/${dirName}/SKILL.md`,
|
|
272
|
+
content: formatCopilotSkill(skill, dirName, directives),
|
|
273
|
+
});
|
|
274
|
+
}
|
|
275
|
+
// 3. The always-on instruction surface.
|
|
276
|
+
ops.push({
|
|
277
|
+
kind: 'merge-block',
|
|
278
|
+
path: COPILOT_INSTRUCTIONS_PATH,
|
|
279
|
+
blockId: COPILOT_BLOCK_ID,
|
|
280
|
+
content: buildInstructionsBlock(skills, phaseMap, ctx),
|
|
281
|
+
});
|
|
282
|
+
return { ops, warnings };
|
|
283
|
+
},
|
|
284
|
+
validate(op) {
|
|
285
|
+
const errors = [];
|
|
286
|
+
const warnings = [];
|
|
287
|
+
// Bounds before existence, and before anything reads the content: a path is
|
|
288
|
+
// rejected on its shape, not on what it happens to resolve to (AC-12).
|
|
289
|
+
if (op.path.startsWith('/') || op.path.split('/').includes('..')) {
|
|
290
|
+
errors.push(`path '${op.path}' must be relative to the project root with no '..' segment`);
|
|
291
|
+
return { valid: false, errors, warnings };
|
|
292
|
+
}
|
|
293
|
+
if (op.kind === 'merge-block') {
|
|
294
|
+
// Plain markdown between managed delimiters — structurally always valid.
|
|
295
|
+
return { valid: true, errors: [], warnings: [] };
|
|
296
|
+
}
|
|
297
|
+
if (op.path.startsWith(`${COPILOT_SKILLS_DIR}/`) && op.path.endsWith('/SKILL.md')) {
|
|
298
|
+
// `.github/skills/<dirName>/SKILL.md`
|
|
299
|
+
const segments = op.path.split('/');
|
|
300
|
+
const dirName = segments[2];
|
|
301
|
+
if (!dirName || !SKILL_NAME_RE.test(dirName)) {
|
|
302
|
+
errors.push(`skill directory name '${dirName}' must be lowercase letters, numbers and hyphens, starting with a letter`);
|
|
303
|
+
}
|
|
304
|
+
if (dirName && dirName.length > MAX_SKILL_NAME_LENGTH) {
|
|
305
|
+
errors.push(`skill directory name '${dirName}' exceeds ${MAX_SKILL_NAME_LENGTH} character limit`);
|
|
306
|
+
}
|
|
307
|
+
const content = op.content;
|
|
308
|
+
if (!content.startsWith('---\n')) {
|
|
309
|
+
errors.push('SKILL.md must begin with YAML frontmatter (---)');
|
|
310
|
+
return { valid: false, errors, warnings };
|
|
311
|
+
}
|
|
312
|
+
if (content.indexOf('\n---\n', 4) === -1) {
|
|
313
|
+
errors.push('SKILL.md has unclosed frontmatter');
|
|
314
|
+
return { valid: false, errors, warnings };
|
|
315
|
+
}
|
|
316
|
+
const name = frontmatterValue(content, 'name');
|
|
317
|
+
if (name === null) {
|
|
318
|
+
errors.push("SKILL.md frontmatter missing required field 'name'");
|
|
319
|
+
}
|
|
320
|
+
else if (name !== dirName) {
|
|
321
|
+
// Copilot drops a skill whose name and directory disagree, silently.
|
|
322
|
+
errors.push(`SKILL.md frontmatter 'name' (${name}) must match directory name (${dirName})`);
|
|
323
|
+
}
|
|
324
|
+
const description = frontmatterValue(content, 'description');
|
|
325
|
+
if (description === null) {
|
|
326
|
+
errors.push("SKILL.md frontmatter missing required field 'description'");
|
|
327
|
+
}
|
|
328
|
+
else if (description.length > COPILOT_MAX_DESCRIPTION_CHARS) {
|
|
329
|
+
errors.push(`SKILL.md frontmatter 'description' is ${description.length} characters, ` +
|
|
330
|
+
`exceeding Copilot's ${COPILOT_MAX_DESCRIPTION_CHARS}-character limit`);
|
|
331
|
+
}
|
|
332
|
+
}
|
|
333
|
+
return { valid: errors.length === 0, errors, warnings };
|
|
334
|
+
},
|
|
335
|
+
};
|
|
336
|
+
//# sourceMappingURL=copilot.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"copilot.js","sourceRoot":"","sources":["../../../src/compile/adapters/copilot.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAcH,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AACzC,OAAO,EACL,gBAAgB,EAChB,qBAAqB,EACrB,aAAa,EACb,sBAAsB,EACtB,kBAAkB,GACnB,MAAM,cAAc,CAAC;AACtB,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAC1D,OAAO,EAAE,iBAAiB,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAC;AACpF,OAAO,EAAE,oBAAoB,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAC;AAExE,8EAA8E;AAC9E,YAAY;AACZ,8EAA8E;AAE9E,qDAAqD;AACrD,MAAM,CAAC,MAAM,kBAAkB,GAAG,gBAAgB,CAAC;AAEnD,uDAAuD;AACvD,MAAM,CAAC,MAAM,yBAAyB,GAAG,iCAAiC,CAAC;AAE3E,kDAAkD;AAClD,MAAM,CAAC,MAAM,gBAAgB,GAAG,OAAO,CAAC;AAExC;;;GAGG;AACH,MAAM,CAAC,MAAM,6BAA6B,GAAG,IAAI,CAAC;AAElD;;;;;;GAMG;AACH,MAAM,yBAAyB,GAC7B,qFAAqF,CAAC;AAExF,8EAA8E;AAC9E,UAAU;AACV,8EAA8E;AAE9E;;;;;;GAMG;AACH,MAAM,UAAU,YAAY,CAAC,KAAY;IACvC,OAAO,kBAAkB,CAAC,KAAK,CAAC,IAA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AAM,EAAE,QAAQ,EAAE,CAAC;IAC1D,CAAC;CACF,CAAC"}
|
|
@@ -4,11 +4,13 @@
|
|
|
4
4
|
* Exports all platform adapters in a Map keyed by PlatformId,
|
|
5
5
|
* plus a sorted list of supported platform identifiers for error messages.
|
|
6
6
|
*
|
|
7
|
-
* Requirements: 1.1, 1.3, claude-codex-only/AC-1
|
|
7
|
+
* Requirements: 1.1, 1.3, claude-codex-only/AC-1, bring-back-copilot/AC-1, bring-back-copilot/AC-20
|
|
8
8
|
*
|
|
9
9
|
* @module
|
|
10
10
|
*/
|
|
11
11
|
import type { PlatformAdapter, PlatformId } from '../../core/types.js';
|
|
12
|
+
import { listInWords } from './list-in-words.js';
|
|
13
|
+
export { listInWords };
|
|
12
14
|
/** All registered platform adapters, keyed by platform identifier. */
|
|
13
15
|
export declare const adapters: Map<PlatformId, PlatformAdapter>;
|
|
14
16
|
/** Sorted list of supported platform identifiers (for error messages). */
|
|
@@ -18,7 +20,8 @@ export declare const supportedPlatforms: PlatformId[];
|
|
|
18
20
|
*
|
|
19
21
|
* Named rather than left to fall through as "unknown": a project configured for
|
|
20
22
|
* one of these did nothing wrong, and the generic unknown-platform warning reads
|
|
21
|
-
* as a typo (claude-codex-only, design D2).
|
|
23
|
+
* as a typo (claude-codex-only, design D2). Copilot was dropped in 2.0.0 and came
|
|
24
|
+
* back for a real user (bring-back-copilot/AC-19).
|
|
22
25
|
*/
|
|
23
26
|
export declare const droppedPlatforms: readonly string[];
|
|
24
27
|
/** Was this platform removed in aidlc 2? */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/compile/adapters/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,OAAO,KAAK,EAAE,eAAe,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAIvE,sEAAsE;AACtE,eAAO,MAAM,QAAQ,EAAE,GAAG,CAAC,UAAU,EAAE,eAAe,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/compile/adapters/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAGH,OAAO,KAAK,EAAE,eAAe,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAC;AAIvE,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,OAAO,EAAE,WAAW,EAAE,CAAC;AAEvB,sEAAsE;AACtE,eAAO,MAAM,QAAQ,EAAE,GAAG,CAAC,UAAU,EAAE,eAAe,CAIpD,CAAC;AAEH,0EAA0E;AAC1E,eAAO,MAAM,kBAAkB,EAAE,UAAU,EAAgC,CAAC;AAE5E;;;;;;;GAOG;AACH,eAAO,MAAM,gBAAgB,EAAE,SAAS,MAAM,EAAmC,CAAC;AAGlF,4CAA4C;AAC5C,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAE3D;AAED,8FAA8F;AAC9F,MAAM,WAAW,iBAAiB;IAChC,SAAS,EAAE,UAAU,EAAE,CAAC;IACxB,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,OAAO,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,wBAAgB,kBAAkB,CAAC,SAAS,EAAE,SAAS,MAAM,EAAE,GAAG,iBAAiB,CAQlF;AAED;;;;;;;GAOG;AACH,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,GAAG,MAAM,GAAG,IAAI,CAWhF;AAED,gHAAgH;AAChH,wBAAgB,sBAAsB,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,CAO/D"}
|
|
@@ -4,17 +4,21 @@
|
|
|
4
4
|
* Exports all platform adapters in a Map keyed by PlatformId,
|
|
5
5
|
* plus a sorted list of supported platform identifiers for error messages.
|
|
6
6
|
*
|
|
7
|
-
* Requirements: 1.1, 1.3, claude-codex-only/AC-1
|
|
7
|
+
* Requirements: 1.1, 1.3, claude-codex-only/AC-1, bring-back-copilot/AC-1, bring-back-copilot/AC-20
|
|
8
8
|
*
|
|
9
9
|
* @module
|
|
10
10
|
*/
|
|
11
11
|
import { FEEDBACK_ISSUES_URL } from '../../core/feedback.js';
|
|
12
12
|
import { claudeCodeAdapter } from './claude-code.js';
|
|
13
13
|
import { codexAdapter } from './codex.js';
|
|
14
|
+
import { copilotAdapter } from './copilot.js';
|
|
15
|
+
import { listInWords } from './list-in-words.js';
|
|
16
|
+
export { listInWords };
|
|
14
17
|
/** All registered platform adapters, keyed by platform identifier. */
|
|
15
18
|
export const adapters = new Map([
|
|
16
19
|
['claude-code', claudeCodeAdapter],
|
|
17
20
|
['codex', codexAdapter],
|
|
21
|
+
['copilot', copilotAdapter],
|
|
18
22
|
]);
|
|
19
23
|
/** Sorted list of supported platform identifiers (for error messages). */
|
|
20
24
|
export const supportedPlatforms = [...adapters.keys()].sort();
|
|
@@ -23,9 +27,10 @@ export const supportedPlatforms = [...adapters.keys()].sort();
|
|
|
23
27
|
*
|
|
24
28
|
* Named rather than left to fall through as "unknown": a project configured for
|
|
25
29
|
* one of these did nothing wrong, and the generic unknown-platform warning reads
|
|
26
|
-
* as a typo (claude-codex-only, design D2).
|
|
30
|
+
* as a typo (claude-codex-only, design D2). Copilot was dropped in 2.0.0 and came
|
|
31
|
+
* back for a real user (bring-back-copilot/AC-19).
|
|
27
32
|
*/
|
|
28
|
-
export const droppedPlatforms = ['
|
|
33
|
+
export const droppedPlatforms = ['cursor', 'kiro', 'windsurf'];
|
|
29
34
|
/** Was this platform removed in aidlc 2? */
|
|
30
35
|
export function isDroppedPlatform(platform) {
|
|
31
36
|
return droppedPlatforms.includes(platform);
|
|
@@ -56,7 +61,7 @@ export function droppedPlatformsNotice(dropped) {
|
|
|
56
61
|
const names = [...new Set(dropped)].join(', ');
|
|
57
62
|
const these = dropped.length === 1 ? 'Its files were' : 'Their files were';
|
|
58
63
|
const them = dropped.length === 1 ? 'it' : 'them';
|
|
59
|
-
return (`${names}: no longer supported as of aidlc 2, which supports ${supportedPlatforms
|
|
64
|
+
return (`${names}: no longer supported as of aidlc 2, which supports ${listInWords(supportedPlatforms)} only. ` +
|
|
60
65
|
`${these} left alone. To keep updating ${them}, stay on aidlc 1.x (npm i -g @rasensio/aidlc@1). ` +
|
|
61
66
|
`Need ${them} back? Say so at ${FEEDBACK_ISSUES_URL}. ` +
|
|
62
67
|
`To silence this, remove ${them} from platforms: in .aidlc/config.yaml.`);
|
|
@@ -64,7 +69,7 @@ export function droppedPlatformsNotice(dropped) {
|
|
|
64
69
|
/** The refusal for `aidlc init --platform <dropped>` (claude-codex-only/AC-3, public-feedback-channel/AC-2). */
|
|
65
70
|
export function droppedPlatformRefusal(platform) {
|
|
66
71
|
return (`Error: '${platform}' is no longer supported as of aidlc 2.\n` +
|
|
67
|
-
`Supported platforms: ${supportedPlatforms
|
|
72
|
+
`Supported platforms: ${listInWords(supportedPlatforms)}\n` +
|
|
68
73
|
`To keep using ${platform}, stay on aidlc 1.x (npm i -g @rasensio/aidlc@1).\n` +
|
|
69
74
|
`Need ${platform} back? Say so at ${FEEDBACK_ISSUES_URL}\n`);
|
|
70
75
|
}
|