tracerkit 1.5.0 → 1.6.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/dist/bin.js CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { a as e, n as t, r as n, t as r } from "./uninstall-CtKwA0V6.js";
2
+ import { n as e, o as t, r as n, t as r } from "./uninstall-Dri3LFXP.js";
3
3
  import { existsSync as i, mkdirSync as a, readFileSync as o, rmSync as s, unlinkSync as c, writeFileSync as l } from "node:fs";
4
4
  import { dirname as u, join as d, resolve as f } from "node:path";
5
5
  import { fileURLToPath as p } from "node:url";
@@ -19,8 +19,8 @@ function _(e, t, n) {
19
19
  }
20
20
  //#endregion
21
21
  //#region src/commands/archive.ts
22
- function v(t, n) {
23
- let r = e(t), u = d(t, r.paths.prds, `${n}.md`), f = d(t, r.paths.plans, `${n}.md`), p = d(t, r.paths.archives, n), m = i(u);
22
+ function v(e, n) {
23
+ let r = t(e), u = d(e, r.paths.prds, `${n}.md`), f = d(e, r.paths.plans, `${n}.md`), p = d(e, r.paths.archives, n), m = i(u);
24
24
  if (!i(f)) throw Error(`Plan "${n}" not found at ${f}`);
25
25
  if (i(p)) throw Error(`Archive "${n}" already exists at ${p}`);
26
26
  a(p, { recursive: !0 });
@@ -60,8 +60,8 @@ function S(e) {
60
60
  }
61
61
  //#endregion
62
62
  //#region src/commands/progress.ts
63
- function C(t, n) {
64
- let r = d(t, e(t).paths.plans, `${n}.md`);
63
+ function C(e, n) {
64
+ let r = d(e, t(e).paths.plans, `${n}.md`);
65
65
  if (!i(r)) throw Error(`Plan "${n}" not found at ${r}`);
66
66
  let { phases: a } = S(o(r, "utf8"));
67
67
  if (a.length === 0) return ["No phases found in plan.", "Total: 0/0"];
@@ -106,14 +106,14 @@ function D(e, t) {
106
106
  return [`Error: ${e instanceof Error ? e.message : String(e)}`];
107
107
  }
108
108
  }
109
- function O(e) {
110
- if (e.includes("--help") || e.includes("-h")) return T;
111
- if (e.includes("--version") || e.includes("-v")) return [`tracerkit/${w}`];
112
- let i = e[0], a = e.slice(1);
109
+ function O(t) {
110
+ if (t.includes("--help") || t.includes("-h")) return T;
111
+ if (t.includes("--version") || t.includes("-v")) return [`tracerkit/${w}`];
112
+ let i = t[0], a = t.slice(1);
113
113
  switch (i) {
114
114
  case "init": return n(E(a));
115
115
  case "update": {
116
- let e = a.includes("--force"), n = t(E(a.filter((e) => e !== "--force")), { force: e });
116
+ let t = a.includes("--force"), n = e(E(a.filter((e) => e !== "--force")), { force: t });
117
117
  return n.push("", "Updated to the latest TracerKit."), n.push("If using Claude Code, restart your session to load changes."), n;
118
118
  }
119
119
  case "uninstall": return r(E(a));
package/dist/index.js CHANGED
@@ -1,2 +1,2 @@
1
- import { i as e, n as t, r as n, t as r } from "./uninstall-CtKwA0V6.js";
2
- export { e as SKILL_NAMES, n as init, r as uninstall, t as update };
1
+ import { a as e, i as t, n, r, t as i } from "./uninstall-Dri3LFXP.js";
2
+ export { t as DEPRECATED_SKILLS, e as SKILL_NAMES, r as init, i as uninstall, n as update };
@@ -24,43 +24,41 @@ function d(t) {
24
24
  archives: typeof o.archives == "string" ? o.archives : u.archives
25
25
  } };
26
26
  }
27
- //#endregion
28
- //#region src/templates.ts
29
27
  var f = [
30
28
  "tk:prd",
31
29
  "tk:plan",
32
30
  "tk:check"
33
- ], p = s(o(l(import.meta.url)), "..", "templates");
34
- function m(e, t = "") {
31
+ ], p = ["tk:verify"], m = s(o(l(import.meta.url)), "..", "templates");
32
+ function h(e, t = "") {
35
33
  let n = r(e, { withFileTypes: !0 }), i = [];
36
34
  for (let r of n) {
37
35
  let n = t ? `${t}/${r.name}` : r.name;
38
- r.isDirectory() ? i.push(...m(s(e, r.name), n)) : i.push(n);
36
+ r.isDirectory() ? i.push(...h(s(e, r.name), n)) : i.push(n);
39
37
  }
40
38
  return i.sort();
41
39
  }
42
- function h(e, t) {
40
+ function g(e, t) {
43
41
  return e.replaceAll("{{paths.prds}}", t.paths.prds).replaceAll("{{paths.plans}}", t.paths.plans).replaceAll("{{paths.archives}}", t.paths.archives);
44
42
  }
45
- function g(e, r, i) {
46
- let c = i ?? m(p);
43
+ function _(e, r, i) {
44
+ let c = i ?? h(m);
47
45
  for (let i of c) {
48
- let c = s(p, i), l = s(e, i);
49
- t(o(l), { recursive: !0 }), a(l, h(n(c, "utf8"), r));
46
+ let c = s(m, i), l = s(e, i);
47
+ t(o(l), { recursive: !0 }), a(l, g(n(c, "utf8"), r));
50
48
  }
51
49
  return { copied: c };
52
50
  }
53
- function _(e) {
51
+ function v(e) {
54
52
  return c("sha256").update(e).digest("hex");
55
53
  }
56
- function v(t, r) {
57
- let i = m(p), a = [], o = [], c = [];
54
+ function y(t, r) {
55
+ let i = h(m), a = [], o = [], c = [];
58
56
  for (let l of i) {
59
57
  let i = s(t, l);
60
58
  if (!e(i)) c.push(l);
61
59
  else {
62
- let e = h(n(s(p, l), "utf8"), r);
63
- _(Buffer.from(e)) === _(n(i)) ? a.push(l) : o.push(l);
60
+ let e = g(n(s(m, l), "utf8"), r);
61
+ v(Buffer.from(e)) === v(n(i)) ? a.push(l) : o.push(l);
64
62
  }
65
63
  }
66
64
  return {
@@ -71,35 +69,43 @@ function v(t, r) {
71
69
  }
72
70
  //#endregion
73
71
  //#region src/commands/init.ts
74
- function y(t) {
72
+ function b(t) {
75
73
  for (let n of f) if (e(s(t, ".claude", "skills", n))) throw Error(`.claude/skills/${n}/ already exists — aborting`);
76
- let { copied: n } = g(t, d(t));
74
+ let { copied: n } = _(t, d(t));
77
75
  return n.map((e) => `✓ ${e}`);
78
76
  }
79
77
  //#endregion
80
78
  //#region src/commands/update.ts
81
- function b(t, n) {
79
+ function x(t, n) {
82
80
  if (!f.some((n) => e(s(t, ".claude", "skills", n)))) throw Error("TracerKit not initialized — run `tracerkit init` first");
83
- let r = d(t), { unchanged: i, modified: a, missing: o } = v(t, r), c = [], l = n?.force ?? !1, u = [
84
- ...i,
85
- ...o,
86
- ...l ? a : []
81
+ let r = d(t), { unchanged: a, modified: o, missing: c } = y(t, r), l = [];
82
+ for (let n of p) {
83
+ let r = s(t, ".claude", "skills", n);
84
+ e(r) && (i(r, {
85
+ recursive: !0,
86
+ force: !0
87
+ }), l.push(`✗ .claude/skills/${n}/ removed (deprecated)`));
88
+ }
89
+ let u = n?.force ?? !1, m = [
90
+ ...a,
91
+ ...c,
92
+ ...u ? o : []
87
93
  ];
88
- if (u.length > 0) {
89
- g(t, r, u);
90
- for (let e of i) c.push(`✓ ${e}`);
91
- for (let e of o) c.push(`✓ ${e} (added)`);
92
- if (l) for (let e of a) c.push(`✓ ${e} (replaced)`);
94
+ if (m.length > 0) {
95
+ _(t, r, m);
96
+ for (let e of a) l.push(`✓ ${e}`);
97
+ for (let e of c) l.push(`✓ ${e} (added)`);
98
+ if (u) for (let e of o) l.push(`✓ ${e} (replaced)`);
93
99
  }
94
- if (!l && a.length > 0) {
95
- for (let e of a) c.push(`⚠ ${e} (skipped — modified)`);
96
- c.push("", "Run `tracerkit update --force` to replace modified files with latest versions.");
100
+ if (!u && o.length > 0) {
101
+ for (let e of o) l.push(`⚠ ${e} (skipped — modified)`);
102
+ l.push("", "Run `tracerkit update --force` to replace modified files with latest versions.");
97
103
  }
98
- return c;
104
+ return l;
99
105
  }
100
106
  //#endregion
101
107
  //#region src/commands/uninstall.ts
102
- function x(t) {
108
+ function S(t) {
103
109
  if (!f.some((n) => e(s(t, ".claude", "skills", n)))) throw Error("TracerKit not initialized — nothing to uninstall");
104
110
  let n = [];
105
111
  for (let r of f) {
@@ -112,4 +118,4 @@ function x(t) {
112
118
  return n;
113
119
  }
114
120
  //#endregion
115
- export { d as a, f as i, b as n, y as r, x as t };
121
+ export { f as a, p as i, x as n, d as o, b as r, S as t };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tracerkit",
3
- "version": "1.5.0",
3
+ "version": "1.6.0",
4
4
  "description": "Spec-driven workflow for Claude Code: replace ad-hoc prompts with PRD → plan → verify.",
5
5
  "license": "MIT",
6
6
  "author": {