@agentic15.com/agentic15-claude-zen 4.0.0 โ 4.0.3
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 +24 -10
- package/package.json +1 -1
- package/src/cli/CommitCommand.js +34 -24
- package/src/cli/TaskCommand.js +1 -0
- package/src/cli/UpgradeCommand.js +4 -1
- package/src/core/TemplateManager.js +0 -8
- package/templates/package.json +1 -16
- package/templates/.babelrc +0 -6
- package/templates/__mocks__/fileMock.js +0 -9
- package/templates/jest.config.js +0 -48
- package/templates/jest.setup.js +0 -13
package/README.md
CHANGED
|
@@ -28,6 +28,7 @@ cd my-project
|
|
|
28
28
|
```bash
|
|
29
29
|
# Initialize git (if not already done)
|
|
30
30
|
git init
|
|
31
|
+
git branch -M main # Rename master to main
|
|
31
32
|
git add .
|
|
32
33
|
git commit -m "Initial commit"
|
|
33
34
|
|
|
@@ -51,7 +52,7 @@ cat > /tmp/protection.json << 'EOF'
|
|
|
51
52
|
"required_pull_request_reviews": {
|
|
52
53
|
"required_approving_review_count": 0
|
|
53
54
|
},
|
|
54
|
-
"enforce_admins":
|
|
55
|
+
"enforce_admins": false,
|
|
55
56
|
"allow_force_pushes": false,
|
|
56
57
|
"allow_deletions": false,
|
|
57
58
|
"required_status_checks": null,
|
|
@@ -77,7 +78,7 @@ $body = @"
|
|
|
77
78
|
"required_pull_request_reviews": {
|
|
78
79
|
"required_approving_review_count": 0
|
|
79
80
|
},
|
|
80
|
-
"enforce_admins":
|
|
81
|
+
"enforce_admins": false,
|
|
81
82
|
"allow_force_pushes": false,
|
|
82
83
|
"allow_deletions": false,
|
|
83
84
|
"required_status_checks": null,
|
|
@@ -93,25 +94,38 @@ gh api repos/OWNER/REPO -X PATCH -H "Accept: application/vnd.github+json" -f del
|
|
|
93
94
|
|
|
94
95
|
Replace `OWNER/REPO` with your GitHub username and repository name.
|
|
95
96
|
|
|
96
|
-
**Step 5: Launch Claude Code**
|
|
97
97
|
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
> **IMPORTANT**: Always launch Claude Code from inside your project directory, not from the parent directory.
|
|
101
|
-
|
|
102
|
-
**Step 6: Use Framework Commands**
|
|
98
|
+
**Step 5: Use Framework Commands**
|
|
103
99
|
```bash
|
|
104
100
|
npx agentic15 auth # One-time GitHub setup
|
|
105
101
|
npx agentic15 plan # Enter interactive mode
|
|
106
102
|
# Type/paste your requirements, press Ctrl+D when done
|
|
103
|
+
```
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
**Step 6: Launch Claude Code in Another Terminal**
|
|
107
|
+
|
|
107
108
|
# Open another terminal. Make sure that you in your project directory. Launch Claude
|
|
109
|
+
Start Claude Code CLI from inside the `my-project` directory. Claude Code MUST be running from inside your project directory to access the framework files.
|
|
108
110
|
# Ask Claude: "Read the requirements file and generate a task breakdown plan"
|
|
111
|
+
|
|
112
|
+
|
|
113
|
+
**Step 7: User Termianl and Not Claude Terminal**
|
|
114
|
+
```
|
|
115
|
+
npx agentic15 plan # Generate Task Files and Lock Plan
|
|
109
116
|
npx agentic15 task next # Start first task
|
|
110
|
-
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
**Step 8: Claude Terminal**
|
|
120
|
+
# Ask Claude: "Implement this Active task"
|
|
121
|
+
|
|
122
|
+
**Step 9: User Termianl Not Claude Terminal**
|
|
123
|
+
```
|
|
111
124
|
npx agentic15 commit # Test, commit, push, PR
|
|
112
125
|
```
|
|
113
126
|
|
|
114
|
-
|
|
127
|
+
|
|
128
|
+
**Step 10: Clean Up Local Branches**
|
|
115
129
|
```bash
|
|
116
130
|
# If auto-delete is enabled, only clean up local branches
|
|
117
131
|
git branch -d feature/task-001
|
package/package.json
CHANGED
package/src/cli/CommitCommand.js
CHANGED
|
@@ -19,32 +19,31 @@ export class CommitCommand {
|
|
|
19
19
|
|
|
20
20
|
console.log(`๐ Task: ${task.id} - ${task.title}\n`);
|
|
21
21
|
|
|
22
|
-
// Step 2:
|
|
23
|
-
console.log('
|
|
24
|
-
this.runTests();
|
|
25
|
-
|
|
26
|
-
// Step 3: Stage files in Agent/
|
|
27
|
-
console.log('\n๐ฆ Staging changes...\n');
|
|
22
|
+
// Step 2: Stage files in Agent/
|
|
23
|
+
console.log('๐ฆ Staging changes...\n');
|
|
28
24
|
this.stageFiles();
|
|
29
25
|
|
|
30
|
-
// Step
|
|
26
|
+
// Step 3: Generate commit message
|
|
31
27
|
const commitMessage = this.generateCommitMessage(task);
|
|
32
28
|
|
|
33
|
-
// Step
|
|
29
|
+
// Step 4: Commit
|
|
34
30
|
console.log('๐พ Creating commit...\n');
|
|
35
31
|
this.createCommit(commitMessage);
|
|
36
32
|
|
|
37
|
-
// Step
|
|
33
|
+
// Step 5: Push to feature branch
|
|
38
34
|
console.log('โฌ๏ธ Pushing to remote...\n');
|
|
39
35
|
this.pushBranch(task.id);
|
|
40
36
|
|
|
41
|
-
// Step
|
|
37
|
+
// Step 6: Create PR
|
|
42
38
|
console.log('๐ Creating pull request...\n');
|
|
43
39
|
const prUrl = await this.createPullRequest(task, commitMessage);
|
|
44
40
|
|
|
45
|
-
// Step
|
|
41
|
+
// Step 7: Update GitHub issue status
|
|
46
42
|
await this.updateGitHubIssue(task, prUrl);
|
|
47
43
|
|
|
44
|
+
// Step 8: Mark task as completed
|
|
45
|
+
this.markTaskCompleted(task);
|
|
46
|
+
|
|
48
47
|
// Step 9: Display summary
|
|
49
48
|
this.displaySummary(task, prUrl, tracker);
|
|
50
49
|
}
|
|
@@ -71,16 +70,6 @@ export class CommitCommand {
|
|
|
71
70
|
return { task, tracker };
|
|
72
71
|
}
|
|
73
72
|
|
|
74
|
-
static runTests() {
|
|
75
|
-
try {
|
|
76
|
-
execSync('npm test', { stdio: 'inherit' });
|
|
77
|
-
console.log('\nโ
All tests passed');
|
|
78
|
-
} catch (error) {
|
|
79
|
-
console.log('\nโ Tests failed. Fix errors before committing.\n');
|
|
80
|
-
process.exit(1);
|
|
81
|
-
}
|
|
82
|
-
}
|
|
83
|
-
|
|
84
73
|
static stageFiles() {
|
|
85
74
|
try {
|
|
86
75
|
// Stage all files in Agent/
|
|
@@ -194,9 +183,8 @@ export class CommitCommand {
|
|
|
194
183
|
prBody += `- Implemented ${task.title}\n\n`;
|
|
195
184
|
|
|
196
185
|
prBody += `## Testing\n\n`;
|
|
197
|
-
prBody += `- [
|
|
198
|
-
prBody += `- [ ]
|
|
199
|
-
prBody += `- [ ] Code follows project conventions\n\n`;
|
|
186
|
+
prBody += `- [ ] Code follows project conventions\n`;
|
|
187
|
+
prBody += `- [ ] Manual testing completed\n\n`;
|
|
200
188
|
|
|
201
189
|
prBody += `## Notes\n\n`;
|
|
202
190
|
prBody += `Auto-generated by Agentic15 Claude Zen`;
|
|
@@ -266,6 +254,28 @@ export class CommitCommand {
|
|
|
266
254
|
}
|
|
267
255
|
}
|
|
268
256
|
|
|
257
|
+
static markTaskCompleted(task) {
|
|
258
|
+
try {
|
|
259
|
+
const activePlanPath = join(process.cwd(), '.claude', 'ACTIVE-PLAN');
|
|
260
|
+
const planId = readFileSync(activePlanPath, 'utf-8').trim();
|
|
261
|
+
const trackerPath = join(process.cwd(), '.claude', 'plans', planId, 'TASK-TRACKER.json');
|
|
262
|
+
|
|
263
|
+
// Update tracker
|
|
264
|
+
const tracker = JSON.parse(readFileSync(trackerPath, 'utf-8'));
|
|
265
|
+
const taskInTracker = tracker.taskFiles.find(t => t.id === task.id);
|
|
266
|
+
|
|
267
|
+
if (taskInTracker) {
|
|
268
|
+
taskInTracker.status = 'completed';
|
|
269
|
+
taskInTracker.completedAt = new Date().toISOString();
|
|
270
|
+
writeFileSync(trackerPath, JSON.stringify(tracker, null, 2));
|
|
271
|
+
console.log(`\nโ
Marked ${task.id} as completed`);
|
|
272
|
+
}
|
|
273
|
+
} catch (error) {
|
|
274
|
+
console.log(`\nโ ๏ธ Failed to mark task as completed: ${error.message}`);
|
|
275
|
+
console.log(' You may need to manually update TASK-TRACKER.json\n');
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
|
|
269
279
|
static displaySummary(task, prUrl, tracker) {
|
|
270
280
|
console.log('\nโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ');
|
|
271
281
|
console.log('โ โ
Commit Workflow Complete โ');
|
package/src/cli/TaskCommand.js
CHANGED
|
@@ -275,6 +275,7 @@ export class TaskCommand {
|
|
|
275
275
|
console.log('\n 2. Link it to your local project:');
|
|
276
276
|
console.log(' git remote add origin https://github.com/OWNER/REPO.git');
|
|
277
277
|
console.log('\n 3. Push your initial code:');
|
|
278
|
+
console.log(' git branch -M main');
|
|
278
279
|
console.log(' git add .');
|
|
279
280
|
console.log(' git commit -m "Initial commit"');
|
|
280
281
|
console.log(' git push -u origin main');
|
|
@@ -73,7 +73,10 @@ export class UpgradeCommand {
|
|
|
73
73
|
console.log(' - .claude/ACTIVE-PLAN (current plan)');
|
|
74
74
|
console.log(' - .claude/settings.local.json (local settings)');
|
|
75
75
|
console.log(' - Agent/ (your source code)');
|
|
76
|
-
console.log(' -
|
|
76
|
+
console.log(' - scripts/ (your scripts)');
|
|
77
|
+
console.log(' - test-site/ (your test site)');
|
|
78
|
+
console.log(' - package.json (your project config)');
|
|
79
|
+
console.log(' - README.md (your documentation)\n');
|
|
77
80
|
console.log('๐พ Backup location: .claude.backup/\n');
|
|
78
81
|
console.log('โ'.repeat(70) + '\n');
|
|
79
82
|
} catch (error) {
|
|
@@ -66,14 +66,6 @@ export class TemplateManager {
|
|
|
66
66
|
// Copy scripts directory
|
|
67
67
|
this.copyDirectory('scripts', targetDir);
|
|
68
68
|
|
|
69
|
-
// Copy Jest configuration files
|
|
70
|
-
this.copySingleFile('jest.config.js', targetDir);
|
|
71
|
-
this.copySingleFile('jest.setup.js', targetDir);
|
|
72
|
-
this.copySingleFile('.babelrc', targetDir);
|
|
73
|
-
|
|
74
|
-
// Copy __mocks__ directory
|
|
75
|
-
this.copyDirectory('__mocks__', targetDir);
|
|
76
|
-
|
|
77
69
|
console.log('โ
Framework structure created');
|
|
78
70
|
console.log('โ
Templates copied');
|
|
79
71
|
console.log('โ
Configuration files generated');
|
package/templates/package.json
CHANGED
|
@@ -3,9 +3,7 @@
|
|
|
3
3
|
"version": "1.0.0",
|
|
4
4
|
"description": "Project with Claude Code structured development framework",
|
|
5
5
|
"type": "commonjs",
|
|
6
|
-
"scripts": {
|
|
7
|
-
"test": "jest --passWithNoTests"
|
|
8
|
-
},
|
|
6
|
+
"scripts": {},
|
|
9
7
|
"keywords": [
|
|
10
8
|
"claude-code",
|
|
11
9
|
"structured-development",
|
|
@@ -14,18 +12,5 @@
|
|
|
14
12
|
"license": "MIT",
|
|
15
13
|
"dependencies": {
|
|
16
14
|
"@agentic15.com/agentic15-claude-zen": "^2.0.0"
|
|
17
|
-
},
|
|
18
|
-
"devDependencies": {
|
|
19
|
-
"jest": "^30.2.0",
|
|
20
|
-
"@testing-library/react": "^16.1.0",
|
|
21
|
-
"@testing-library/jest-dom": "^6.6.3",
|
|
22
|
-
"@testing-library/user-event": "^14.5.2",
|
|
23
|
-
"@babel/preset-env": "^7.26.0",
|
|
24
|
-
"@babel/preset-react": "^7.26.3",
|
|
25
|
-
"babel-jest": "^30.0.0",
|
|
26
|
-
"jest-environment-jsdom": "^30.0.0",
|
|
27
|
-
"prop-types": "^15.8.1",
|
|
28
|
-
"identity-obj-proxy": "^3.0.0",
|
|
29
|
-
"@playwright/test": "^1.41.0"
|
|
30
15
|
}
|
|
31
16
|
}
|
package/templates/.babelrc
DELETED
package/templates/jest.config.js
DELETED
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Jest Configuration
|
|
3
|
-
* Framework-agnostic configuration supporting React, Vue, Angular, Svelte
|
|
4
|
-
*
|
|
5
|
-
* @version 1.4.4
|
|
6
|
-
* @package agentic15-claude-zen
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
module.exports = {
|
|
10
|
-
// Use jsdom for DOM testing (React, Vue, Svelte, Angular)
|
|
11
|
-
testEnvironment: 'jsdom',
|
|
12
|
-
|
|
13
|
-
// Transform JS/JSX/TS/TSX files with babel-jest
|
|
14
|
-
transform: {
|
|
15
|
-
'^.+\\.(js|jsx|ts|tsx)$': 'babel-jest',
|
|
16
|
-
},
|
|
17
|
-
|
|
18
|
-
// Support JS, JSX, TS, TSX file extensions
|
|
19
|
-
moduleFileExtensions: ['js', 'jsx', 'ts', 'tsx', 'json'],
|
|
20
|
-
|
|
21
|
-
// Find test files in tests/ directory
|
|
22
|
-
testMatch: [
|
|
23
|
-
'**/tests/**/*.test.{js,jsx,ts,tsx}',
|
|
24
|
-
'**/tests/**/*.spec.{js,jsx,ts,tsx}',
|
|
25
|
-
],
|
|
26
|
-
|
|
27
|
-
// Coverage collection
|
|
28
|
-
collectCoverageFrom: [
|
|
29
|
-
'Agent/src/**/*.{js,jsx,ts,tsx}',
|
|
30
|
-
'!Agent/src/**/*.d.ts',
|
|
31
|
-
'!Agent/src/index.{js,ts}',
|
|
32
|
-
],
|
|
33
|
-
|
|
34
|
-
// Setup files for different frameworks
|
|
35
|
-
setupFilesAfterEnv: ['<rootDir>/jest.setup.js'],
|
|
36
|
-
|
|
37
|
-
// Module name mapper for CSS/asset imports
|
|
38
|
-
moduleNameMapper: {
|
|
39
|
-
'\\.(css|less|scss|sass)$': 'identity-obj-proxy',
|
|
40
|
-
'\\.(jpg|jpeg|png|gif|svg)$': '<rootDir>/__mocks__/fileMock.js',
|
|
41
|
-
},
|
|
42
|
-
|
|
43
|
-
// Ignore patterns
|
|
44
|
-
testPathIgnorePatterns: ['/node_modules/', '/test-site/'],
|
|
45
|
-
|
|
46
|
-
// Verbose output
|
|
47
|
-
verbose: true,
|
|
48
|
-
};
|
package/templates/jest.setup.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Jest Setup File
|
|
3
|
-
* Configures testing environment for UI components
|
|
4
|
-
*
|
|
5
|
-
* @version 1.4.4
|
|
6
|
-
* @package agentic15-claude-zen
|
|
7
|
-
*/
|
|
8
|
-
|
|
9
|
-
// Import jest-dom matchers for better assertions
|
|
10
|
-
import '@testing-library/jest-dom';
|
|
11
|
-
|
|
12
|
-
// Suppress console errors during tests (optional)
|
|
13
|
-
// global.console.error = jest.fn();
|