2020 schedule :
2121 - cron : ' 0 6 * * 1' # Weekly on Monday at 6 AM UTC
2222
23+ # Ensure only one instance runs at a time per PR/branch
24+ concurrency :
25+ group : ${{ github.workflow }}-${{ github.head_ref || github.ref }}
26+ cancel-in-progress : true
27+
2328jobs :
2429 # Job 1: Validate command generation (always runs)
2530 validate-generation :
@@ -47,35 +52,37 @@ jobs:
4752 run : |
4853 # Create a test environment
4954 mkdir -p test_project/.deepwork/jobs
55+ mkdir -p test_project/.claude # Required for platform detection
5056 cp -r tests/fixtures/jobs/fruits test_project/.deepwork/jobs/
5157
52- # Install deepwork into test project
58+ # Set up git repo in test project
5359 cd test_project
5460 git init
5561 git config user.email "test@test.com"
5662 git config user.name "Test"
5763 echo "# Test" > README.md
5864 git add . && git commit -m "init"
65+ cd ..
5966
60- # Run deepwork sync to generate commands
61- uv run --directory .. deepwork sync
67+ # Run deepwork install to set up the project (this also runs sync)
68+ uv run deepwork install --platform claude --path test_project
6269
6370 # Validate generated commands exist
6471 echo "Checking generated commands..."
65- ls -la .claude/commands/
72+ ls -la test_project/ .claude/commands/
6673
6774 # Verify command files exist
68- test -f .claude/commands/fruits.identify.md || (echo "Missing fruits.identify.md" && exit 1)
69- test -f .claude/commands/fruits.classify.md || (echo "Missing fruits.classify.md" && exit 1)
75+ test -f test_project/ .claude/commands/fruits.identify.md || (echo "Missing fruits.identify.md" && exit 1)
76+ test -f test_project/ .claude/commands/fruits.classify.md || (echo "Missing fruits.classify.md" && exit 1)
7077
7178 # Verify command content
72- grep -q "# fruits.identify" .claude/commands/fruits.identify.md
73- grep -q "raw_items" .claude/commands/fruits.identify.md
74- grep -q "identified_fruits.md" .claude/commands/fruits.identify.md
79+ grep -q "# fruits.identify" test_project/ .claude/commands/fruits.identify.md
80+ grep -q "raw_items" test_project/ .claude/commands/fruits.identify.md
81+ grep -q "identified_fruits.md" test_project/ .claude/commands/fruits.identify.md
7582
76- grep -q "# fruits.classify" .claude/commands/fruits.classify.md
77- grep -q "identified_fruits.md" .claude/commands/fruits.classify.md
78- grep -q "classified_fruits.md" .claude/commands/fruits.classify.md
83+ grep -q "# fruits.classify" test_project/ .claude/commands/fruits.classify.md
84+ grep -q "identified_fruits.md" test_project/ .claude/commands/fruits.classify.md
85+ grep -q "classified_fruits.md" test_project/ .claude/commands/fruits.classify.md
7986
8087 echo "Command generation validated successfully!"
8188
@@ -129,6 +136,7 @@ jobs:
129136 if : steps.check-key.outputs.has_key == 'true'
130137 run : |
131138 mkdir -p test_project/.deepwork/jobs
139+ mkdir -p test_project/.claude # Required for platform detection
132140 cp -r tests/fixtures/jobs/fruits test_project/.deepwork/jobs/
133141
134142 cd test_project
@@ -137,12 +145,13 @@ jobs:
137145 git config user.name "Test"
138146 echo "# CI Test Project" > README.md
139147 git add . && git commit -m "init"
148+ cd ..
140149
141- # Generate commands
142- uv run --directory .. deepwork sync
150+ # Run deepwork install to set up the project (this also runs sync)
151+ uv run deepwork install --platform claude --path test_project
143152
144153 echo "Test project setup complete"
145- ls -la .claude/commands/
154+ ls -la test_project/ .claude/commands/
146155
147156 - name : Run Claude Code - Identify Step
148157 if : steps.check-key.outputs.has_key == 'true'
0 commit comments