@open-product-primer/cli 0.12.0 → 0.13.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/dist/commands/init.js
CHANGED
|
@@ -48,7 +48,7 @@ function initCommand() {
|
|
|
48
48
|
return new commander_1.Command('init')
|
|
49
49
|
.description('Initialize oprim in the current repository')
|
|
50
50
|
.option('--name <name>', 'project name (defaults to directory name)')
|
|
51
|
-
.option('--agent <name>', 'AI agent to install skills for (repeatable; supported: claude, cursor)', (val, prev) => [...prev, val], [])
|
|
51
|
+
.option('--agent <name>', 'AI agent to install skills for (repeatable; supported: claude, cursor, codex, gemini, poolside)', (val, prev) => [...prev, val], [])
|
|
52
52
|
.action(async (opts) => {
|
|
53
53
|
const projectRoot = process.cwd();
|
|
54
54
|
const projectName = opts.name ?? path.basename(projectRoot);
|
package/dist/lib/detect.js
CHANGED
|
@@ -72,6 +72,8 @@ function detectAvailableAgents(projectRoot) {
|
|
|
72
72
|
detected.push('codex');
|
|
73
73
|
if (fs.existsSync(path.join(projectRoot, 'GEMINI.md')))
|
|
74
74
|
detected.push('gemini');
|
|
75
|
+
if (fs.existsSync(path.join(projectRoot, '.poolside')))
|
|
76
|
+
detected.push('poolside');
|
|
75
77
|
return detected;
|
|
76
78
|
}
|
|
77
79
|
function writeAgentsToConfig(agents, projectRoot) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export type Agent = 'claude' | 'cursor' | 'codex' | 'gemini';
|
|
1
|
+
export type Agent = 'claude' | 'cursor' | 'codex' | 'gemini' | 'poolside';
|
|
2
2
|
export declare const SUPPORTED_AGENTS: readonly Agent[];
|
|
3
3
|
export declare function promptFrameworkSelection(projectRoot: string): Promise<string>;
|
|
4
4
|
export declare function promptAgentSelection(projectRoot: string): Promise<string[]>;
|
|
@@ -7,8 +7,10 @@ export declare function installAgentSkills(agent: Agent, projectRoot: string, fr
|
|
|
7
7
|
export declare const OPRIM_CONTEXT_SKILL_STEP = "## Step 0: Check relevant product decisions\nInvoke the `oprim:context` skill using the Skill tool. If matching PDRs are surfaced, review them before proceeding. If no PDRs match or `oprim/decisions/` is empty, the skill exits silently \u2014 continue to Step 1 immediately.";
|
|
8
8
|
export declare const CLAUDE_SKILLS: Record<string, string>;
|
|
9
9
|
export declare const CLAUDE_COMMANDS: Record<string, string>;
|
|
10
|
+
export declare const POOLSIDE_SKILLS: Record<string, string>;
|
|
10
11
|
export declare const CURSOR_SKILLS: Record<string, string>;
|
|
11
12
|
export declare const CURSOR_COMMANDS: Record<string, string>;
|
|
12
13
|
export declare function writeAgentInstructionFile(filePath: string, section: string): void;
|
|
13
14
|
export declare function codexInstructions(): string;
|
|
14
15
|
export declare function geminiInstructions(): string;
|
|
16
|
+
export declare function poolsideInstructions(): string;
|
|
@@ -36,7 +36,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.CURSOR_COMMANDS = exports.CURSOR_SKILLS = exports.CLAUDE_COMMANDS = exports.CLAUDE_SKILLS = exports.OPRIM_CONTEXT_SKILL_STEP = exports.SUPPORTED_AGENTS = void 0;
|
|
39
|
+
exports.CURSOR_COMMANDS = exports.CURSOR_SKILLS = exports.POOLSIDE_SKILLS = exports.CLAUDE_COMMANDS = exports.CLAUDE_SKILLS = exports.OPRIM_CONTEXT_SKILL_STEP = exports.SUPPORTED_AGENTS = void 0;
|
|
40
40
|
exports.promptFrameworkSelection = promptFrameworkSelection;
|
|
41
41
|
exports.promptAgentSelection = promptAgentSelection;
|
|
42
42
|
exports.promptPdrSurfacing = promptPdrSurfacing;
|
|
@@ -44,12 +44,13 @@ exports.installAgentSkills = installAgentSkills;
|
|
|
44
44
|
exports.writeAgentInstructionFile = writeAgentInstructionFile;
|
|
45
45
|
exports.codexInstructions = codexInstructions;
|
|
46
46
|
exports.geminiInstructions = geminiInstructions;
|
|
47
|
+
exports.poolsideInstructions = poolsideInstructions;
|
|
47
48
|
const path = __importStar(require("path"));
|
|
48
49
|
const fs = __importStar(require("fs"));
|
|
49
50
|
const chalk_1 = __importDefault(require("chalk"));
|
|
50
51
|
const scaffold_1 = require("./scaffold");
|
|
51
52
|
const detect_1 = require("./detect");
|
|
52
|
-
exports.SUPPORTED_AGENTS = ['claude', 'cursor', 'codex', 'gemini'];
|
|
53
|
+
exports.SUPPORTED_AGENTS = ['claude', 'cursor', 'codex', 'gemini', 'poolside'];
|
|
53
54
|
async function promptFrameworkSelection(projectRoot) {
|
|
54
55
|
const configPath = path.join(projectRoot, '.claude', 'hooks', 'config.json');
|
|
55
56
|
if (fs.existsSync(configPath)) {
|
|
@@ -87,6 +88,7 @@ async function promptAgentSelection(projectRoot) {
|
|
|
87
88
|
{ name: 'Cursor', value: 'cursor', checked: detected.includes('cursor') },
|
|
88
89
|
{ name: 'Codex', value: 'codex', checked: detected.includes('codex') },
|
|
89
90
|
{ name: 'Gemini CLI', value: 'gemini', checked: detected.includes('gemini') },
|
|
91
|
+
{ name: 'Poolside', value: 'poolside', checked: detected.includes('poolside') },
|
|
90
92
|
],
|
|
91
93
|
});
|
|
92
94
|
}
|
|
@@ -170,6 +172,21 @@ function installAgentSkills(agent, projectRoot, framework = 'openspec', pdrSurfa
|
|
|
170
172
|
console.log(chalk_1.default.dim(' .claude/ created — Claude Code will discover these files automatically.'));
|
|
171
173
|
}
|
|
172
174
|
}
|
|
175
|
+
else if (agent === 'poolside') {
|
|
176
|
+
const poolsideDir = path.join(projectRoot, '.poolside');
|
|
177
|
+
const dirCreated = !fs.existsSync(poolsideDir);
|
|
178
|
+
const skillsBase = path.join(poolsideDir, 'skills');
|
|
179
|
+
for (const [name, content] of Object.entries(exports.POOLSIDE_SKILLS)) {
|
|
180
|
+
(0, scaffold_1.writeFile)(path.join(skillsBase, name, 'SKILL.md'), content);
|
|
181
|
+
console.log(chalk_1.default.green('✓') + ` .poolside/skills/${name}/SKILL.md`);
|
|
182
|
+
}
|
|
183
|
+
const agentsFile = path.join(projectRoot, 'AGENTS.md');
|
|
184
|
+
writeAgentInstructionFile(agentsFile, poolsideInstructions());
|
|
185
|
+
console.log(chalk_1.default.green('✓') + ' AGENTS.md (oprim section written)');
|
|
186
|
+
if (dirCreated) {
|
|
187
|
+
console.log(chalk_1.default.dim(' .poolside/ created — Poolside will discover these files automatically.'));
|
|
188
|
+
}
|
|
189
|
+
}
|
|
173
190
|
else if (agent === 'codex') {
|
|
174
191
|
const agentsFile = path.join(projectRoot, 'AGENTS.md');
|
|
175
192
|
writeAgentInstructionFile(agentsFile, codexInstructions());
|
|
@@ -280,6 +297,15 @@ exports.CLAUDE_COMMANDS = {
|
|
|
280
297
|
'sequence.md': claudeWrapper('OPRIM: Sequence', 'Validate and update the primer sequencing board', sequenceContent()),
|
|
281
298
|
'archive.md': claudeWrapper('OPRIM: Archive', 'Archive a completed bet — move it out of the active board', archiveCommandContent()),
|
|
282
299
|
};
|
|
300
|
+
// ─── Poolside skill playbooks ─────────────────────────────────────────────────
|
|
301
|
+
exports.POOLSIDE_SKILLS = {
|
|
302
|
+
'oprim-pdr': pdrSkill(),
|
|
303
|
+
'oprim-bet': betSkill(),
|
|
304
|
+
'oprim-criteria': criteriaSkill(),
|
|
305
|
+
'oprim-review': reviewSkill(),
|
|
306
|
+
'oprim-archive': archiveSkill(),
|
|
307
|
+
'oprim-sequence': oprimSequenceSkill(),
|
|
308
|
+
};
|
|
283
309
|
// ─── Cursor skill playbooks ───────────────────────────────────────────────────
|
|
284
310
|
exports.CURSOR_SKILLS = {
|
|
285
311
|
'oprim-pdr': pdrSkill(),
|
|
@@ -1127,3 +1153,6 @@ function codexInstructions() {
|
|
|
1127
1153
|
function geminiInstructions() {
|
|
1128
1154
|
return oprimWorkflowsInline();
|
|
1129
1155
|
}
|
|
1156
|
+
function poolsideInstructions() {
|
|
1157
|
+
return oprimWorkflowsInline();
|
|
1158
|
+
}
|