axel-setup 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.
Files changed (117) hide show
  1. package/CHANGELOG.md +218 -0
  2. package/CONTRIBUTING.md +58 -0
  3. package/LICENSE +21 -0
  4. package/README.md +518 -0
  5. package/agents/api-design.md +51 -0
  6. package/agents/bughunter.md +136 -0
  7. package/agents/changelog.md +89 -0
  8. package/agents/cleanup.md +126 -0
  9. package/agents/compare-branch.md +35 -0
  10. package/agents/cross-repo.md +97 -0
  11. package/agents/db-check.md +14 -0
  12. package/agents/debug.md +47 -0
  13. package/agents/deploy-check.md +100 -0
  14. package/agents/draft-message.md +19 -0
  15. package/agents/excelsior-coordinator.md +75 -0
  16. package/agents/excelsior-verifier.md +94 -0
  17. package/agents/feature.md +48 -0
  18. package/agents/harness-optimizer.md +40 -0
  19. package/agents/incident.md +48 -0
  20. package/agents/linear-task.md +18 -0
  21. package/agents/onboard.md +24 -0
  22. package/agents/perf.md +44 -0
  23. package/agents/production-validator.md +96 -0
  24. package/agents/review.md +113 -0
  25. package/agents/security-check.md +29 -0
  26. package/agents/sprint-summary.md +15 -0
  27. package/agents/tdd-mainder.md +178 -0
  28. package/agents/test-gen.md +39 -0
  29. package/axel-manifest.json +129 -0
  30. package/bin/axel-setup.js +597 -0
  31. package/bootstrap.sh +1087 -0
  32. package/commands/create-pr.md +13 -0
  33. package/commands/daily.md +182 -0
  34. package/commands/deslop.md +13 -0
  35. package/commands/draft-message.md +23 -0
  36. package/commands/eod-review.md +154 -0
  37. package/commands/execute-prp.md +37 -0
  38. package/commands/generate-prp.md +75 -0
  39. package/commands/multi-repo-feature.md +60 -0
  40. package/commands/roadmap.md +31 -0
  41. package/commands/sprint-status.md +486 -0
  42. package/commands/style.md +68 -0
  43. package/commands/visualize.md +17 -0
  44. package/docs/roadmap/multi-runtime.md +73 -0
  45. package/docs/superpowers/plans/2026-06-12-setup-hardening-roadmap.md +61 -0
  46. package/hooks/desktop-notify.sh +26 -0
  47. package/hooks/enforce-agent-model.jq +14 -0
  48. package/hooks/gsd-context-monitor.js +156 -0
  49. package/hooks/linear-lifecycle-sync.sh +112 -0
  50. package/hooks/memory-dedup.sh +122 -0
  51. package/hooks/memory-extractor.sh +218 -0
  52. package/hooks/post-commit-memory-trigger.sh +16 -0
  53. package/hooks/post-commit-verify.sh +41 -0
  54. package/hooks/post-edit-lint.sh +43 -0
  55. package/hooks/precompact-save-context.sh +124 -0
  56. package/hooks/priority-map-staleness.sh +29 -0
  57. package/hooks/proactive-resolver.sh +104 -0
  58. package/hooks/session-auto-title.sh +165 -0
  59. package/hooks/session-checkpoint.sh +97 -0
  60. package/hooks/session-cost-log.sh +77 -0
  61. package/hooks/session-log-action.sh +36 -0
  62. package/hooks/session-log-prompt.sh +25 -0
  63. package/hooks/session-restore.sh +45 -0
  64. package/hooks/session-save.sh +81 -0
  65. package/hooks/session-summarize.sh +154 -0
  66. package/hooks/validate-commit-format.sh +38 -0
  67. package/hooks/weekly-priority-map-review.sh +143 -0
  68. package/install.sh +46 -0
  69. package/package.json +67 -0
  70. package/scripts/ci/bootstrap-dry-run.sh +40 -0
  71. package/scripts/ci/check.sh +65 -0
  72. package/scripts/posthog-snapshot-loader.sh +112 -0
  73. package/skills/context-budget/SKILL.md +86 -0
  74. package/skills/memory-review/SKILL.md +100 -0
  75. package/skills/model-routing/SKILL.md +70 -0
  76. package/skills/posthog-weekly/SKILL.md +271 -0
  77. package/skills/ui-ux-pro-max/SKILL.md +377 -0
  78. package/skills/ui-ux-pro-max/data/charts.csv +26 -0
  79. package/skills/ui-ux-pro-max/data/colors.csv +97 -0
  80. package/skills/ui-ux-pro-max/data/icons.csv +101 -0
  81. package/skills/ui-ux-pro-max/data/landing.csv +31 -0
  82. package/skills/ui-ux-pro-max/data/products.csv +97 -0
  83. package/skills/ui-ux-pro-max/data/react-performance.csv +45 -0
  84. package/skills/ui-ux-pro-max/data/stacks/astro.csv +54 -0
  85. package/skills/ui-ux-pro-max/data/stacks/flutter.csv +53 -0
  86. package/skills/ui-ux-pro-max/data/stacks/html-tailwind.csv +56 -0
  87. package/skills/ui-ux-pro-max/data/stacks/jetpack-compose.csv +53 -0
  88. package/skills/ui-ux-pro-max/data/stacks/nextjs.csv +53 -0
  89. package/skills/ui-ux-pro-max/data/stacks/nuxt-ui.csv +51 -0
  90. package/skills/ui-ux-pro-max/data/stacks/nuxtjs.csv +59 -0
  91. package/skills/ui-ux-pro-max/data/stacks/react-native.csv +52 -0
  92. package/skills/ui-ux-pro-max/data/stacks/react.csv +54 -0
  93. package/skills/ui-ux-pro-max/data/stacks/shadcn.csv +61 -0
  94. package/skills/ui-ux-pro-max/data/stacks/svelte.csv +54 -0
  95. package/skills/ui-ux-pro-max/data/stacks/swiftui.csv +51 -0
  96. package/skills/ui-ux-pro-max/data/stacks/vue.csv +50 -0
  97. package/skills/ui-ux-pro-max/data/styles.csv +68 -0
  98. package/skills/ui-ux-pro-max/data/typography.csv +58 -0
  99. package/skills/ui-ux-pro-max/data/ui-reasoning.csv +101 -0
  100. package/skills/ui-ux-pro-max/data/ux-guidelines.csv +100 -0
  101. package/skills/ui-ux-pro-max/data/web-interface.csv +31 -0
  102. package/skills/ui-ux-pro-max/scripts/core.py +253 -0
  103. package/skills/ui-ux-pro-max/scripts/design_system.py +1067 -0
  104. package/skills/ui-ux-pro-max/scripts/search.py +114 -0
  105. package/templates/AGENTS.runtime.md +17 -0
  106. package/templates/CLAUDE.md +252 -0
  107. package/templates/claude-monitor.plist +35 -0
  108. package/templates/keybindings.json +13 -0
  109. package/templates/merge-settings.jq +53 -0
  110. package/templates/review-upgrades.md +44 -0
  111. package/templates/settings.json +255 -0
  112. package/templates/statusline-command.sh +182 -0
  113. package/tests/fixtures/hooks/events.json +32 -0
  114. package/tools/session-costs-view.sh +128 -0
  115. package/tools/session-dashboard-gen.sh +369 -0
  116. package/tools/session-live.sh +173 -0
  117. package/tools/session-server.js +441 -0
@@ -0,0 +1,178 @@
1
+ ---
2
+ name: tdd
3
+ description: Test-Driven Development specialist for Rails + Next.js stacks — RSpec (Rails) and Jest/Vitest (Next.js). London school approach: write failing test first, implement minimum to pass, refactor.
4
+ tools: ["Bash", "Read", "Write", "Edit", "Grep", "Glob"]
5
+ ---
6
+
7
+ # TDD Specialist — Rails + Next.js
8
+
9
+ You practice Test-Driven Development (London School / mockist approach) adapted for Rails + Next.js stacks.
10
+
11
+ ## Core Principle
12
+ **Red → Green → Refactor. Always.**
13
+ Never write implementation before a failing test. Never close a task without specs covering happy path + edge cases + error cases.
14
+
15
+ ## Rails / RSpec (main-api)
16
+
17
+ ### Test Structure
18
+ ```ruby
19
+ # spec/services/namespace/action_spec.rb
20
+ RSpec.describe Namespace::Action do
21
+ subject(:service) { described_class.new(params) }
22
+
23
+ describe "#call" do
24
+ context "when [happy path]" do
25
+ it "returns expected result" do
26
+ result = service.call
27
+ expect(result).to be_success
28
+ expect(result.value).to eq(expected)
29
+ end
30
+ end
31
+
32
+ context "when [edge case]" do
33
+ it "handles gracefully" do
34
+ # ...
35
+ end
36
+ end
37
+
38
+ context "when [error case]" do
39
+ it "returns failure with error" do
40
+ result = service.call
41
+ expect(result).to be_failure
42
+ expect(result.error).to eq(:expected_error)
43
+ end
44
+ end
45
+ end
46
+ end
47
+ ```
48
+
49
+ ### Request Specs (API endpoints)
50
+ ```ruby
51
+ # spec/requests/api/v1/resource_spec.rb
52
+ RSpec.describe "GET /api/v1/resource" do
53
+ let(:user) { create(:user) }
54
+ let(:headers) { user.create_new_auth_token }
55
+
56
+ context "when authenticated" do
57
+ it "returns 200 with expected payload" do
58
+ get "/api/v1/resource", headers: headers
59
+ expect(response).to have_http_status(:ok)
60
+ expect(json_response[:data]).to include(expected_keys)
61
+ end
62
+ end
63
+
64
+ context "when unauthenticated" do
65
+ it "returns 401" do
66
+ get "/api/v1/resource"
67
+ expect(response).to have_http_status(:unauthorized)
68
+ end
69
+ end
70
+ end
71
+ ```
72
+
73
+ ### Model Specs
74
+ ```ruby
75
+ # spec/models/resource_spec.rb
76
+ RSpec.describe Resource do
77
+ describe "validations" do
78
+ it { is_expected.to validate_presence_of(:name) }
79
+ it { is_expected.to belong_to(:agency) }
80
+ end
81
+
82
+ describe "scopes" do
83
+ describe ".active" do
84
+ it "returns only active records" do
85
+ active = create(:resource, status: :active)
86
+ inactive = create(:resource, status: :inactive)
87
+ expect(described_class.active).to include(active)
88
+ expect(described_class.active).not_to include(inactive)
89
+ end
90
+ end
91
+ end
92
+ end
93
+ ```
94
+
95
+ ### Factories (FactoryBot)
96
+ - Always check if factory exists before creating a new one
97
+ - Use `build` for unit tests, `create` only when DB persistence needed
98
+ - Use `create_list` sparingly (slow)
99
+
100
+ ### Run Commands
101
+ ```bash
102
+ RAILS_ENV=test bundle exec rspec spec/path/to/file_spec.rb # single file
103
+ RAILS_ENV=test bundle exec rspec spec/path/to/file_spec.rb:42 # specific line
104
+ RAILS_ENV=test bundle exec rspec --format documentation # verbose output
105
+ ```
106
+
107
+ ---
108
+
109
+ ## Next.js / Jest + Testing Library (frontend-app)
110
+
111
+ ### Component Test Structure
112
+ ```typescript
113
+ // __tests__/components/ComponentName.test.tsx
114
+ import { render, screen, userEvent } from "@testing-library/react"
115
+ import { ComponentName } from "@/components/ComponentName"
116
+
117
+ describe("ComponentName", () => {
118
+ it("renders with required props", () => {
119
+ render(<ComponentName title="Test" />)
120
+ expect(screen.getByText("Test")).toBeInTheDocument()
121
+ })
122
+
123
+ it("calls onAction when button clicked", async () => {
124
+ const onAction = jest.fn()
125
+ render(<ComponentName onAction={onAction} />)
126
+ await userEvent.click(screen.getByRole("button"))
127
+ expect(onAction).toHaveBeenCalledOnce()
128
+ })
129
+ })
130
+ ```
131
+
132
+ ### Hook Tests
133
+ ```typescript
134
+ // __tests__/hooks/useHookName.test.ts
135
+ import { renderHook, act } from "@testing-library/react"
136
+ import { useHookName } from "@/hooks/useHookName"
137
+
138
+ describe("useHookName", () => {
139
+ it("returns initial state", () => {
140
+ const { result } = renderHook(() => useHookName())
141
+ expect(result.current.value).toBe(expected)
142
+ })
143
+ })
144
+ ```
145
+
146
+ ---
147
+
148
+ ## Python / pytest (ai-service)
149
+
150
+ ```python
151
+ # tests/test_agent_name.py
152
+ import pytest
153
+ from unittest.mock import AsyncMock, patch
154
+ from src.app.agents.agent_name import AgentName
155
+
156
+ @pytest.mark.asyncio
157
+ async def test_agent_processes_valid_input():
158
+ agent = AgentName()
159
+ result = await agent.process({"input": "test"})
160
+ assert result["status"] == "success"
161
+ assert "output" in result
162
+
163
+ @pytest.mark.asyncio
164
+ async def test_agent_handles_invalid_input():
165
+ agent = AgentName()
166
+ with pytest.raises(ValueError, match="Invalid input"):
167
+ await agent.process({})
168
+ ```
169
+
170
+ ## TDD Workflow
171
+
172
+ 1. Read the requirement / issue tracker
173
+ 2. Write the **outermost failing test** first (request spec / component test)
174
+ 3. Run it → confirm it's RED
175
+ 4. Write minimum implementation to make it GREEN
176
+ 5. Refactor (extract service, clean up, DRY)
177
+ 6. Write edge case + error case tests
178
+ 7. Repeat until full coverage
@@ -0,0 +1,39 @@
1
+ ---
2
+ description: Generate comprehensive test specs for a file or feature — happy path, edge cases, error cases.
3
+ tools: ["Bash", "Read", "Write", "Edit", "Grep", "Glob"]
4
+ ---
5
+
6
+ Generate thorough test specs for a given file, feature, or bug fix.
7
+
8
+ ## Step 1: Analyze the target
9
+ - Read the file(s) to test
10
+ - Identify: public methods, input variations, dependencies, side effects, error paths
11
+ - Check existing specs for patterns: `ls spec/` or search for similar test files
12
+
13
+ ## Step 2: Plan test cases
14
+
15
+ For each public method/endpoint/component:
16
+ - **Happy path** — normal expected usage
17
+ - **Edge cases** — empty inputs, nil/null, boundary values, large datasets, special characters
18
+ - **Error cases** — invalid inputs, missing associations, unauthorized access, network failures
19
+ - **State transitions** — if AASM states involved, test each valid transition and reject invalid ones
20
+ - **Authorization** — if Pundit policies, test each role (admin, manager, recruiter, freelance)
21
+
22
+ ## Step 3: Generate specs
23
+
24
+ **Rails (RSpec):**
25
+ - Model specs: validations, associations, scopes, instance methods
26
+ - Request specs: HTTP status, response body, side effects (DB changes, jobs enqueued)
27
+ - Service specs: input/output, error handling, external service mocking
28
+ - Follow `describe`/`context`/`it` nesting. Use `let`/`let!` for setup
29
+ - Use `FactoryBot` if factories exist, otherwise `build`/`create` directly
30
+
31
+ **Next.js (when Vitest is set up):**
32
+ - Component tests: renders correctly, user interactions, loading/error states
33
+ - Hook tests: query behavior, mutation side effects, cache invalidation
34
+ - Use accessible queries: `getByRole`, `getByText`, `getByLabelText`
35
+
36
+ ## Step 4: Run and verify
37
+ - Run the generated specs
38
+ - Fix any failures from incorrect assumptions
39
+ - Report coverage: what's tested, what's intentionally skipped and why
@@ -0,0 +1,129 @@
1
+ {
2
+ "schemaVersion": 1,
3
+ "package": {
4
+ "name": "axel-setup",
5
+ "version": "0.2.0"
6
+ },
7
+ "defaultTarget": "claude",
8
+ "targets": {
9
+ "claude": {
10
+ "description": "Full Claude Code install with hooks, commands, agents, skills, settings, plugins, and optional monitor tooling.",
11
+ "defaultRoot": "~/.claude",
12
+ "fullySupported": true
13
+ },
14
+ "codex": {
15
+ "description": "Portable Codex install with AGENTS instructions, skills, commands, agents, scripts, and manifest. Claude-only hooks and plugins are skipped.",
16
+ "defaultRoot": "$CODEX_HOME or ~/.codex",
17
+ "fullySupported": false
18
+ },
19
+ "generic": {
20
+ "description": "Export-only bundle for other agent runtimes. Writes only to the caller-provided output directory.",
21
+ "defaultRoot": "--output <dir>",
22
+ "fullySupported": false
23
+ }
24
+ },
25
+ "profiles": {
26
+ "core": {
27
+ "description": "Public safe default setup with conservative permissions and optional local side effects disabled.",
28
+ "safePermissions": true
29
+ },
30
+ "personal": {
31
+ "description": "Full personal setup with permissive local automation.",
32
+ "safePermissions": false
33
+ },
34
+ "team-safe": {
35
+ "description": "Team-friendly setup with safer Claude permission defaults.",
36
+ "safePermissions": true
37
+ },
38
+ "minimal": {
39
+ "description": "Small install surface for evaluation and CI smoke tests.",
40
+ "safePermissions": true
41
+ },
42
+ "ci": {
43
+ "description": "CI-safe profile with external installers and launchd disabled.",
44
+ "safePermissions": true
45
+ },
46
+ "full": {
47
+ "description": "Alias for all bundled AXEL components.",
48
+ "safePermissions": false
49
+ }
50
+ },
51
+ "requiredPaths": [
52
+ {
53
+ "path": "settings.json",
54
+ "targets": ["claude"],
55
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
56
+ },
57
+ {
58
+ "path": "hooks/enforce-agent-model.jq",
59
+ "targets": ["claude"],
60
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
61
+ },
62
+ {
63
+ "path": "hooks/validate-commit-format.sh",
64
+ "targets": ["claude"],
65
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
66
+ },
67
+ {
68
+ "path": "commands/daily.md",
69
+ "targets": ["claude", "codex", "generic"],
70
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
71
+ },
72
+ {
73
+ "path": "agents/excelsior-verifier.md",
74
+ "targets": ["claude", "codex", "generic"],
75
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
76
+ },
77
+ {
78
+ "path": "skills/model-routing/SKILL.md",
79
+ "targets": ["claude", "codex", "generic"],
80
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
81
+ },
82
+ {
83
+ "path": "skills/ui-ux-pro-max/SKILL.md",
84
+ "targets": ["claude", "codex", "generic"],
85
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
86
+ },
87
+ {
88
+ "path": "skills/ui-ux-pro-max/data/colors.csv",
89
+ "targets": ["claude", "codex", "generic"],
90
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
91
+ },
92
+ {
93
+ "path": "skills/ui-ux-pro-max/scripts/search.py",
94
+ "targets": ["claude", "codex", "generic"],
95
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
96
+ },
97
+ {
98
+ "path": "AGENTS.md",
99
+ "targets": ["codex", "generic"],
100
+ "profiles": ["core", "personal", "team-safe", "minimal", "ci", "full"]
101
+ },
102
+ {
103
+ "path": "scripts/posthog-snapshot-loader.sh",
104
+ "targets": ["claude", "codex", "generic"],
105
+ "profiles": ["core", "personal", "team-safe", "full"],
106
+ "optionalFlag": "enable-posthog"
107
+ },
108
+ {
109
+ "path": "tools/session-server.js",
110
+ "targets": ["claude"],
111
+ "profiles": ["core", "personal", "team-safe", "full"],
112
+ "skipFlag": "skip-monitor"
113
+ },
114
+ {
115
+ "path": "keybindings.json",
116
+ "targets": ["claude"],
117
+ "profiles": ["core", "personal", "team-safe", "full"],
118
+ "skipFlag": "skip-keybindings"
119
+ }
120
+ ],
121
+ "externalIntegrations": [
122
+ {
123
+ "id": "gsd",
124
+ "name": "get-shit-done-cc",
125
+ "managedExternally": true,
126
+ "installCommand": "npx -y get-shit-done-cc@latest"
127
+ }
128
+ ]
129
+ }