@antoneeo/agentic-sdlc-skill 1.0.8 → 1.0.9
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/CHANGELOG.md +12 -0
- package/gemini-extension.json +1 -1
- package/package.json +7 -1
- package/scripts/init.js +114 -60
- package/scripts/postinstall.js +36 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
Tutte le modifiche significative a questa skill saranno documentate in questo file.
|
|
4
4
|
|
|
5
|
+
## [1.0.9] - 2026-05-10
|
|
6
|
+
### Added
|
|
7
|
+
- New **Smart Discovery** system during project initialization.
|
|
8
|
+
- Official support for **Codex AI** via automatic `.codex/hooks.json` injection.
|
|
9
|
+
- Support for **Cursor** and **Windsurf** via `.cursorrules`.
|
|
10
|
+
- Binary command `agentic-sdlc-init` for use via `npx`.
|
|
11
|
+
- `postinstall` script for global AI CLI detection (Claude, Gemini, Codex).
|
|
12
|
+
- Full English localization for all user-facing messages and scripts.
|
|
13
|
+
|
|
14
|
+
### Changed
|
|
15
|
+
- Updated `init.js` to support the new `ai_docs/` directory structure defined in v1.0.8.
|
|
16
|
+
|
|
5
17
|
## [1.0.8] - 2026-05-10
|
|
6
18
|
### Aggiunto
|
|
7
19
|
- Skill evoluta in "Hybrid Edition": integrazione opzionale con **devPNT** (server MCP) per governance avanzata tramite database e piani gerarchici.
|
package/gemini-extension.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@antoneeo/agentic-sdlc-skill",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.9",
|
|
4
4
|
"description": "Protocollo SDLC Documentation-First per Gemini CLI. Gestisce audit, analisi, sviluppo e chiusura feature con documentazione sincronizzata.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"gemini-cli",
|
|
@@ -14,6 +14,12 @@
|
|
|
14
14
|
"publishConfig": {
|
|
15
15
|
"access": "public"
|
|
16
16
|
},
|
|
17
|
+
"bin": {
|
|
18
|
+
"agentic-sdlc-init": "scripts/init.js"
|
|
19
|
+
},
|
|
20
|
+
"scripts": {
|
|
21
|
+
"postinstall": "node scripts/postinstall.js"
|
|
22
|
+
},
|
|
17
23
|
"files": [
|
|
18
24
|
"skills",
|
|
19
25
|
"gemini-extension.json",
|
package/scripts/init.js
CHANGED
|
@@ -1,93 +1,147 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
1
|
+
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
const fs = require('fs');
|
|
4
4
|
const path = require('path');
|
|
5
|
+
const { execSync } = require('child_process');
|
|
5
6
|
|
|
6
7
|
const cwd = process.cwd();
|
|
7
8
|
|
|
8
|
-
//
|
|
9
|
+
// Helper for command checking
|
|
10
|
+
function checkCommand(cmd) {
|
|
11
|
+
try {
|
|
12
|
+
execSync(`${cmd} --version`, { stdio: 'ignore' });
|
|
13
|
+
return true;
|
|
14
|
+
} catch (e) {
|
|
15
|
+
return false;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
// 1. Path definitions
|
|
9
20
|
const directories = [
|
|
10
|
-
path.join(cwd, '
|
|
11
|
-
path.join(cwd, '
|
|
21
|
+
path.join(cwd, 'ai_docs'),
|
|
22
|
+
path.join(cwd, 'ai_docs', 'strategic'),
|
|
23
|
+
path.join(cwd, 'ai_docs', 'audit'),
|
|
24
|
+
path.join(cwd, 'ai_docs', 'solutions'),
|
|
25
|
+
path.join(cwd, '.codex')
|
|
12
26
|
];
|
|
13
27
|
|
|
14
28
|
const files = {
|
|
15
|
-
architecture: path.join(cwd, '
|
|
16
|
-
existingFeatures: path.join(cwd, '
|
|
17
|
-
featuresHistory: path.join(cwd, '
|
|
29
|
+
architecture: path.join(cwd, 'ai_docs', 'strategic', 'architecture.md'),
|
|
30
|
+
existingFeatures: path.join(cwd, 'ai_docs', 'strategic', 'existing_features.md'),
|
|
31
|
+
featuresHistory: path.join(cwd, 'ai_docs', 'strategic', 'features_history.md'),
|
|
32
|
+
auditPlan: path.join(cwd, 'ai_docs', 'audit', 'audit_plan.md'),
|
|
33
|
+
handoff: path.join(cwd, 'ai_docs', 'audit', 'handoff.md'),
|
|
18
34
|
claudeConfig: path.join(cwd, 'CLAUDE.md'),
|
|
19
|
-
geminiConfig: path.join(cwd, 'GEMINI.md')
|
|
35
|
+
geminiConfig: path.join(cwd, 'GEMINI.md'),
|
|
36
|
+
codexHooks: path.join(cwd, '.codex', 'hooks.json'),
|
|
37
|
+
cursorRules: path.join(cwd, '.cursorrules')
|
|
20
38
|
};
|
|
21
39
|
|
|
22
|
-
// 2.
|
|
23
|
-
const protocolContent = `#
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
## 1.
|
|
28
|
-
|
|
29
|
-
-
|
|
30
|
-
-
|
|
31
|
-
1. \`
|
|
32
|
-
2. \`
|
|
33
|
-
3. \`
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
## 2.
|
|
37
|
-
|
|
38
|
-
-
|
|
39
|
-
-
|
|
40
|
-
|
|
41
|
-
## 3.
|
|
42
|
-
|
|
43
|
-
1.
|
|
44
|
-
2.
|
|
45
|
-
3. **
|
|
46
|
-
4.
|
|
47
|
-
|
|
48
|
-
## 4.
|
|
49
|
-
|
|
50
|
-
-
|
|
51
|
-
-
|
|
40
|
+
// 2. Operational Protocol (System Prompt)
|
|
41
|
+
const protocolContent = `# "Agentic SDLC" Operational Protocol
|
|
42
|
+
|
|
43
|
+
You are a senior software engineer strictly following a "Documentation-First" process. NEVER implement code without completing the preceding documentation steps. Use your tools (file read/write, shell execution) to adhere to the following phases.
|
|
44
|
+
|
|
45
|
+
## 1. Audit and Alignment Phase
|
|
46
|
+
Before responding to any operational request:
|
|
47
|
+
- Check for the existence of the \`ai_docs/\` folder.
|
|
48
|
+
- If \`ai_docs/\` is missing or essential documents are absent, create them by analyzing the source code:
|
|
49
|
+
1. \`ai_docs/strategic/architecture.md\`: Tech Stack, Directory Structure, Architecture Patterns.
|
|
50
|
+
2. \`ai_docs/strategic/existing_features.md\`: List of current features.
|
|
51
|
+
3. \`ai_docs/strategic/features_history.md\`: Feature history table (ID, Name, Status, Dates).
|
|
52
|
+
4. \`ai_docs/audit/audit_plan.md\`: Codebase analysis plan in batches.
|
|
53
|
+
|
|
54
|
+
## 2. Request Analysis Phase
|
|
55
|
+
For every new feature request:
|
|
56
|
+
- Create \`ai_docs/solutions/ANALYSIS_[feature_name].md\` (Objective, Impact, Action Plan, Test Strategy).
|
|
57
|
+
- Add a entry in \`features_history.md\` with status \`[PLANNED]\`.
|
|
58
|
+
|
|
59
|
+
## 3. Development and Testing Phase
|
|
60
|
+
Only after Phase 2 is complete:
|
|
61
|
+
1. Update feature status to \`[IN_PROGRESS]\`.
|
|
62
|
+
2. Implement code surgically following the plan.
|
|
63
|
+
3. **Mandatory:** Write automated tests following the **AAA (Arrange, Act, Assert)** pattern.
|
|
64
|
+
4. Execute tests. If they fail, fix and re-run until Exit Code is 0.
|
|
65
|
+
|
|
66
|
+
## 4. Closing Phase
|
|
67
|
+
Upon feature completion:
|
|
68
|
+
- Update \`architecture.md\` and \`existing_features.md\` if necessary.
|
|
69
|
+
- Update \`features_history.md\` setting status to \`[COMPLETED]\`.
|
|
52
70
|
`;
|
|
53
71
|
|
|
54
|
-
|
|
55
|
-
|
|
72
|
+
const codexHooksContent = JSON.stringify({
|
|
73
|
+
hooks: {
|
|
74
|
+
SessionStart: [
|
|
75
|
+
{
|
|
76
|
+
hooks: [
|
|
77
|
+
{
|
|
78
|
+
type: "command",
|
|
79
|
+
command: `echo '${protocolContent.replace(/'/g, "'\\''")}'`
|
|
80
|
+
}
|
|
81
|
+
]
|
|
82
|
+
}
|
|
83
|
+
]
|
|
84
|
+
}
|
|
85
|
+
}, null, 2);
|
|
86
|
+
|
|
87
|
+
const historyBoilerplate = `# Feature History
|
|
56
88
|
|
|
57
|
-
| ID |
|
|
89
|
+
| ID | Feature Name | Status | Start Date | End Date | Analysis Doc | Notes |
|
|
58
90
|
|:---|:---|:---|:---|:---|:---|:---|
|
|
59
|
-
| 000 | Init
|
|
91
|
+
| 000 | Project Init | [COMPLETED] | - | - | - | Automatic initialization |
|
|
60
92
|
`;
|
|
61
93
|
|
|
62
|
-
console.log('🚀
|
|
94
|
+
console.log('🚀 Initializing Agentic SDLC workflow (Discovery Mode)...');
|
|
63
95
|
|
|
64
|
-
// 3.
|
|
96
|
+
// 3. Directory creation
|
|
65
97
|
directories.forEach(dir => {
|
|
66
98
|
if (!fs.existsSync(dir)) {
|
|
67
99
|
fs.mkdirSync(dir, { recursive: true });
|
|
68
|
-
console.log(`📁
|
|
100
|
+
console.log(`📁 Created directory: ${path.relative(cwd, dir)}`);
|
|
69
101
|
}
|
|
70
102
|
});
|
|
71
103
|
|
|
72
|
-
// 4.
|
|
104
|
+
// 4. Basic file writing
|
|
73
105
|
const writeIfNotExists = (filePath, content, description) => {
|
|
74
106
|
if (!fs.existsSync(filePath)) {
|
|
75
107
|
fs.writeFileSync(filePath, content, 'utf8');
|
|
76
|
-
console.log(`📄
|
|
108
|
+
console.log(`📄 Created file: ${path.relative(cwd, filePath)} (${description})`);
|
|
109
|
+
return true;
|
|
77
110
|
} else {
|
|
78
|
-
console.log(`⏭️
|
|
111
|
+
console.log(`⏭️ Skipped: ${path.relative(cwd, filePath)} already exists.`);
|
|
112
|
+
return false;
|
|
79
113
|
}
|
|
80
114
|
};
|
|
81
115
|
|
|
82
|
-
writeIfNotExists(files.architecture, '#
|
|
83
|
-
writeIfNotExists(files.existingFeatures, '#
|
|
84
|
-
writeIfNotExists(files.featuresHistory, historyBoilerplate, '
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
console.log('
|
|
92
|
-
|
|
93
|
-
|
|
116
|
+
writeIfNotExists(files.architecture, '# Project Architecture\n\n- Stack:\n- Patterns:\n', 'Architecture Boilerplate');
|
|
117
|
+
writeIfNotExists(files.existingFeatures, '# Existing Features\n\n- \n', 'Features Boilerplate');
|
|
118
|
+
writeIfNotExists(files.featuresHistory, historyBoilerplate, 'History Table');
|
|
119
|
+
writeIfNotExists(files.auditPlan, '# Audit Plan\n\n| Directory/File | Status | Notes |\n|:---|:---|:---|\n| / | [PENDING] | Initial analysis |\n', 'Audit Plan');
|
|
120
|
+
|
|
121
|
+
// 5. Client Discovery and Configuration
|
|
122
|
+
console.log('\n--- Environment Analysis ---');
|
|
123
|
+
|
|
124
|
+
if (checkCommand('claude')) {
|
|
125
|
+
console.log('✅ Claude Code detected.');
|
|
126
|
+
writeIfNotExists(files.claudeConfig, protocolContent, 'Claude Configuration');
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
if (checkCommand('gemini')) {
|
|
130
|
+
console.log('✅ Gemini CLI detected.');
|
|
131
|
+
writeIfNotExists(files.geminiConfig, protocolContent, 'Gemini Configuration');
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
if (checkCommand('codex')) {
|
|
135
|
+
console.log('✅ Codex AI detected.');
|
|
136
|
+
writeIfNotExists(files.codexHooks, codexHooksContent, 'Codex AI Hooks');
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
// Cursor/Windsurf (always recommended)
|
|
140
|
+
writeIfNotExists(files.cursorRules, protocolContent, 'Cursor/Windsurf Rules');
|
|
141
|
+
|
|
142
|
+
console.log('\n✅ Setup completed successfully!');
|
|
143
|
+
console.log('💡 Next steps:');
|
|
144
|
+
console.log(' 1. If using Claude Code, start it: it will read CLAUDE.md.');
|
|
145
|
+
console.log(' 2. If using Gemini CLI, commands will use GEMINI.md.');
|
|
146
|
+
console.log(' 3. If using Codex, session hooks will inject the protocol.');
|
|
147
|
+
console.log(' 4. Start analyzing the codebase following ai_docs/audit/audit_plan.md.');
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
const { execSync } = require('child_process');
|
|
4
|
+
|
|
5
|
+
function checkCommand(cmd) {
|
|
6
|
+
try {
|
|
7
|
+
execSync(`${cmd} --version`, { stdio: 'ignore' });
|
|
8
|
+
return true;
|
|
9
|
+
} catch (e) {
|
|
10
|
+
return false;
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
console.log('\n--- Agentic SDLC Skill Discovery ---');
|
|
15
|
+
|
|
16
|
+
const agents = [
|
|
17
|
+
{ name: 'Claude Code', cmd: 'claude' },
|
|
18
|
+
{ name: 'Gemini CLI', cmd: 'gemini' },
|
|
19
|
+
{ name: 'Codex AI', cmd: 'codex' }
|
|
20
|
+
];
|
|
21
|
+
|
|
22
|
+
let detected = false;
|
|
23
|
+
agents.forEach(agent => {
|
|
24
|
+
if (checkCommand(agent.cmd)) {
|
|
25
|
+
console.log(`✅ Detected: ${agent.name}`);
|
|
26
|
+
detected = true;
|
|
27
|
+
}
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
if (!detected) {
|
|
31
|
+
console.log('ℹ️ No specific AI CLI detected globally, but you can still use the skill.');
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
console.log('\nTo initialize a project with the SDLC protocol, run:');
|
|
35
|
+
console.log('👉 npx agentic-sdlc-init');
|
|
36
|
+
console.log('------------------------------------\n');
|