File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ push :
5+ branches : [main]
6+ pull_request :
7+
8+ jobs :
9+ validate :
10+ runs-on : ubuntu-latest
11+ steps :
12+ - uses : actions/checkout@v4
13+
14+ - name : Setup Node.js
15+ uses : actions/setup-node@v4
16+ with :
17+ node-version : ' 18'
18+
19+ - name : Validate plugin.json
20+ run : node -e "JSON.parse(require('fs').readFileSync('plugin.json', 'utf8')); console.log('plugin.json is valid JSON')" 2>/dev/null || echo "plugin.json not found, skipping"
21+
22+ - name : Validate SKILL.md exists and has frontmatter
23+ run : |
24+ SKILL_PATH="skills/shieldcode/SKILL.md"
25+ if [ ! -f "$SKILL_PATH" ]; then
26+ echo "ERROR: $SKILL_PATH not found"
27+ exit 1
28+ fi
29+ echo "SKILL.md found at $SKILL_PATH"
30+ if ! head -1 "$SKILL_PATH" | grep -q '^---'; then
31+ echo "ERROR: SKILL.md does not start with frontmatter (---)"
32+ exit 1
33+ fi
34+ echo "SKILL.md has valid frontmatter"
35+
36+ - name : Check SKILL.md size
37+ run : |
38+ SKILL_PATH="skills/shieldcode/SKILL.md"
39+ SIZE=$(wc -c < "$SKILL_PATH")
40+ LIMIT=32768
41+ echo "SKILL.md size: ${SIZE} bytes (limit: ${LIMIT})"
42+ if [ "$SIZE" -gt "$LIMIT" ]; then
43+ echo "WARNING: SKILL.md exceeds 32KB (${SIZE} bytes). Claude Code may truncate it."
44+ else
45+ echo "SKILL.md size is within limit."
46+ fi
47+
48+ - name : Test install.sh syntax
49+ run : bash -n install.sh && echo "install.sh syntax OK"
50+
51+ - name : Test uninstall.sh syntax
52+ run : bash -n uninstall.sh && echo "uninstall.sh syntax OK"
Original file line number Diff line number Diff line change 1+ name : Release
2+
3+ on :
4+ push :
5+ tags :
6+ - ' v*'
7+
8+ jobs :
9+ release :
10+ runs-on : ubuntu-latest
11+ permissions :
12+ contents : write
13+ steps :
14+ - uses : actions/checkout@v4
15+
16+ - name : Extract changelog for this version
17+ id : changelog
18+ run : |
19+ TAG="${GITHUB_REF_NAME}"
20+ VERSION="${TAG#v}"
21+ NOTES=$(awk "/^## \[?${VERSION}\]?/{found=1; next} found && /^## /{exit} found{print}" CHANGELOG.md)
22+ if [ -z "$NOTES" ]; then
23+ NOTES="Release ${TAG}"
24+ fi
25+ echo "notes<<EOF" >> "$GITHUB_OUTPUT"
26+ echo "$NOTES" >> "$GITHUB_OUTPUT"
27+ echo "EOF" >> "$GITHUB_OUTPUT"
28+
29+ - name : Create GitHub Release
30+ uses : softprops/action-gh-release@v2
31+ with :
32+ name : " ShieldCode ${{ github.ref_name }}"
33+ body : ${{ steps.changelog.outputs.notes }}
34+ files : install.sh
You can’t perform that action at this time.
0 commit comments