@use-aistack/cli 0.3.0 → 0.4.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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@use-aistack/cli",
3
- "version": "0.3.0",
4
- "description": "Share and clone AI development configurations",
3
+ "version": "0.4.0",
4
+ "description": "Measure and share your AI stack from your terminal",
5
5
  "type": "module",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -13,7 +13,11 @@
13
13
  "bin": {
14
14
  "aistack": "dist/index.js"
15
15
  },
16
- "files": ["dist", "README.md"],
16
+ "files": [
17
+ "dist",
18
+ "skills",
19
+ "README.md"
20
+ ],
17
21
  "publishConfig": {
18
22
  "access": "public"
19
23
  },
@@ -24,16 +28,18 @@
24
28
  "prepublishOnly": "pnpm build"
25
29
  },
26
30
  "dependencies": {
31
+ "@clack/prompts": "^0.10.0",
27
32
  "commander": "^13.1.0",
33
+ "ignore": "^7.0.0",
28
34
  "open": "^10.1.0",
29
35
  "picocolors": "^1.1.0",
30
- "@clack/prompts": "^0.10.0",
31
- "ignore": "^7.0.0"
36
+ "smol-toml": "^1.6.1",
37
+ "yaml": "^2.9.0"
32
38
  },
33
39
  "devDependencies": {
40
+ "@types/node": "^24",
34
41
  "tsup": "^8.4.0",
35
- "typescript": "^5.7.2",
36
- "@types/node": "^22.10.2"
42
+ "typescript": "^5.7.2"
37
43
  },
38
44
  "engines": {
39
45
  "node": ">=18"
@@ -0,0 +1,48 @@
1
+ ---
2
+ name: aistack-sync
3
+ description: Publish measured Claude Code usage (rolling 30 days) to the user's aistack stack. Use when the user says "sync my stack", "aistack sync", "publish my usage", or asks to update the measured layer of their stack.
4
+ ---
5
+
6
+ # aistack sync
7
+
8
+ Publish the local measured-usage snapshot to the user's aistack stack. The
9
+ `aistack` MCP server does all the work: it scans the transcripts on this
10
+ machine, stages the exact bytes, and gates the send behind a dialog only the
11
+ user can answer. You trigger and display. You never decide.
12
+
13
+ ## Steps
14
+
15
+ 1. Call the `sync_preview` tool on the `aistack` MCP server. No arguments.
16
+ 2. Show the returned text to the user verbatim, in a code block. Do not
17
+ summarize it. Do not omit lines. Do not add numbers of your own.
18
+ 3. If the output says `publish unavailable`, stop and relay the reason.
19
+ 4. If the user asked for a sync, call `sync_publish` with the `preview id`
20
+ from the output. A confirmation dialog appears. The user answers it
21
+ themselves. Wait; the dialog can take minutes.
22
+ 5. Relay the tool result verbatim. "Not published" is a valid outcome, not an
23
+ error to work around.
24
+
25
+ ## Rules
26
+
27
+ - Never call `sync_publish` without a `sync_preview` in the same conversation.
28
+ - Never replace the preview text with your own summary. The preview is the
29
+ review surface the user consents on.
30
+ - A cancel or a timeout is the user's answer. Do not raise the gate again in
31
+ the same turn. Retry only when the user asks.
32
+ - If the `aistack` MCP server is not connected, say so and point at the setup
33
+ step below. Do not publish through any other channel. There is none.
34
+
35
+ ## Setup (one time, done by the user)
36
+
37
+ ```sh
38
+ npx @use-aistack/cli connect claude
39
+ ```
40
+
41
+ That installs both halves: the `aistack` MCP server (user scope) and this
42
+ Skill. Manual alternative:
43
+
44
+ ```sh
45
+ claude mcp add --scope user aistack -- npx -y @use-aistack/cli mcp
46
+ ```
47
+
48
+ The machine must be linked once with `npx @use-aistack/cli login`.