kaizen-agent 1.7.1 → 1.7.2
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/LICENSE +21 -21
- package/README.md +657 -657
- package/agents/kaizen-builder.md +77 -77
- package/agents/kaizen-planner.md +250 -250
- package/agents/kaizen-reviewer.md +127 -127
- package/cli/dashboard.ts +1187 -1187
- package/cli/install.ts +947 -947
- package/cli/publish-gh.sh +27 -27
- package/cli/release.sh +45 -45
- package/cli/settings.ts +415 -415
- package/cli/state.test.ts +197 -197
- package/cli/state.ts +704 -704
- package/cli/web.ts +423 -423
- package/commands/kaizen-abort.md +5 -5
- package/commands/kaizen-approve.md +5 -5
- package/commands/kaizen-auto.md +6 -6
- package/commands/kaizen-backlog.md +5 -5
- package/commands/kaizen-config.md +5 -5
- package/commands/kaizen-full.md +5 -5
- package/commands/kaizen-init.md +5 -5
- package/commands/kaizen-install.md +5 -5
- package/commands/kaizen-lite.md +5 -5
- package/commands/kaizen-plan.md +6 -6
- package/commands/kaizen-reject.md +6 -6
- package/commands/kaizen-review.md +6 -6
- package/commands/kaizen-run.md +5 -5
- package/commands/kaizen-status.md +5 -5
- package/package.json +1 -1
- package/skills/kaizen/README.md +281 -281
- package/skills/kaizen/SKILL.md +440 -440
- package/skills/kaizen/adapters.md +77 -77
- package/skills/kaizen/config.default.yml +167 -167
- package/skills/kaizen/spec-build.md +119 -119
- package/skills/kaizen/spec-main.md +104 -104
- package/skills/kaizen/spec-plan.md +201 -201
- package/skills/kaizen/spec-review.md +121 -121
- package/skills/kaizen/spec.md +153 -153
- package/skills/kaizen-help/SKILL.md +129 -129
- package/web/board.html +520 -513
package/cli/publish-gh.sh
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
#!/bin/sh
|
|
2
|
-
# Publish the same tarball to GitHub Packages, so the repo's "Packages" box lists
|
|
3
|
-
# it. GitHub only accepts names scoped to the repo owner, so the package goes there
|
|
4
|
-
# as @hfadhlullah/kaizen-agent while npm keeps kaizen-agent. Run after `bun publish`.
|
|
5
|
-
set -eu
|
|
6
|
-
cd "$(dirname "$0")/.."
|
|
7
|
-
token="${GITHUB_TOKEN:-$(gh auth token 2>/dev/null || true)}"
|
|
8
|
-
[ -n "$token" ] || { echo "publish-gh: no GitHub token (gh auth login, scope write:packages)"; exit 1; }
|
|
9
|
-
|
|
10
|
-
tmp="$(mktemp -d)"
|
|
11
|
-
trap 'rm -rf "$tmp"' EXIT
|
|
12
|
-
cp package.json "$tmp/package.json.orig"
|
|
13
|
-
bun -e '
|
|
14
|
-
const p = JSON.parse(await Bun.file("package.json").text());
|
|
15
|
-
p.name = "@hfadhlullah/kaizen-agent";
|
|
16
|
-
p.publishConfig = { registry: "https://npm.pkg.github.com" };
|
|
17
|
-
await Bun.write("package.json", JSON.stringify(p, null, 2) + "\n");
|
|
18
|
-
'
|
|
19
|
-
# Bun reads the project's own .npmrc; a temporary one carries the token and never
|
|
20
|
-
# lands in git (it is removed on exit, and .gitignore refuses it besides).
|
|
21
|
-
[ -e .npmrc ] && cp .npmrc "$tmp/npmrc.orig"
|
|
22
|
-
printf '//npm.pkg.github.com/:_authToken=%s\n@hfadhlullah:registry=https://npm.pkg.github.com\n' "$token" > .npmrc
|
|
23
|
-
# The scoped copy must not run postpublish: the tag and release already exist.
|
|
24
|
-
bun publish --ignore-scripts "$@" || status=$?
|
|
25
|
-
cp "$tmp/package.json.orig" package.json
|
|
26
|
-
if [ -e "$tmp/npmrc.orig" ]; then cp "$tmp/npmrc.orig" .npmrc; else rm -f .npmrc; fi
|
|
27
|
-
exit "${status:-0}"
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
# Publish the same tarball to GitHub Packages, so the repo's "Packages" box lists
|
|
3
|
+
# it. GitHub only accepts names scoped to the repo owner, so the package goes there
|
|
4
|
+
# as @hfadhlullah/kaizen-agent while npm keeps kaizen-agent. Run after `bun publish`.
|
|
5
|
+
set -eu
|
|
6
|
+
cd "$(dirname "$0")/.."
|
|
7
|
+
token="${GITHUB_TOKEN:-$(gh auth token 2>/dev/null || true)}"
|
|
8
|
+
[ -n "$token" ] || { echo "publish-gh: no GitHub token (gh auth login, scope write:packages)"; exit 1; }
|
|
9
|
+
|
|
10
|
+
tmp="$(mktemp -d)"
|
|
11
|
+
trap 'rm -rf "$tmp"' EXIT
|
|
12
|
+
cp package.json "$tmp/package.json.orig"
|
|
13
|
+
bun -e '
|
|
14
|
+
const p = JSON.parse(await Bun.file("package.json").text());
|
|
15
|
+
p.name = "@hfadhlullah/kaizen-agent";
|
|
16
|
+
p.publishConfig = { registry: "https://npm.pkg.github.com" };
|
|
17
|
+
await Bun.write("package.json", JSON.stringify(p, null, 2) + "\n");
|
|
18
|
+
'
|
|
19
|
+
# Bun reads the project's own .npmrc; a temporary one carries the token and never
|
|
20
|
+
# lands in git (it is removed on exit, and .gitignore refuses it besides).
|
|
21
|
+
[ -e .npmrc ] && cp .npmrc "$tmp/npmrc.orig"
|
|
22
|
+
printf '//npm.pkg.github.com/:_authToken=%s\n@hfadhlullah:registry=https://npm.pkg.github.com\n' "$token" > .npmrc
|
|
23
|
+
# The scoped copy must not run postpublish: the tag and release already exist.
|
|
24
|
+
bun publish --ignore-scripts "$@" || status=$?
|
|
25
|
+
cp "$tmp/package.json.orig" package.json
|
|
26
|
+
if [ -e "$tmp/npmrc.orig" ]; then cp "$tmp/npmrc.orig" .npmrc; else rm -f .npmrc; fi
|
|
27
|
+
exit "${status:-0}"
|
package/cli/release.sh
CHANGED
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
#!/bin/sh
|
|
2
|
-
# Runs after `bun publish`: tag the published version and open a GitHub release
|
|
3
|
-
# for it, so a version can never exist on npm with nothing to read on GitHub.
|
|
4
|
-
#
|
|
5
|
-
# Never fails the publish. The package is already public by the time this runs;
|
|
6
|
-
# exiting non-zero here would report a failure that did not happen.
|
|
7
|
-
set -u
|
|
8
|
-
v="${npm_package_version:-$(bun -p "require('./package.json').version" 2>/dev/null)}"
|
|
9
|
-
[ -n "$v" ] || { echo "release: no version, skipping"; exit 0; }
|
|
10
|
-
tag="v$v"
|
|
11
|
-
|
|
12
|
-
git rev-parse --git-dir >/dev/null 2>&1 || { echo "release: not a git checkout, skipping"; exit 0; }
|
|
13
|
-
|
|
14
|
-
if git rev-parse "$tag" >/dev/null 2>&1; then
|
|
15
|
-
echo "release: $tag already tagged"
|
|
16
|
-
else
|
|
17
|
-
git tag -a "$tag" -m "kaizen-agent $tag" || { echo "release: could not tag"; exit 0; }
|
|
18
|
-
git push origin "$tag" >/dev/null 2>&1 || echo "release: tag made but not pushed"
|
|
19
|
-
fi
|
|
20
|
-
|
|
21
|
-
command -v gh >/dev/null 2>&1 || { echo "release: gh not installed — tag pushed, write the release by hand"; exit 0; }
|
|
22
|
-
gh auth status >/dev/null 2>&1 || { echo "release: gh not logged in — tag pushed, write the release by hand"; exit 0; }
|
|
23
|
-
|
|
24
|
-
if gh release view "$tag" >/dev/null 2>&1; then
|
|
25
|
-
echo "release: $tag already released"
|
|
26
|
-
exit 0
|
|
27
|
-
fi
|
|
28
|
-
|
|
29
|
-
# --generate-notes only lists pull requests, and this repo merges none, so the
|
|
30
|
-
# notes are built here: the title from the release commit's subject, the body from
|
|
31
|
-
# every commit since the previous tag with its message, oldest first.
|
|
32
|
-
prev="$(git describe --tags --abbrev=0 "$tag^" 2>/dev/null || true)"
|
|
33
|
-
subject="$(git log -1 --format=%s "$tag" | sed -n 's/^Release [0-9.]*: //p')"
|
|
34
|
-
title="$tag${subject:+: $subject}"
|
|
35
|
-
notes="$(mktemp)"
|
|
36
|
-
git log --reverse --format='### %s%n%n%b' ${prev:+"$prev.."}"$tag" \
|
|
37
|
-
| grep -vE '^(Co-Authored-By|Claude-Session):' \
|
|
38
|
-
| grep -vE '^### Release [0-9.]+:' \
|
|
39
|
-
| cat -s > "$notes"
|
|
40
|
-
[ -n "$prev" ] && printf '\n**Full Changelog**: https://github.com/hfadhlullah/kaizen/compare/%s...%s\n' "$prev" "$tag" >> "$notes"
|
|
41
|
-
gh release create "$tag" --title "$title" --notes-file "$notes" >/dev/null 2>&1 \
|
|
42
|
-
&& echo "release: published $tag https://github.com/hfadhlullah/kaizen/releases/tag/$tag" \
|
|
43
|
-
|| echo "release: tag pushed, release not created"
|
|
44
|
-
rm -f "$notes"
|
|
45
|
-
exit 0
|
|
1
|
+
#!/bin/sh
|
|
2
|
+
# Runs after `bun publish`: tag the published version and open a GitHub release
|
|
3
|
+
# for it, so a version can never exist on npm with nothing to read on GitHub.
|
|
4
|
+
#
|
|
5
|
+
# Never fails the publish. The package is already public by the time this runs;
|
|
6
|
+
# exiting non-zero here would report a failure that did not happen.
|
|
7
|
+
set -u
|
|
8
|
+
v="${npm_package_version:-$(bun -p "require('./package.json').version" 2>/dev/null)}"
|
|
9
|
+
[ -n "$v" ] || { echo "release: no version, skipping"; exit 0; }
|
|
10
|
+
tag="v$v"
|
|
11
|
+
|
|
12
|
+
git rev-parse --git-dir >/dev/null 2>&1 || { echo "release: not a git checkout, skipping"; exit 0; }
|
|
13
|
+
|
|
14
|
+
if git rev-parse "$tag" >/dev/null 2>&1; then
|
|
15
|
+
echo "release: $tag already tagged"
|
|
16
|
+
else
|
|
17
|
+
git tag -a "$tag" -m "kaizen-agent $tag" || { echo "release: could not tag"; exit 0; }
|
|
18
|
+
git push origin "$tag" >/dev/null 2>&1 || echo "release: tag made but not pushed"
|
|
19
|
+
fi
|
|
20
|
+
|
|
21
|
+
command -v gh >/dev/null 2>&1 || { echo "release: gh not installed — tag pushed, write the release by hand"; exit 0; }
|
|
22
|
+
gh auth status >/dev/null 2>&1 || { echo "release: gh not logged in — tag pushed, write the release by hand"; exit 0; }
|
|
23
|
+
|
|
24
|
+
if gh release view "$tag" >/dev/null 2>&1; then
|
|
25
|
+
echo "release: $tag already released"
|
|
26
|
+
exit 0
|
|
27
|
+
fi
|
|
28
|
+
|
|
29
|
+
# --generate-notes only lists pull requests, and this repo merges none, so the
|
|
30
|
+
# notes are built here: the title from the release commit's subject, the body from
|
|
31
|
+
# every commit since the previous tag with its message, oldest first.
|
|
32
|
+
prev="$(git describe --tags --abbrev=0 "$tag^" 2>/dev/null || true)"
|
|
33
|
+
subject="$(git log -1 --format=%s "$tag" | sed -n 's/^Release [0-9.]*: //p')"
|
|
34
|
+
title="$tag${subject:+: $subject}"
|
|
35
|
+
notes="$(mktemp)"
|
|
36
|
+
git log --reverse --format='### %s%n%n%b' ${prev:+"$prev.."}"$tag" \
|
|
37
|
+
| grep -vE '^(Co-Authored-By|Claude-Session):' \
|
|
38
|
+
| grep -vE '^### Release [0-9.]+:' \
|
|
39
|
+
| cat -s > "$notes"
|
|
40
|
+
[ -n "$prev" ] && printf '\n**Full Changelog**: https://github.com/hfadhlullah/kaizen/compare/%s...%s\n' "$prev" "$tag" >> "$notes"
|
|
41
|
+
gh release create "$tag" --title "$title" --notes-file "$notes" >/dev/null 2>&1 \
|
|
42
|
+
&& echo "release: published $tag https://github.com/hfadhlullah/kaizen/releases/tag/$tag" \
|
|
43
|
+
|| echo "release: tag pushed, release not created"
|
|
44
|
+
rm -f "$notes"
|
|
45
|
+
exit 0
|