@bradygaster/squad-sdk 0.9.1 → 0.9.2-insider.1
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/README.md +340 -296
- package/dist/agents/history-shadow.d.ts +7 -5
- package/dist/agents/history-shadow.d.ts.map +1 -1
- package/dist/agents/history-shadow.js +69 -78
- package/dist/agents/history-shadow.js.map +1 -1
- package/dist/agents/index.d.ts +12 -1
- package/dist/agents/index.d.ts.map +1 -1
- package/dist/agents/index.js +62 -9
- package/dist/agents/index.js.map +1 -1
- package/dist/agents/lifecycle.d.ts +4 -0
- package/dist/agents/lifecycle.d.ts.map +1 -1
- package/dist/agents/lifecycle.js +6 -7
- package/dist/agents/lifecycle.js.map +1 -1
- package/dist/agents/onboarding.d.ts +4 -2
- package/dist/agents/onboarding.d.ts.map +1 -1
- package/dist/agents/onboarding.js +26 -16
- package/dist/agents/onboarding.js.map +1 -1
- package/dist/agents/personal.d.ts +2 -1
- package/dist/agents/personal.d.ts.map +1 -1
- package/dist/agents/personal.js +11 -12
- package/dist/agents/personal.js.map +1 -1
- package/dist/build/bundle.d.ts.map +1 -1
- package/dist/build/bundle.js +6 -6
- package/dist/build/bundle.js.map +1 -1
- package/dist/build/github-dist.js +42 -42
- package/dist/build/release.d.ts.map +1 -1
- package/dist/build/release.js +7 -5
- package/dist/build/release.js.map +1 -1
- package/dist/casting/index.d.ts.map +1 -1
- package/dist/casting/index.js +4 -3
- package/dist/casting/index.js.map +1 -1
- package/dist/config/agent-source.d.ts +5 -1
- package/dist/config/agent-source.d.ts.map +1 -1
- package/dist/config/agent-source.js +85 -41
- package/dist/config/agent-source.js.map +1 -1
- package/dist/config/init.d.ts +4 -3
- package/dist/config/init.d.ts.map +1 -1
- package/dist/config/init.js +257 -236
- package/dist/config/init.js.map +1 -1
- package/dist/config/legacy-fallback.d.ts +3 -2
- package/dist/config/legacy-fallback.d.ts.map +1 -1
- package/dist/config/legacy-fallback.js +16 -14
- package/dist/config/legacy-fallback.js.map +1 -1
- package/dist/config/models.d.ts +9 -6
- package/dist/config/models.d.ts.map +1 -1
- package/dist/config/models.js +35 -25
- package/dist/config/models.js.map +1 -1
- package/dist/index.d.ts +5 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +14 -1
- package/dist/index.js.map +1 -1
- package/dist/marketplace/packaging.d.ts.map +1 -1
- package/dist/marketplace/packaging.js +18 -16
- package/dist/marketplace/packaging.js.map +1 -1
- package/dist/multi-squad.d.ts.map +1 -1
- package/dist/multi-squad.js +10 -9
- package/dist/multi-squad.js.map +1 -1
- package/dist/platform/comms-file-log.d.ts.map +1 -1
- package/dist/platform/comms-file-log.js +7 -6
- package/dist/platform/comms-file-log.js.map +1 -1
- package/dist/platform/comms.d.ts.map +1 -1
- package/dist/platform/comms.js +6 -5
- package/dist/platform/comms.js.map +1 -1
- package/dist/platform/index.d.ts.map +1 -1
- package/dist/platform/index.js +4 -3
- package/dist/platform/index.js.map +1 -1
- package/dist/ralph/capabilities.d.ts +30 -1
- package/dist/ralph/capabilities.d.ts.map +1 -1
- package/dist/ralph/capabilities.js +51 -6
- package/dist/ralph/capabilities.js.map +1 -1
- package/dist/ralph/index.d.ts +1 -1
- package/dist/ralph/index.d.ts.map +1 -1
- package/dist/ralph/index.js +4 -3
- package/dist/ralph/index.js.map +1 -1
- package/dist/ralph/rate-limiting.d.ts.map +1 -1
- package/dist/ralph/rate-limiting.js +4 -4
- package/dist/ralph/rate-limiting.js.map +1 -1
- package/dist/remote/bridge.d.ts.map +1 -1
- package/dist/remote/bridge.js +2 -2
- package/dist/remote/bridge.js.map +1 -1
- package/dist/resolution.d.ts +9 -0
- package/dist/resolution.d.ts.map +1 -1
- package/dist/resolution.js +39 -16
- package/dist/resolution.js.map +1 -1
- package/dist/roles/catalog.d.ts +1 -1
- package/dist/runtime/config.d.ts.map +1 -1
- package/dist/runtime/config.js +8 -7
- package/dist/runtime/config.js.map +1 -1
- package/dist/runtime/cross-squad.d.ts.map +1 -1
- package/dist/runtime/cross-squad.js +8 -7
- package/dist/runtime/cross-squad.js.map +1 -1
- package/dist/runtime/scheduler.d.ts.map +1 -1
- package/dist/runtime/scheduler.js +8 -8
- package/dist/runtime/scheduler.js.map +1 -1
- package/dist/runtime/squad-observer.d.ts.map +1 -1
- package/dist/runtime/squad-observer.js +7 -4
- package/dist/runtime/squad-observer.js.map +1 -1
- package/dist/sharing/consult.d.ts +1 -1
- package/dist/sharing/consult.d.ts.map +1 -1
- package/dist/sharing/consult.js +144 -142
- package/dist/sharing/consult.js.map +1 -1
- package/dist/sharing/export.d.ts.map +1 -1
- package/dist/sharing/export.js +16 -16
- package/dist/sharing/export.js.map +1 -1
- package/dist/sharing/import.d.ts.map +1 -1
- package/dist/sharing/import.js +13 -12
- package/dist/sharing/import.js.map +1 -1
- package/dist/skills/skill-loader.d.ts.map +1 -1
- package/dist/skills/skill-loader.js +10 -9
- package/dist/skills/skill-loader.js.map +1 -1
- package/dist/skills/skill-script-loader.d.ts.map +1 -1
- package/dist/skills/skill-script-loader.js +6 -4
- package/dist/skills/skill-script-loader.js.map +1 -1
- package/dist/skills/skill-source.d.ts +3 -1
- package/dist/skills/skill-source.d.ts.map +1 -1
- package/dist/skills/skill-source.js +18 -16
- package/dist/skills/skill-source.js.map +1 -1
- package/dist/state/collection-map.d.ts +43 -0
- package/dist/state/collection-map.d.ts.map +1 -0
- package/dist/state/collection-map.js +9 -0
- package/dist/state/collection-map.js.map +1 -0
- package/dist/state/collections.d.ts +102 -0
- package/dist/state/collections.d.ts.map +1 -0
- package/dist/state/collections.js +317 -0
- package/dist/state/collections.js.map +1 -0
- package/dist/state/domain-types.d.ts +122 -0
- package/dist/state/domain-types.d.ts.map +1 -0
- package/dist/state/domain-types.js +54 -0
- package/dist/state/domain-types.js.map +1 -0
- package/dist/state/handles.d.ts +16 -0
- package/dist/state/handles.d.ts.map +1 -0
- package/dist/state/handles.js +161 -0
- package/dist/state/handles.js.map +1 -0
- package/dist/state/index.d.ts +17 -0
- package/dist/state/index.d.ts.map +1 -0
- package/dist/state/index.js +15 -0
- package/dist/state/index.js.map +1 -0
- package/dist/state/io/charter-io.d.ts +28 -0
- package/dist/state/io/charter-io.d.ts.map +1 -0
- package/dist/state/io/charter-io.js +94 -0
- package/dist/state/io/charter-io.js.map +1 -0
- package/dist/state/io/decisions-io.d.ts +42 -0
- package/dist/state/io/decisions-io.d.ts.map +1 -0
- package/dist/state/io/decisions-io.js +66 -0
- package/dist/state/io/decisions-io.js.map +1 -0
- package/dist/state/io/history-io.d.ts +37 -0
- package/dist/state/io/history-io.d.ts.map +1 -0
- package/dist/state/io/history-io.js +102 -0
- package/dist/state/io/history-io.js.map +1 -0
- package/dist/state/io/index.d.ts +19 -0
- package/dist/state/io/index.d.ts.map +1 -0
- package/dist/state/io/index.js +19 -0
- package/dist/state/io/index.js.map +1 -0
- package/dist/state/io/routing-io.d.ts +37 -0
- package/dist/state/io/routing-io.d.ts.map +1 -0
- package/dist/state/io/routing-io.js +99 -0
- package/dist/state/io/routing-io.js.map +1 -0
- package/dist/state/io/team-io.d.ts +46 -0
- package/dist/state/io/team-io.d.ts.map +1 -0
- package/dist/state/io/team-io.js +82 -0
- package/dist/state/io/team-io.js.map +1 -0
- package/dist/state/schema.d.ts +24 -0
- package/dist/state/schema.d.ts.map +1 -0
- package/dist/state/schema.js +41 -0
- package/dist/state/schema.js.map +1 -0
- package/dist/state/squad-state.d.ts +42 -0
- package/dist/state/squad-state.d.ts.map +1 -0
- package/dist/state/squad-state.js +68 -0
- package/dist/state/squad-state.js.map +1 -0
- package/dist/storage/fs-storage-provider.d.ts +60 -0
- package/dist/storage/fs-storage-provider.d.ts.map +1 -0
- package/dist/storage/fs-storage-provider.js +377 -0
- package/dist/storage/fs-storage-provider.js.map +1 -0
- package/dist/storage/in-memory-storage-provider.d.ts +46 -0
- package/dist/storage/in-memory-storage-provider.d.ts.map +1 -0
- package/dist/storage/in-memory-storage-provider.js +264 -0
- package/dist/storage/in-memory-storage-provider.js.map +1 -0
- package/dist/storage/index.d.ts +6 -0
- package/dist/storage/index.d.ts.map +1 -0
- package/dist/storage/index.js +5 -0
- package/dist/storage/index.js.map +1 -0
- package/dist/storage/sqlite-storage-provider.d.ts +95 -0
- package/dist/storage/sqlite-storage-provider.d.ts.map +1 -0
- package/dist/storage/sqlite-storage-provider.js +383 -0
- package/dist/storage/sqlite-storage-provider.js.map +1 -0
- package/dist/storage/storage-error.d.ts +28 -0
- package/dist/storage/storage-error.d.ts.map +1 -0
- package/dist/storage/storage-error.js +35 -0
- package/dist/storage/storage-error.js.map +1 -0
- package/dist/storage/storage-provider.d.ts +161 -0
- package/dist/storage/storage-provider.d.ts.map +1 -0
- package/dist/storage/storage-provider.js +18 -0
- package/dist/storage/storage-provider.js.map +1 -0
- package/dist/streams/resolver.d.ts.map +1 -1
- package/dist/streams/resolver.js +6 -5
- package/dist/streams/resolver.js.map +1 -1
- package/dist/tools/index.d.ts +5 -1
- package/dist/tools/index.d.ts.map +1 -1
- package/dist/tools/index.js +54 -15
- package/dist/tools/index.js.map +1 -1
- package/dist/upstream/resolver.d.ts +3 -2
- package/dist/upstream/resolver.d.ts.map +1 -1
- package/dist/upstream/resolver.js +33 -32
- package/dist/upstream/resolver.js.map +1 -1
- package/package.json +33 -1
- package/templates/casting/Futurama.json +9 -9
- package/templates/casting-history.json +4 -4
- package/templates/casting-policy.json +37 -37
- package/templates/casting-reference.md +104 -104
- package/templates/casting-registry.json +3 -3
- package/templates/ceremonies.md +41 -41
- package/templates/charter.md +53 -53
- package/templates/constraint-tracking.md +38 -38
- package/templates/cooperative-rate-limiting.md +229 -229
- package/templates/copilot-instructions.md +46 -46
- package/templates/history.md +10 -10
- package/templates/identity/now.md +9 -9
- package/templates/identity/wisdom.md +15 -15
- package/templates/issue-lifecycle.md +412 -412
- package/templates/keda-scaler.md +164 -164
- package/templates/machine-capabilities.md +74 -74
- package/templates/mcp-config.md +90 -90
- package/templates/multi-agent-format.md +28 -28
- package/templates/plugin-marketplace.md +49 -49
- package/templates/ralph-circuit-breaker.md +313 -313
- package/templates/raw-agent-output.md +37 -37
- package/templates/roster.md +60 -60
- package/templates/routing.md +39 -39
- package/templates/run-output.md +50 -50
- package/templates/schedule.json +19 -19
- package/templates/scribe-charter.md +123 -119
- package/templates/skill.md +24 -24
- package/templates/skills/agent-collaboration/SKILL.md +42 -42
- package/templates/skills/agent-conduct/SKILL.md +24 -24
- package/templates/skills/architectural-proposals/SKILL.md +151 -151
- package/templates/skills/ci-validation-gates/SKILL.md +84 -84
- package/templates/skills/cli-wiring/SKILL.md +47 -47
- package/templates/skills/client-compatibility/SKILL.md +89 -89
- package/templates/skills/cross-machine-coordination/SKILL.md +434 -0
- package/templates/skills/cross-squad/SKILL.md +114 -114
- package/templates/skills/distributed-mesh/SKILL.md +287 -287
- package/templates/skills/distributed-mesh/mesh.json.example +30 -30
- package/templates/skills/distributed-mesh/sync-mesh.ps1 +111 -111
- package/templates/skills/distributed-mesh/sync-mesh.sh +104 -104
- package/templates/skills/docs-standards/SKILL.md +71 -71
- package/templates/skills/economy-mode/SKILL.md +114 -114
- package/templates/skills/error-recovery/SKILL.md +99 -0
- package/templates/skills/external-comms/SKILL.md +329 -329
- package/templates/skills/gh-auth-isolation/SKILL.md +183 -183
- package/templates/skills/git-workflow/SKILL.md +204 -204
- package/templates/skills/github-multi-account/SKILL.md +95 -95
- package/templates/skills/history-hygiene/SKILL.md +36 -36
- package/templates/skills/humanizer/SKILL.md +105 -105
- package/templates/skills/init-mode/SKILL.md +102 -102
- package/templates/skills/iterative-retrieval/SKILL.md +165 -0
- package/templates/skills/model-selection/SKILL.md +117 -117
- package/templates/skills/nap/SKILL.md +24 -24
- package/templates/skills/notification-routing/SKILL.md +105 -0
- package/templates/skills/personal-squad/SKILL.md +57 -57
- package/templates/skills/pr-screenshots/SKILL.md +149 -0
- package/templates/skills/project-conventions/SKILL.md +56 -56
- package/templates/skills/ralph-two-pass-scan/SKILL.md +35 -0
- package/templates/skills/reflect/SKILL.md +229 -0
- package/templates/skills/release-process/SKILL.md +131 -423
- package/templates/skills/reskill/SKILL.md +92 -92
- package/templates/skills/retro-enforcement/SKILL.md +148 -0
- package/templates/skills/reviewer-protocol/SKILL.md +79 -79
- package/templates/skills/secret-handling/SKILL.md +200 -200
- package/templates/skills/session-recovery/SKILL.md +155 -155
- package/templates/skills/squad-conventions/SKILL.md +69 -69
- package/templates/skills/test-discipline/SKILL.md +37 -37
- package/templates/skills/tiered-memory/SKILL.md +234 -0
- package/templates/skills/windows-compatibility/SKILL.md +98 -74
- package/templates/{squad.agent.md → squad.agent.md.template} +57 -28
- package/templates/workflows/squad-ci.yml +24 -24
- package/templates/workflows/squad-docs.yml +54 -54
- package/templates/workflows/squad-heartbeat.yml +167 -171
- package/templates/workflows/squad-insider-release.yml +61 -61
- package/templates/workflows/squad-issue-assign.yml +161 -161
- package/templates/workflows/squad-label-enforce.yml +181 -181
- package/templates/workflows/squad-preview.yml +55 -55
- package/templates/workflows/squad-promote.yml +120 -120
- package/templates/workflows/squad-release.yml +77 -77
- package/templates/workflows/squad-triage.yml +260 -260
- package/templates/workflows/sync-squad-labels.yml +169 -169
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
name: Squad CI
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
pull_request:
|
|
5
|
-
branches: [dev, preview, main, insider]
|
|
6
|
-
types: [opened, synchronize, reopened]
|
|
7
|
-
push:
|
|
8
|
-
branches: [dev, insider]
|
|
9
|
-
|
|
10
|
-
permissions:
|
|
11
|
-
contents: read
|
|
12
|
-
|
|
13
|
-
jobs:
|
|
14
|
-
test:
|
|
15
|
-
runs-on: ubuntu-latest
|
|
16
|
-
steps:
|
|
17
|
-
- uses: actions/checkout@v4
|
|
18
|
-
|
|
19
|
-
- uses: actions/setup-node@v4
|
|
20
|
-
with:
|
|
21
|
-
node-version: 22
|
|
22
|
-
|
|
23
|
-
- name: Run tests
|
|
24
|
-
run: node --test test/*.test.
|
|
1
|
+
name: Squad CI
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
branches: [dev, preview, main, insider]
|
|
6
|
+
types: [opened, synchronize, reopened]
|
|
7
|
+
push:
|
|
8
|
+
branches: [dev, insider]
|
|
9
|
+
|
|
10
|
+
permissions:
|
|
11
|
+
contents: read
|
|
12
|
+
|
|
13
|
+
jobs:
|
|
14
|
+
test:
|
|
15
|
+
runs-on: ubuntu-latest
|
|
16
|
+
steps:
|
|
17
|
+
- uses: actions/checkout@v4
|
|
18
|
+
|
|
19
|
+
- uses: actions/setup-node@v4
|
|
20
|
+
with:
|
|
21
|
+
node-version: 22
|
|
22
|
+
|
|
23
|
+
- name: Run tests
|
|
24
|
+
run: node --test test/*.test.cjs
|
|
@@ -1,54 +1,54 @@
|
|
|
1
|
-
name: Squad Docs — Build & Deploy
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
workflow_dispatch:
|
|
5
|
-
push:
|
|
6
|
-
branches: [preview]
|
|
7
|
-
paths:
|
|
8
|
-
- 'docs/**'
|
|
9
|
-
- '.github/workflows/squad-docs.yml'
|
|
10
|
-
|
|
11
|
-
permissions:
|
|
12
|
-
contents: read
|
|
13
|
-
pages: write
|
|
14
|
-
id-token: write
|
|
15
|
-
|
|
16
|
-
concurrency:
|
|
17
|
-
group: pages
|
|
18
|
-
cancel-in-progress: true
|
|
19
|
-
|
|
20
|
-
jobs:
|
|
21
|
-
build:
|
|
22
|
-
runs-on: ubuntu-latest
|
|
23
|
-
steps:
|
|
24
|
-
- uses: actions/checkout@v4
|
|
25
|
-
|
|
26
|
-
- uses: actions/setup-node@v4
|
|
27
|
-
with:
|
|
28
|
-
node-version: '22'
|
|
29
|
-
cache: npm
|
|
30
|
-
cache-dependency-path: docs/package-lock.json
|
|
31
|
-
|
|
32
|
-
- name: Install docs dependencies
|
|
33
|
-
working-directory: docs
|
|
34
|
-
run: npm ci
|
|
35
|
-
|
|
36
|
-
- name: Build docs site
|
|
37
|
-
working-directory: docs
|
|
38
|
-
run: npm run build
|
|
39
|
-
|
|
40
|
-
- name: Upload Pages artifact
|
|
41
|
-
uses: actions/upload-pages-artifact@v3
|
|
42
|
-
with:
|
|
43
|
-
path: docs/dist
|
|
44
|
-
|
|
45
|
-
deploy:
|
|
46
|
-
needs: build
|
|
47
|
-
runs-on: ubuntu-latest
|
|
48
|
-
environment:
|
|
49
|
-
name: github-pages
|
|
50
|
-
url: ${{ steps.deployment.outputs.page_url }}
|
|
51
|
-
steps:
|
|
52
|
-
- name: Deploy to GitHub Pages
|
|
53
|
-
id: deployment
|
|
54
|
-
uses: actions/deploy-pages@v4
|
|
1
|
+
name: Squad Docs — Build & Deploy
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_dispatch:
|
|
5
|
+
push:
|
|
6
|
+
branches: [preview]
|
|
7
|
+
paths:
|
|
8
|
+
- 'docs/**'
|
|
9
|
+
- '.github/workflows/squad-docs.yml'
|
|
10
|
+
|
|
11
|
+
permissions:
|
|
12
|
+
contents: read
|
|
13
|
+
pages: write
|
|
14
|
+
id-token: write
|
|
15
|
+
|
|
16
|
+
concurrency:
|
|
17
|
+
group: pages
|
|
18
|
+
cancel-in-progress: true
|
|
19
|
+
|
|
20
|
+
jobs:
|
|
21
|
+
build:
|
|
22
|
+
runs-on: ubuntu-latest
|
|
23
|
+
steps:
|
|
24
|
+
- uses: actions/checkout@v4
|
|
25
|
+
|
|
26
|
+
- uses: actions/setup-node@v4
|
|
27
|
+
with:
|
|
28
|
+
node-version: '22'
|
|
29
|
+
cache: npm
|
|
30
|
+
cache-dependency-path: docs/package-lock.json
|
|
31
|
+
|
|
32
|
+
- name: Install docs dependencies
|
|
33
|
+
working-directory: docs
|
|
34
|
+
run: npm ci
|
|
35
|
+
|
|
36
|
+
- name: Build docs site
|
|
37
|
+
working-directory: docs
|
|
38
|
+
run: npm run build
|
|
39
|
+
|
|
40
|
+
- name: Upload Pages artifact
|
|
41
|
+
uses: actions/upload-pages-artifact@v3
|
|
42
|
+
with:
|
|
43
|
+
path: docs/dist
|
|
44
|
+
|
|
45
|
+
deploy:
|
|
46
|
+
needs: build
|
|
47
|
+
runs-on: ubuntu-latest
|
|
48
|
+
environment:
|
|
49
|
+
name: github-pages
|
|
50
|
+
url: ${{ steps.deployment.outputs.page_url }}
|
|
51
|
+
steps:
|
|
52
|
+
- name: Deploy to GitHub Pages
|
|
53
|
+
id: deployment
|
|
54
|
+
uses: actions/deploy-pages@v4
|
|
@@ -1,171 +1,167 @@
|
|
|
1
|
-
name: Squad Heartbeat (Ralph)
|
|
2
|
-
# ⚠️ SYNC: This workflow is maintained in 4 locations. Changes must be applied to all:
|
|
3
|
-
# - templates/workflows/squad-heartbeat.yml (source template)
|
|
4
|
-
# - packages/squad-cli/templates/workflows/squad-heartbeat.yml (CLI package)
|
|
5
|
-
# - .squad/templates/workflows/squad-heartbeat.yml (installed template)
|
|
6
|
-
# - .github/workflows/squad-heartbeat.yml (active workflow)
|
|
7
|
-
# Run 'squad upgrade' to sync installed copies from source templates.
|
|
8
|
-
|
|
9
|
-
on:
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
'',
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
});
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
if
|
|
118
|
-
|
|
119
|
-
const
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
}
|
|
169
|
-
} catch (e) {
|
|
170
|
-
core.info(`No squad:copilot label found or error: ${e.message}`);
|
|
171
|
-
}
|
|
1
|
+
name: Squad Heartbeat (Ralph)
|
|
2
|
+
# ⚠️ SYNC: This workflow is maintained in 4 locations. Changes must be applied to all:
|
|
3
|
+
# - templates/workflows/squad-heartbeat.yml (source template)
|
|
4
|
+
# - packages/squad-cli/templates/workflows/squad-heartbeat.yml (CLI package)
|
|
5
|
+
# - .squad/templates/workflows/squad-heartbeat.yml (installed template)
|
|
6
|
+
# - .github/workflows/squad-heartbeat.yml (active workflow)
|
|
7
|
+
# Run 'squad upgrade' to sync installed copies from source templates.
|
|
8
|
+
|
|
9
|
+
on:
|
|
10
|
+
# React to completed work or new squad work
|
|
11
|
+
issues:
|
|
12
|
+
types: [closed, labeled]
|
|
13
|
+
pull_request:
|
|
14
|
+
types: [closed]
|
|
15
|
+
|
|
16
|
+
# Manual trigger
|
|
17
|
+
workflow_dispatch:
|
|
18
|
+
|
|
19
|
+
permissions:
|
|
20
|
+
issues: write
|
|
21
|
+
contents: read
|
|
22
|
+
pull-requests: read
|
|
23
|
+
|
|
24
|
+
jobs:
|
|
25
|
+
heartbeat:
|
|
26
|
+
runs-on: ubuntu-latest
|
|
27
|
+
steps:
|
|
28
|
+
- uses: actions/checkout@v4
|
|
29
|
+
|
|
30
|
+
- name: Check triage script
|
|
31
|
+
id: check-script
|
|
32
|
+
run: |
|
|
33
|
+
if [ -f ".squad/templates/ralph-triage.js" ]; then
|
|
34
|
+
echo "has_script=true" >> $GITHUB_OUTPUT
|
|
35
|
+
else
|
|
36
|
+
echo "has_script=false" >> $GITHUB_OUTPUT
|
|
37
|
+
echo "⚠️ ralph-triage.js not found — run 'squad upgrade' to install"
|
|
38
|
+
fi
|
|
39
|
+
|
|
40
|
+
- name: Ralph — Smart triage
|
|
41
|
+
if: steps.check-script.outputs.has_script == 'true'
|
|
42
|
+
env:
|
|
43
|
+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
44
|
+
run: |
|
|
45
|
+
node .squad/templates/ralph-triage.js \
|
|
46
|
+
--squad-dir .squad \
|
|
47
|
+
--output triage-results.json
|
|
48
|
+
|
|
49
|
+
- name: Ralph — Apply triage decisions
|
|
50
|
+
if: steps.check-script.outputs.has_script == 'true' && hashFiles('triage-results.json') != ''
|
|
51
|
+
uses: actions/github-script@v7
|
|
52
|
+
with:
|
|
53
|
+
script: |
|
|
54
|
+
const fs = require('fs');
|
|
55
|
+
const path = 'triage-results.json';
|
|
56
|
+
if (!fs.existsSync(path)) {
|
|
57
|
+
core.info('No triage results — board is clear');
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
const results = JSON.parse(fs.readFileSync(path, 'utf8'));
|
|
62
|
+
if (results.length === 0) {
|
|
63
|
+
core.info('📋 Board is clear — Ralph found no untriaged issues');
|
|
64
|
+
return;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
for (const decision of results) {
|
|
68
|
+
try {
|
|
69
|
+
await github.rest.issues.addLabels({
|
|
70
|
+
owner: context.repo.owner,
|
|
71
|
+
repo: context.repo.repo,
|
|
72
|
+
issue_number: decision.issueNumber,
|
|
73
|
+
labels: [decision.label]
|
|
74
|
+
});
|
|
75
|
+
|
|
76
|
+
await github.rest.issues.createComment({
|
|
77
|
+
owner: context.repo.owner,
|
|
78
|
+
repo: context.repo.repo,
|
|
79
|
+
issue_number: decision.issueNumber,
|
|
80
|
+
body: [
|
|
81
|
+
'### 🔄 Ralph — Auto-Triage',
|
|
82
|
+
'',
|
|
83
|
+
`**Assigned to:** ${decision.assignTo}`,
|
|
84
|
+
`**Reason:** ${decision.reason}`,
|
|
85
|
+
`**Source:** ${decision.source}`,
|
|
86
|
+
'',
|
|
87
|
+
'> Ralph auto-triaged this issue using routing rules.',
|
|
88
|
+
'> To reassign, swap the `squad:*` label.'
|
|
89
|
+
].join('\n')
|
|
90
|
+
});
|
|
91
|
+
|
|
92
|
+
core.info(`Triaged #${decision.issueNumber} → ${decision.assignTo} (${decision.source})`);
|
|
93
|
+
} catch (e) {
|
|
94
|
+
core.warning(`Failed to triage #${decision.issueNumber}: ${e.message}`);
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
core.info(`🔄 Ralph triaged ${results.length} issue(s)`);
|
|
99
|
+
|
|
100
|
+
# Copilot auto-assign step (uses PAT if available)
|
|
101
|
+
- name: Ralph — Assign @copilot issues
|
|
102
|
+
if: success()
|
|
103
|
+
uses: actions/github-script@v7
|
|
104
|
+
with:
|
|
105
|
+
github-token: ${{ secrets.COPILOT_ASSIGN_TOKEN || secrets.GITHUB_TOKEN }}
|
|
106
|
+
script: |
|
|
107
|
+
const fs = require('fs');
|
|
108
|
+
|
|
109
|
+
let teamFile = '.squad/team.md';
|
|
110
|
+
if (!fs.existsSync(teamFile)) {
|
|
111
|
+
teamFile = '.ai-team/team.md';
|
|
112
|
+
}
|
|
113
|
+
if (!fs.existsSync(teamFile)) return;
|
|
114
|
+
|
|
115
|
+
const content = fs.readFileSync(teamFile, 'utf8');
|
|
116
|
+
|
|
117
|
+
// Check if @copilot is on the team with auto-assign
|
|
118
|
+
const hasCopilot = content.includes('🤖 Coding Agent') || content.includes('@copilot');
|
|
119
|
+
const autoAssign = content.includes('<!-- copilot-auto-assign: true -->');
|
|
120
|
+
if (!hasCopilot || !autoAssign) return;
|
|
121
|
+
|
|
122
|
+
// Find issues labeled squad:copilot with no assignee
|
|
123
|
+
try {
|
|
124
|
+
const { data: copilotIssues } = await github.rest.issues.listForRepo({
|
|
125
|
+
owner: context.repo.owner,
|
|
126
|
+
repo: context.repo.repo,
|
|
127
|
+
labels: 'squad:copilot',
|
|
128
|
+
state: 'open',
|
|
129
|
+
per_page: 5
|
|
130
|
+
});
|
|
131
|
+
|
|
132
|
+
const unassigned = copilotIssues.filter(i =>
|
|
133
|
+
!i.assignees || i.assignees.length === 0
|
|
134
|
+
);
|
|
135
|
+
|
|
136
|
+
if (unassigned.length === 0) {
|
|
137
|
+
core.info('No unassigned squad:copilot issues');
|
|
138
|
+
return;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
// Get repo default branch
|
|
142
|
+
const { data: repoData } = await github.rest.repos.get({
|
|
143
|
+
owner: context.repo.owner,
|
|
144
|
+
repo: context.repo.repo
|
|
145
|
+
});
|
|
146
|
+
|
|
147
|
+
for (const issue of unassigned) {
|
|
148
|
+
try {
|
|
149
|
+
await github.request('POST /repos/{owner}/{repo}/issues/{issue_number}/assignees', {
|
|
150
|
+
owner: context.repo.owner,
|
|
151
|
+
repo: context.repo.repo,
|
|
152
|
+
issue_number: issue.number,
|
|
153
|
+
assignees: ['copilot-swe-agent[bot]'],
|
|
154
|
+
agent_assignment: {
|
|
155
|
+
target_repo: `${context.repo.owner}/${context.repo.repo}`,
|
|
156
|
+
base_branch: repoData.default_branch,
|
|
157
|
+
custom_instructions: `Read .squad/team.md (or .ai-team/team.md) for team context and .squad/routing.md (or .ai-team/routing.md) for routing rules.`
|
|
158
|
+
}
|
|
159
|
+
});
|
|
160
|
+
core.info(`Assigned copilot-swe-agent[bot] to #${issue.number}`);
|
|
161
|
+
} catch (e) {
|
|
162
|
+
core.warning(`Failed to assign @copilot to #${issue.number}: ${e.message}`);
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
} catch (e) {
|
|
166
|
+
core.info(`No squad:copilot label found or error: ${e.message}`);
|
|
167
|
+
}
|
|
@@ -1,61 +1,61 @@
|
|
|
1
|
-
name: Squad Insider Release
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches: [insider]
|
|
6
|
-
|
|
7
|
-
permissions:
|
|
8
|
-
contents: write
|
|
9
|
-
|
|
10
|
-
jobs:
|
|
11
|
-
release:
|
|
12
|
-
runs-on: ubuntu-latest
|
|
13
|
-
steps:
|
|
14
|
-
- uses: actions/checkout@v4
|
|
15
|
-
with:
|
|
16
|
-
fetch-depth: 0
|
|
17
|
-
|
|
18
|
-
- uses: actions/setup-node@v4
|
|
19
|
-
with:
|
|
20
|
-
node-version: 22
|
|
21
|
-
|
|
22
|
-
- name: Run tests
|
|
23
|
-
run: node --test test/*.test.
|
|
24
|
-
|
|
25
|
-
- name: Read version from package.json
|
|
26
|
-
id: version
|
|
27
|
-
run: |
|
|
28
|
-
VERSION=$(node -e "console.log(require('./package.json').version)")
|
|
29
|
-
SHORT_SHA=$(git rev-parse --short HEAD)
|
|
30
|
-
INSIDER_VERSION="${VERSION}-insider+${SHORT_SHA}"
|
|
31
|
-
INSIDER_TAG="v${INSIDER_VERSION}"
|
|
32
|
-
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
|
|
33
|
-
echo "short_sha=$SHORT_SHA" >> "$GITHUB_OUTPUT"
|
|
34
|
-
echo "insider_version=$INSIDER_VERSION" >> "$GITHUB_OUTPUT"
|
|
35
|
-
echo "insider_tag=$INSIDER_TAG" >> "$GITHUB_OUTPUT"
|
|
36
|
-
echo "📦 Base Version: $VERSION (Short SHA: $SHORT_SHA)"
|
|
37
|
-
echo "🏷️ Insider Version: $INSIDER_VERSION"
|
|
38
|
-
echo "🔖 Insider Tag: $INSIDER_TAG"
|
|
39
|
-
|
|
40
|
-
- name: Create git tag
|
|
41
|
-
run: |
|
|
42
|
-
git config user.name "github-actions[bot]"
|
|
43
|
-
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
44
|
-
git tag -a "${{ steps.version.outputs.insider_tag }}" -m "Insider Release ${{ steps.version.outputs.insider_tag }}"
|
|
45
|
-
git push origin "${{ steps.version.outputs.insider_tag }}"
|
|
46
|
-
|
|
47
|
-
- name: Create GitHub Release
|
|
48
|
-
env:
|
|
49
|
-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
50
|
-
run: |
|
|
51
|
-
gh release create "${{ steps.version.outputs.insider_tag }}" \
|
|
52
|
-
--title "${{ steps.version.outputs.insider_tag }}" \
|
|
53
|
-
--notes "This is an insider/development build of Squad. Install with:\`\`\`bash\nnpm install -g @bradygaster/squad-cli@${{ steps.version.outputs.insider_tag }}\n\`\`\`\n\n**Note:** Insider builds may be unstable and are intended for early adopters and testing only." \
|
|
54
|
-
--prerelease
|
|
55
|
-
|
|
56
|
-
- name: Verify release
|
|
57
|
-
env:
|
|
58
|
-
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
59
|
-
run: |
|
|
60
|
-
gh release view "${{ steps.version.outputs.insider_tag }}"
|
|
61
|
-
echo "✅ Insider Release ${{ steps.version.outputs.insider_tag }} created and verified."
|
|
1
|
+
name: Squad Insider Release
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
push:
|
|
5
|
+
branches: [insider]
|
|
6
|
+
|
|
7
|
+
permissions:
|
|
8
|
+
contents: write
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
release:
|
|
12
|
+
runs-on: ubuntu-latest
|
|
13
|
+
steps:
|
|
14
|
+
- uses: actions/checkout@v4
|
|
15
|
+
with:
|
|
16
|
+
fetch-depth: 0
|
|
17
|
+
|
|
18
|
+
- uses: actions/setup-node@v4
|
|
19
|
+
with:
|
|
20
|
+
node-version: 22
|
|
21
|
+
|
|
22
|
+
- name: Run tests
|
|
23
|
+
run: node --test test/*.test.cjs
|
|
24
|
+
|
|
25
|
+
- name: Read version from package.json
|
|
26
|
+
id: version
|
|
27
|
+
run: |
|
|
28
|
+
VERSION=$(node -e "console.log(require('./package.json').version)")
|
|
29
|
+
SHORT_SHA=$(git rev-parse --short HEAD)
|
|
30
|
+
INSIDER_VERSION="${VERSION}-insider+${SHORT_SHA}"
|
|
31
|
+
INSIDER_TAG="v${INSIDER_VERSION}"
|
|
32
|
+
echo "version=$VERSION" >> "$GITHUB_OUTPUT"
|
|
33
|
+
echo "short_sha=$SHORT_SHA" >> "$GITHUB_OUTPUT"
|
|
34
|
+
echo "insider_version=$INSIDER_VERSION" >> "$GITHUB_OUTPUT"
|
|
35
|
+
echo "insider_tag=$INSIDER_TAG" >> "$GITHUB_OUTPUT"
|
|
36
|
+
echo "📦 Base Version: $VERSION (Short SHA: $SHORT_SHA)"
|
|
37
|
+
echo "🏷️ Insider Version: $INSIDER_VERSION"
|
|
38
|
+
echo "🔖 Insider Tag: $INSIDER_TAG"
|
|
39
|
+
|
|
40
|
+
- name: Create git tag
|
|
41
|
+
run: |
|
|
42
|
+
git config user.name "github-actions[bot]"
|
|
43
|
+
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
44
|
+
git tag -a "${{ steps.version.outputs.insider_tag }}" -m "Insider Release ${{ steps.version.outputs.insider_tag }}"
|
|
45
|
+
git push origin "${{ steps.version.outputs.insider_tag }}"
|
|
46
|
+
|
|
47
|
+
- name: Create GitHub Release
|
|
48
|
+
env:
|
|
49
|
+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
50
|
+
run: |
|
|
51
|
+
gh release create "${{ steps.version.outputs.insider_tag }}" \
|
|
52
|
+
--title "${{ steps.version.outputs.insider_tag }}" \
|
|
53
|
+
--notes "This is an insider/development build of Squad. Install with:\`\`\`bash\nnpm install -g @bradygaster/squad-cli@${{ steps.version.outputs.insider_tag }}\n\`\`\`\n\n**Note:** Insider builds may be unstable and are intended for early adopters and testing only." \
|
|
54
|
+
--prerelease
|
|
55
|
+
|
|
56
|
+
- name: Verify release
|
|
57
|
+
env:
|
|
58
|
+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
59
|
+
run: |
|
|
60
|
+
gh release view "${{ steps.version.outputs.insider_tag }}"
|
|
61
|
+
echo "✅ Insider Release ${{ steps.version.outputs.insider_tag }} created and verified."
|