@headways/cli 0.1.0 → 0.2.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 +77 -0
- package/dist/api-WUIL5TMR.js +0 -0
- package/dist/chunk-QXOLSB3Q.js +0 -0
- package/dist/chunk-VLKLEV4U.js +0 -0
- package/dist/config-GRE3MIQL.js +0 -0
- package/dist/index.js +6 -2
- package/package.json +17 -15
package/README.md
ADDED
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
# @headways/cli
|
|
2
|
+
|
|
3
|
+
The official CLI for [Headways](https://headways.ai) — author skills, sync them to your team, and capture workflows directly from Claude Code.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install -g @headways/cli
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Setup
|
|
12
|
+
|
|
13
|
+
```bash
|
|
14
|
+
headways configure
|
|
15
|
+
# Prompts for your API key (sk_…). Validates and saves org automatically.
|
|
16
|
+
```
|
|
17
|
+
|
|
18
|
+
Options:
|
|
19
|
+
|
|
20
|
+
```bash
|
|
21
|
+
headways configure --token <key> # non-interactive
|
|
22
|
+
headways configure --api-url http://localhost:3001 # local dev
|
|
23
|
+
headways configure status # show saved key + org
|
|
24
|
+
headways configure clear # remove credentials
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## Commands
|
|
28
|
+
|
|
29
|
+
### Skills
|
|
30
|
+
|
|
31
|
+
```bash
|
|
32
|
+
headways skills new # scaffold a new skill interactively
|
|
33
|
+
headways skills new --slug <slug> --headline "<headline>" # non-interactive
|
|
34
|
+
headways skills import <path> # ingest an existing file or directory
|
|
35
|
+
headways skills push <slug> # sync local edits to the skill draft
|
|
36
|
+
headways skills list # list skills in the active org
|
|
37
|
+
headways skills capture # capture a workflow from Claude Code
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
### Sync
|
|
41
|
+
|
|
42
|
+
```bash
|
|
43
|
+
headways sync start # register device + pull updates once
|
|
44
|
+
headways sync start --daemon # poll every 60s for background updates
|
|
45
|
+
headways sync status # show pending skill updates
|
|
46
|
+
headways accept <skill> # install a pending update
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### Other
|
|
50
|
+
|
|
51
|
+
```bash
|
|
52
|
+
headways feedback <skillSlug> # submit feedback on a skill run
|
|
53
|
+
headways org use <slug> # switch active org
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
## Creating a skill from scratch
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
cd ~/my-skills
|
|
60
|
+
headways skills new # creates ./<slug>/ with SKILL.md,
|
|
61
|
+
# headways.yaml, capabilities.yaml,
|
|
62
|
+
# hooks.yaml
|
|
63
|
+
# Edit the skill
|
|
64
|
+
vim <slug>/SKILL.md
|
|
65
|
+
# Push as a draft
|
|
66
|
+
headways skills push <slug>
|
|
67
|
+
# Publish via the web UI when ready
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
Installed skill bundles land in `~/.claude/skills/<slug>/`. Config is stored in `~/.headways/config.json`.
|
|
71
|
+
|
|
72
|
+
## Local development
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
pnpm --filter @headways/cli build
|
|
76
|
+
npm install -g ./packages/cli
|
|
77
|
+
```
|
package/dist/api-WUIL5TMR.js
CHANGED
|
File without changes
|
package/dist/chunk-QXOLSB3Q.js
CHANGED
|
File without changes
|
package/dist/chunk-VLKLEV4U.js
CHANGED
|
File without changes
|
package/dist/config-GRE3MIQL.js
CHANGED
|
File without changes
|
package/dist/index.js
CHANGED
|
@@ -50,7 +50,9 @@ function registerAuthCommands(program2) {
|
|
|
50
50
|
cfg.orgId = me.organization.id;
|
|
51
51
|
}
|
|
52
52
|
writeConfig(cfg);
|
|
53
|
-
console.log(
|
|
53
|
+
console.log(
|
|
54
|
+
me.type === "api_key" && me.organization ? `API key saved. Org: ${me.organization.slug}` : "API key saved."
|
|
55
|
+
);
|
|
54
56
|
} catch {
|
|
55
57
|
console.error("Invalid API key. Not saved. Check the key and try again.");
|
|
56
58
|
process.exit(1);
|
|
@@ -61,7 +63,9 @@ function registerAuthCommands(program2) {
|
|
|
61
63
|
if (!cfg.token) {
|
|
62
64
|
console.log("No API key configured. Run `headways configure`.");
|
|
63
65
|
} else {
|
|
64
|
-
console.log(
|
|
66
|
+
console.log(
|
|
67
|
+
`API key: ${cfg.token.slice(0, 12)}\u2026 | Org: ${cfg.orgSlug ?? "(none set)"} | API: ${cfg.apiUrl ?? "https://api.headways.ai"}`
|
|
68
|
+
);
|
|
65
69
|
}
|
|
66
70
|
});
|
|
67
71
|
configure.command("clear").description("Remove stored API key and org").action(() => {
|
package/package.json
CHANGED
|
@@ -1,39 +1,41 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@headways/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Headways CLI — authoring, sync, and runtime SDK",
|
|
6
|
-
"files": [
|
|
6
|
+
"files": [
|
|
7
|
+
"dist",
|
|
8
|
+
"README.md"
|
|
9
|
+
],
|
|
7
10
|
"bin": {
|
|
8
11
|
"headways": "./dist/index.js"
|
|
9
12
|
},
|
|
10
13
|
"publishConfig": {
|
|
11
14
|
"access": "public"
|
|
12
15
|
},
|
|
13
|
-
"scripts": {
|
|
14
|
-
"build": "tsup",
|
|
15
|
-
"dev": "tsx src/index.ts",
|
|
16
|
-
"test": "vitest run",
|
|
17
|
-
"test:unit": "vitest run",
|
|
18
|
-
"type-check": "tsc -p tsconfig.json --noEmit",
|
|
19
|
-
"prepublishOnly": "pnpm build"
|
|
20
|
-
},
|
|
21
16
|
"dependencies": {
|
|
22
|
-
"@headways/db": "workspace:*",
|
|
23
17
|
"@modelcontextprotocol/sdk": "^1.15.0",
|
|
24
18
|
"chalk": "^5.3.0",
|
|
25
19
|
"commander": "^12.1.0",
|
|
26
20
|
"dotenv": "^16.4.7",
|
|
27
21
|
"node-fetch": "^3.3.2",
|
|
28
22
|
"yaml": "^2.5.1",
|
|
29
|
-
"zod": "^3.25.28"
|
|
23
|
+
"zod": "^3.25.28",
|
|
24
|
+
"@headways/db": "0.0.0"
|
|
30
25
|
},
|
|
31
26
|
"devDependencies": {
|
|
32
|
-
"@headways/config": "workspace:*",
|
|
33
27
|
"@types/node": "^22.16.5",
|
|
34
28
|
"tsup": "^8.5.1",
|
|
35
29
|
"tsx": "^4.21.0",
|
|
36
30
|
"typescript": "^5.8.3",
|
|
37
|
-
"vitest": "^3.2.4"
|
|
31
|
+
"vitest": "^3.2.4",
|
|
32
|
+
"@headways/config": "0.0.0"
|
|
33
|
+
},
|
|
34
|
+
"scripts": {
|
|
35
|
+
"build": "tsup",
|
|
36
|
+
"dev": "tsx src/index.ts",
|
|
37
|
+
"test": "vitest run",
|
|
38
|
+
"test:unit": "vitest run",
|
|
39
|
+
"type-check": "tsc -p tsconfig.json --noEmit"
|
|
38
40
|
}
|
|
39
|
-
}
|
|
41
|
+
}
|