crewkit 0.1.0 → 1.0.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 +142 -1
- package/package.json +1 -1
- package/skill/SKILL.md +38 -2
- package/skill/adapters/copilot.md +239 -0
- package/skill/adapters/cursor.md +215 -0
- package/skill/templates/skills/dev-metrics/SKILL.md +126 -0
- package/skill/templates/skills/impact/SKILL.md +157 -0
- package/skill/templates/skills/retro/SKILL.md +134 -0
- package/skill/templates/skills/review-pr/SKILL.md +39 -5
- package/skill/templates/skills/security-scan/SKILL.md +157 -0
- package/src/add.js +45 -0
- package/src/cli.js +15 -6
- package/src/install.js +4 -1
- package/src/update.js +28 -0
package/src/cli.js
CHANGED
|
@@ -1,16 +1,20 @@
|
|
|
1
1
|
import { install } from './install.js';
|
|
2
|
+
import { update } from './update.js';
|
|
3
|
+
import { add } from './add.js';
|
|
2
4
|
|
|
3
5
|
const HELP = `
|
|
4
6
|
crewkit — Context engineering for AI-assisted development
|
|
5
7
|
|
|
6
8
|
Commands:
|
|
7
|
-
install
|
|
8
|
-
update
|
|
9
|
-
|
|
9
|
+
install Install crewkit skill globally (~/.claude/skills/)
|
|
10
|
+
update Update to latest version (re-run install)
|
|
11
|
+
add <skill> Add an optional skill to the current project
|
|
12
|
+
help Show this message
|
|
10
13
|
|
|
11
14
|
Usage:
|
|
12
|
-
npx crewkit install
|
|
13
|
-
|
|
15
|
+
npx crewkit install # one-time setup
|
|
16
|
+
npx crewkit add retro # add optional skill to project
|
|
17
|
+
/crewkit-setup # run in your IDE to scan & calibrate a project
|
|
14
18
|
`;
|
|
15
19
|
|
|
16
20
|
export function run(args) {
|
|
@@ -18,9 +22,14 @@ export function run(args) {
|
|
|
18
22
|
|
|
19
23
|
switch (command) {
|
|
20
24
|
case 'install':
|
|
21
|
-
case 'update':
|
|
22
25
|
install();
|
|
23
26
|
break;
|
|
27
|
+
case 'update':
|
|
28
|
+
update();
|
|
29
|
+
break;
|
|
30
|
+
case 'add':
|
|
31
|
+
add(args[1]);
|
|
32
|
+
break;
|
|
24
33
|
case 'help':
|
|
25
34
|
case '--help':
|
|
26
35
|
case '-h':
|
package/src/install.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { cpSync, mkdirSync, existsSync, readFileSync } from 'node:fs';
|
|
1
|
+
import { cpSync, mkdirSync, existsSync, readFileSync, writeFileSync } from 'node:fs';
|
|
2
2
|
import { join, dirname } from 'node:path';
|
|
3
3
|
import { homedir } from 'node:os';
|
|
4
4
|
import { fileURLToPath } from 'node:url';
|
|
@@ -25,6 +25,9 @@ export function install() {
|
|
|
25
25
|
// Read version
|
|
26
26
|
const pkg = JSON.parse(readFileSync(join(__dirname, '..', 'package.json'), 'utf8'));
|
|
27
27
|
|
|
28
|
+
// Write version marker
|
|
29
|
+
writeFileSync(join(skillDest, '.version'), pkg.version, 'utf8');
|
|
30
|
+
|
|
28
31
|
console.log(`
|
|
29
32
|
✓ crewkit v${pkg.version} installed
|
|
30
33
|
|
package/src/update.js
ADDED
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { existsSync, readFileSync } from 'node:fs';
|
|
2
|
+
import { join, dirname } from 'node:path';
|
|
3
|
+
import { homedir } from 'node:os';
|
|
4
|
+
import { fileURLToPath } from 'node:url';
|
|
5
|
+
import { install } from './install.js';
|
|
6
|
+
|
|
7
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
8
|
+
const __dirname = dirname(__filename);
|
|
9
|
+
|
|
10
|
+
export function update() {
|
|
11
|
+
const versionFile = join(homedir(), '.claude', 'skills', 'crewkit-setup', '.version');
|
|
12
|
+
const pkg = JSON.parse(readFileSync(join(__dirname, '..', 'package.json'), 'utf8'));
|
|
13
|
+
|
|
14
|
+
const newVersion = pkg.version;
|
|
15
|
+
const currentVersion = existsSync(versionFile)
|
|
16
|
+
? readFileSync(versionFile, 'utf8').trim()
|
|
17
|
+
: 'unknown';
|
|
18
|
+
|
|
19
|
+
if (currentVersion === newVersion) {
|
|
20
|
+
console.log(` Already up to date (v${newVersion})`);
|
|
21
|
+
return;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
install();
|
|
25
|
+
|
|
26
|
+
const fromLabel = currentVersion === 'unknown' ? 'v0.1 (untracked)' : `v${currentVersion}`;
|
|
27
|
+
console.log(` Updated: ${fromLabel} → v${newVersion}`);
|
|
28
|
+
}
|