Skip to content

Commit 6c889a0

Browse files
committed
Fix CI workflow paths for new project structure
- Update lint job to check templates/.claude/hooks instead of .claude/hooks - Fix directive enforcement test to use correct template paths - Update system integration validation for template-based structure - Fix NPX package test to work from project root instead of subdirectory - All paths now reflect current NPX package organization
1 parent 342048d commit 6c889a0

1 file changed

Lines changed: 12 additions & 13 deletions

File tree

.github/workflows/validate.yml

Lines changed: 12 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -47,26 +47,26 @@ jobs:
4747
- name: Validate directive enforcement
4848
run: |
4949
# Test that directive enforcer exists and is executable
50-
test -x .claude/hooks/directive-enforcer.sh
50+
test -x templates/.claude/hooks/directive-enforcer.sh
5151
echo "✅ Directive enforcer is executable"
5252
5353
# Test basic directive patterns
5454
echo "Testing directive enforcement patterns..."
5555
5656
# Should pass (no violations)
57-
echo "normal file operation" | USER_PROMPT="normal file operation" TOOL_NAME="Write" .claude/hooks/directive-enforcer.sh
57+
echo "normal file operation" | USER_PROMPT="normal file operation" TOOL_NAME="Write" templates/.claude/hooks/directive-enforcer.sh
5858
echo "✅ Normal operations pass"
5959
6060
# Should fail (direct implementation)
61-
if echo "implement new login function" | USER_PROMPT="implement new login function" TOOL_NAME="Write" .claude/hooks/directive-enforcer.sh 2>/dev/null; then
61+
if echo "implement new login function" | USER_PROMPT="implement new login function" TOOL_NAME="Write" templates/.claude/hooks/directive-enforcer.sh 2>/dev/null; then
6262
echo "❌ DIRECTIVE 1 failed - should have blocked direct implementation"
6363
exit 1
6464
else
6565
echo "✅ DIRECTIVE 1 working - blocked direct implementation"
6666
fi
6767
6868
# Should fail (peer-to-peer routing)
69-
if echo "send from @agent-a to @agent-b directly" | USER_PROMPT="send from @agent-a to @agent-b directly" TOOL_NAME="Write" .claude/hooks/directive-enforcer.sh 2>/dev/null; then
69+
if echo "send from @agent-a to @agent-b directly" | USER_PROMPT="send from @agent-a to @agent-b directly" TOOL_NAME="Write" templates/.claude/hooks/directive-enforcer.sh 2>/dev/null; then
7070
echo "❌ DIRECTIVE 2 failed - should have blocked peer-to-peer routing"
7171
exit 1
7272
else
@@ -108,13 +108,13 @@ jobs:
108108
- name: Lint hook scripts
109109
run: |
110110
echo "Linting hook scripts..."
111-
find .claude/hooks -name "*.sh" -type f -exec shellcheck {} +
111+
find templates/.claude/hooks -name "*.sh" -type f -exec shellcheck {} +
112112
echo "✅ All hook scripts pass shellcheck"
113113
114114
- name: Validate hook permissions
115115
run: |
116116
echo "Checking hook script permissions..."
117-
find .claude/hooks -name "*.sh" -type f -exec test -x {} \; -print
117+
find templates/.claude/hooks -name "*.sh" -type f -exec test -x {} \; -print
118118
echo "✅ All hook scripts are executable"
119119
120120
integration:
@@ -131,30 +131,29 @@ jobs:
131131

132132
- name: Test NPX package locally
133133
run: |
134-
cd claude-code-collective
135134
npm install
136135
npm pack
137136
138137
# Test local installation
139138
mkdir -p /tmp/test-install
140139
cd /tmp/test-install
141140
npm init -y
142-
npm install $GITHUB_WORKSPACE/claude-code-collective/claude-code-collective-*.tgz
141+
npm install $GITHUB_WORKSPACE/claude-code-collective-*.tgz
143142
144143
echo "✅ NPX package installation test passed"
145144
146145
- name: Validate system integration
147146
run: |
148147
echo "Testing complete system integration..."
149148
150-
# Check all required directories exist
151-
test -d .claude/agents || { echo "❌ Missing .claude/agents"; exit 1; }
152-
test -d .claude/hooks || { echo "❌ Missing .claude/hooks"; exit 1; }
149+
# Check all required template directories exist
150+
test -d templates/.claude/agents || { echo "❌ Missing templates/.claude/agents"; exit 1; }
151+
test -d templates/.claude/hooks || { echo "❌ Missing templates/.claude/hooks"; exit 1; }
153152
test -d .claude-collective || { echo "❌ Missing .claude-collective"; exit 1; }
154153
test -f CLAUDE.md || { echo "❌ Missing CLAUDE.md"; exit 1; }
155154
156-
# Check key files
157-
test -f .claude/settings.json || { echo "❌ Missing settings.json"; exit 1; }
155+
# Check key template files
156+
test -f templates/.claude/settings.json || { echo "❌ Missing templates/.claude/settings.json"; exit 1; }
158157
test -f .claude-collective/jest.config.js || { echo "❌ Missing jest.config.js"; exit 1; }
159158
test -f .claude-collective/package.json || { echo "❌ Missing package.json"; exit 1; }
160159

0 commit comments

Comments
 (0)