create-anpunkit 2.1.0 → 2.3.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.
Files changed (68) hide show
  1. package/bin/cli.js +2 -2
  2. package/package.json +2 -3
  3. package/template/.claude/agents/debugger.md +1 -1
  4. package/template/.claude/agents/e2e-runner.md +56 -29
  5. package/template/.claude/agents/implementer.md +14 -8
  6. package/template/.claude/agents/infra-provisioner.md +53 -59
  7. package/template/.claude/agents/planner.md +99 -30
  8. package/template/.claude/agents/researcher.md +16 -1
  9. package/template/.claude/agents/spec-author.md +126 -0
  10. package/template/.claude/agents/synthesizer.md +1 -1
  11. package/template/.claude/agents/test-author.md +81 -63
  12. package/template/.claude/anpunkit-manifest.json +66 -107
  13. package/template/.claude/commands/infra.md +7 -3
  14. package/template/.claude/commands/log-decision.md +1 -1
  15. package/template/.claude/commands/log-issue.md +1 -1
  16. package/template/.claude/commands/overview.md +55 -13
  17. package/template/.claude/commands/phase.md +153 -81
  18. package/template/.claude/commands/quick.md +1 -1
  19. package/template/.claude/commands/replan.md +1 -1
  20. package/template/.claude/commands/store-wisdom.md +1 -1
  21. package/template/.claude/commands/synthesize.md +1 -1
  22. package/template/.claude/commands/unstuck.md +1 -1
  23. package/template/.claude/hooks/session-start.sh +5 -11
  24. package/template/.claude/ref/compression.md +56 -0
  25. package/template/.claude/skills/karpathy-guidelines/SKILL.md +1 -1
  26. package/template/.gitattributes +1 -0
  27. package/template/AGENTS.md +264 -130
  28. package/template/CLAUDE.md +5 -9
  29. package/template/README.md +116 -136
  30. package/template/commands.src/infra.md +7 -3
  31. package/template/commands.src/log-decision.md +1 -1
  32. package/template/commands.src/log-issue.md +1 -1
  33. package/template/commands.src/overview.md +55 -13
  34. package/template/commands.src/phase.md +153 -81
  35. package/template/commands.src/quick.md +1 -1
  36. package/template/commands.src/replan.md +1 -1
  37. package/template/commands.src/store-wisdom.md +1 -1
  38. package/template/commands.src/synthesize.md +1 -1
  39. package/template/commands.src/unstuck.md +1 -1
  40. package/template/docs/DESIGN_LOG.md +414 -9
  41. package/template/knowledge/azure.md +161 -0
  42. package/template/knowledge/webapp.md +265 -0
  43. package/template/scripts/spec-conformance.sh +93 -0
  44. package/template/scripts/spec-staleness.sh +115 -0
  45. package/template/setup.sh +30 -111
  46. package/template/tests/helpers/spec-assert.py +162 -0
  47. package/template/tests/helpers/spec-assert.ts +158 -0
  48. package/template/.claude/hooks/cursor-session-start.sh +0 -17
  49. package/template/.claude/skills/caveman/SKILL.md +0 -39
  50. package/template/.cursor/commands/infra.md +0 -82
  51. package/template/.cursor/commands/log-decision.md +0 -29
  52. package/template/.cursor/commands/log-issue.md +0 -23
  53. package/template/.cursor/commands/overview.md +0 -145
  54. package/template/.cursor/commands/phase.md +0 -249
  55. package/template/.cursor/commands/quick.md +0 -25
  56. package/template/.cursor/commands/replan.md +0 -73
  57. package/template/.cursor/commands/store-wisdom.md +0 -191
  58. package/template/.cursor/commands/synthesize.md +0 -22
  59. package/template/.cursor/commands/unstuck.md +0 -36
  60. package/template/.cursor/hooks.json +0 -14
  61. package/template/.cursor/rules/anpunkit.md +0 -11
  62. package/template/anpunkit.png +0 -0
  63. package/template/docker-compose.test.yml +0 -34
  64. package/template/e2e/global-setup.ts +0 -57
  65. package/template/index.html +0 -340
  66. package/template/playwright.config.ts +0 -28
  67. package/template/scripts/auth-setup.sh +0 -51
  68. package/template/scripts/e2e-stack.sh +0 -65
@@ -1,51 +0,0 @@
1
- #!/usr/bin/env bash
2
- # scripts/auth-setup.sh — verify Azure CLI session is ready.
3
- set -euo pipefail
4
- cd "${CLAUDE_PROJECT_DIR:-.}"
5
-
6
- RED='\033[0;31m'; GREEN='\033[0;32m'; YELLOW='\033[1;33m'; NC='\033[0m'
7
- ok() { printf "${GREEN} OK${NC} %s\n" "$1"; }
8
- warn() { printf "${YELLOW} WARN${NC} %s\n" "$1"; }
9
- fail() { printf "${RED} FAIL${NC} %s\n" "$1"; }
10
-
11
- echo ""
12
- echo "=== Azure session check ==="
13
- echo ""
14
-
15
- if ! command -v az >/dev/null 2>&1; then
16
- fail "az CLI not found. Install from https://learn.microsoft.com/cli/azure/install-azure-cli"
17
- exit 1
18
- fi
19
- AZ_VER=$(az version --query '"azure-cli"' -o tsv 2>/dev/null || echo "unknown")
20
- ok "az CLI present (version: ${AZ_VER})"
21
-
22
- ACCOUNT_JSON=$(az account show 2>/dev/null || true)
23
- if [ -z "$ACCOUNT_JSON" ]; then
24
- warn "Not logged in. Running az login..."
25
- az login
26
- ACCOUNT_JSON=$(az account show 2>/dev/null || true)
27
- fi
28
-
29
- if [ -z "$ACCOUNT_JSON" ]; then
30
- fail "az login failed or was cancelled."
31
- exit 1
32
- fi
33
-
34
- SUB_NAME=$(echo "$ACCOUNT_JSON" | python3 -c "import sys,json; print(json.load(sys.stdin)['name'])" 2>/dev/null || echo "unknown")
35
- SUB_ID=$(echo "$ACCOUNT_JSON" | python3 -c "import sys,json; print(json.load(sys.stdin)['id'])" 2>/dev/null || echo "unknown")
36
- ok "Logged in — subscription: ${SUB_NAME} (${SUB_ID})"
37
-
38
- # Token freshness check
39
- TOKEN_EXP=$(az account get-access-token --query expiresOn -o tsv 2>/dev/null || echo "")
40
- if [ -n "$TOKEN_EXP" ]; then
41
- ok "Token valid until: ${TOKEN_EXP}"
42
- else
43
- warn "Could not determine token expiry — may need re-login during session."
44
- fi
45
-
46
- # Mark auth done for this session (suppresses SessionStart hook nudge)
47
- PROJECT_HASH=$(echo "$PWD" | md5sum 2>/dev/null | cut -c1-8 || echo "anpunkit")
48
- touch "/tmp/anpunkit-auth-${USER:-unknown}-${PROJECT_HASH}"
49
-
50
- echo ""
51
- echo "Azure session ready. You can now run /infra or Azure-dependent phases."
@@ -1,65 +0,0 @@
1
- #!/usr/bin/env bash
2
- # scripts/e2e-stack.sh — E2E test stack lifecycle.
3
- set -euo pipefail
4
- cd "$(dirname "$0")/.."
5
-
6
- CMD="${1:-}"
7
- COMPOSE="docker-compose.test.yml"
8
- ENVFILE=".env.test"
9
-
10
- [ -f "$ENVFILE" ] || { echo "missing $ENVFILE — run /infra to generate it"; exit 1; }
11
- set -a; . "./$ENVFILE"; set +a
12
-
13
- if [ "${E2E_STACK_EXTERNAL:-}" = "1" ]; then
14
- echo "[e2e-stack] E2E_STACK_EXTERNAL=1 — targeting deployed Azure app at ${E2E_BASE_URL:-<unset>}"
15
- case "$CMD" in
16
- up)
17
- echo "[e2e-stack] Verifying Azure app is reachable..."
18
- for i in $(seq 1 10); do
19
- if curl -fs "${E2E_BASE_URL:-http://localhost:8080}/health" >/dev/null 2>&1 \
20
- || curl -fs "${E2E_BASE_URL:-http://localhost:8080}" >/dev/null 2>&1; then
21
- echo "[e2e-stack] Azure app reachable."
22
- exit 0
23
- fi
24
- sleep 3
25
- done
26
- echo "[e2e-stack] WARNING: Azure app not reachable. Classify as AZURE UNAVAILABLE."
27
- exit 1
28
- ;;
29
- down)
30
- echo "[e2e-stack] External mode — nothing to stop."
31
- exit 0
32
- ;;
33
- *)
34
- echo "usage: e2e-stack.sh up|down"
35
- exit 1
36
- ;;
37
- esac
38
- fi
39
-
40
- if docker compose version >/dev/null 2>&1; then DC="docker compose"; else DC="docker-compose"; fi
41
-
42
- case "$CMD" in
43
- up)
44
- echo "[e2e-stack] building + starting local app containers..."
45
- $DC -f "$COMPOSE" --env-file "$ENVFILE" up -d --build
46
- for i in $(seq 1 30); do
47
- if curl -fs "${E2E_BASE_URL:-http://localhost:8080}" >/dev/null 2>&1; then
48
- echo "[e2e-stack] up."
49
- exit 0
50
- fi
51
- sleep 3
52
- done
53
- echo "[e2e-stack] ERROR: app did not become healthy — STACK NOT READY"
54
- exit 1
55
- ;;
56
- down)
57
- echo "[e2e-stack] stopping local containers..."
58
- $DC -f "$COMPOSE" --env-file "$ENVFILE" down
59
- echo "[e2e-stack] down."
60
- ;;
61
- *)
62
- echo "usage: e2e-stack.sh up|down"
63
- exit 1
64
- ;;
65
- esac