github-actions-cicd
Skill2 starsChanged 8 months agoMITView on GitHub
Expert implementation and optimization of GitHub Actions CI/CD pipelines. Use when designing workflows, debugging pipeline failures, optimizing build times, or implementing best practices for continuous integration and deployment.
- Reads credentials
- Installs packages
4 other projects use a version of this.
Adopted by
Most recently taken up by
- NicoGenti/opencode-orchestrator-kittheir own version, first seen Nov 8, 2026
- ai-enhanced-engineer/aiee-skillstheir own version, first seen Nov 1, 2026
- jenreh/appkittheir own version, first seen Jul 8, 2026
- julweber/ai_agent_skillsword for word, first seen Mar 20, 2026
Other versions4 projects use a version of this.
Word for word · 1
- julweber/ai_agent_skills★ 2100% same
Edited · 0
None found.
Wrote their own version · 3
- NicoGenti/opencode-orchestrator-kit★ 9same name
- ai-enhanced-engineer/aiee-skills★ 4same name
- jenreh/appkit★ 4same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository51 other files it gives its agents.
- AGENTS.mdAGENTS.md
- ai-agent-skills-assistantSkill
- ansibleSkill
- artificial-analysisSkill
- cavemanSkill
- claude-cliSkill
- code-doctorSkill
- code-summarizerSkill
- codex-cliSkill
- concourse-ciSkill
- dev-brainstormingSkill
- docker-cliSkill
- file-organizerSkill
- frontend-web-developerSkill
- github-cliSkill
- gitlab-ci-cdSkill
- grill-meSkill
- gtd-assistantSkill
- herdr-cliSkill
- hf-cliSkill
- karpathy-guidelinesSkill
- kestraSkill
- list-large-filesSkill
- list-most-intensive-processesSkill
- llama-cppSkill
- llm-wikiSkill
- mermaidSkill
- morning-ritualSkill
- obsidian-masterSkill
- obsidian-open-loops-collectorSkill
- opencode-agent-creatorSkill
- opencode-cliSkill
- pi-cliSkill
- pi-subagents-masterSkill
- planka-development-flowSkill
- plnk-cliSkill
- ponytailSkill
- product-prd-brainstormingSkill
- python-api-developerSkill
- ralph-prd-converterSkill
- ralph-prd-generatorSkill
- release-managementSkill
- rest-testsuite-skillSkill
- skill-loaderSkill
- design-taste-frontendSkill
- terraformSkill
- tmux-coderSkill
- tmux-specialistSkill
- trello-cliSkill
- tts-conversationSkill
- uvSkill
The file
We split this skill into the rules it gives an agent
10 rules. About 0 are common, 8 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈8
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 71
Best Practice: Use paths to filter irrelevant changes:
- Distinctive: line 105
Use matrices to test across multiple configurations:
- Very specific: line 150
Use hashFiles() for cache invalidation on lockfile changes
- Very specific: line 240
Use actionlint for syntax validation:
- Distinctive: line 255
Path filtering: Only run workflows on relevant file changes
- Distinctive: line 257
Self-hosted runners: Use faster hardware for heavy workloads
- Distinctive: line 258
Avoid redundant steps: Don't checkout or install if not needed
- Distinctive: line 301
Explicit waits: instead of arbitrary sleep times
- Distinctive: line 312
Test data isolation: Create/cleanup unique data per run
- Distinctive: line 357
Ensure required fields present
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
GitHub Actions CI/CD Specialist
Expert guidance on implementing, debugging, and optimizing GitHub Actions workflows for CI/CD pipelines.
When to Use This Skill
Activate this skill when the user:
- Wants to create or modify a
.github/workflows/*.ymlfile - Experiences workflow failures and needs troubleshooting help
- Asks about matrix builds, caching strategies, or secrets management
- Needs guidance on CI/CD best practices
- Wants to optimize pipeline performance
Core Workflow Structure
Basic Template
name: CI Pipeline
on:
push:
branches: [main]
pull_request:
branches: [main]
permissions:
contents: read
env:
NODE_ENV: production
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- run: npm ci
- run: npm testKey Implementation Guidelines
1. Workflow Triggers (on)
Choose appropriate triggers to balance responsiveness and cost:
| Trigger Type | Use Case | Example |
push | Main branch deployments | branches: [main, develop] |
pull_request | PR validation | branches: [main] |
workflow_dispatch | Manual triggering | For ad-hoc runs |
schedule | Periodic jobs | cron: '0 0 * * *' |
Best Practice: Use paths to filter irrelevant changes:
on:
push:
branches: [main]
paths:
- 'src/**'
- '.github/workflows/*.yml'2. Job Configuration
Each job should have:
runs-on: Specify runner (ubuntu-latest, windows-latest, self-hosted)timeout-minutes: Prevent hung jobs (recommended: 15-30 min for CI)env: Job-level environment variablesneeds: Dependencies on other jobs
Example:
jobs:
test:
runs-on: ubuntu-latest
timeout-minutes: 20
env:
CI: true
strategy:
matrix:
node-version: [18, 20, 22]
steps:3. Matrix Strategy for Parallel Testing
Use matrices to test across multiple configurations:
strategy:
fail-fast: false # Continue all jobs even if one fails
matrix:
node-version: [18, 20, 22]
os: [ubuntu-latest, windows-latest]Advanced Matrix Patterns:
- Include specific combinations:
strategy:
matrix:
include:
- node: 20
experimental: false
- node: 21
experimental: true- Dynamic matrices based on code changes:
# Use outputs from previous jobs to adjust matrix
if: ${{ matrix.unit-test-this-shard == 'true' }}4. Caching Dependencies
Optimize build times with intelligent caching:
- name: Cache node modules
uses: actions/cache@v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ matrix.node-version }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-${{ matrix.node-version }}-Caching Best Practices:
- Cache at the job level, before dependency installation
- Use
hashFiles()for cache invalidation on lockfile changes - Include OS and runtime version in cache key to prevent conflicts
- Provide restore-keys for partial matches
5. Secrets Management
Proper secrets usage patterns:
Standard approach:
steps:
- name: Deploy with API key
env:
API_KEY: ${{ secrets.API_KEY }}
run: ./deploy.shIn matrix strategy:
strategy:
matrix:
include:
- org: apples
secret_name: APPLES_API_KEY
- org: bananas
secret_name: BANANAS_API_KEY
steps:
- env:
API_KEY: ${{ secrets[matrix.secret_name] }}Environment-level secrets: For deployment workflows, use GitHub Environments with protected secrets.
6. Permissions Configuration
Explicit permissions improve security:
permissions:
contents: read # For checkout
packages: write # For pushing container images
id-token: write # For OIDC authenticationCommon permission combinations:
- Read-only CI:
contents: read - PR with comments:
contents: read, pull-requests: write - Package publishing:
contents: write, packages: write
Debugging Workflow Failures
Common Issues & Solutions
| Problem | Diagnosis | Solution |
| Job hangs/timeout | Check timeout-minutes, add debug logging | Increase timeout or investigate infinite loops |
| Cache misses | Inspect cache key pattern | Verify hashFiles path and key structure |
| Secret not available | Check scope (repo vs env) | Use correct secrets context or environment |
| Matrix job failures | Review fail-fast setting | Set fail-fast: false for complete results |
| Permission denied | Audit permissions block | Add specific permission grants |
Debugging Techniques
1. Enable step-level debugging:
env:
ACTIONS_RUNNER_DEBUG: true
ACTIONS_STEP_DEBUG: true2. Add diagnostic steps:
- name: Debug environment
run: |
echo "GITHUB_REF: ${{ github.ref }}"
echo "Matrix value: ${{ matrix.os }}"
env | sort3. Use structured logging:
# In shell scripts
echo "::group::Setup Phase
# ... commands ...
echo ::endgroup::Workflow Validation
Use actionlint for syntax validation:
actionlint .github/workflows/*.ymlCommon linting issues:
- Missing quotes around expressions with special characters
- Incorrect action versions (use @v4 not @main)
- Permission scope mismatches
Performance Optimization
Strategies to Reduce CI Time
- Parallel jobs: Split independent test suites into parallel jobs
- Path filtering: Only run workflows on relevant file changes
- Caching: Cache dependencies, build outputs, and generated assets
- Self-hosted runners: Use faster hardware for heavy workloads
- Avoid redundant steps: Don't checkout or install if not needed
Example: Optimized Multi-Stage Pipeline
jobs:
build:
runs-on: ubuntu-latest
outputs:
artifact-path: ${{ steps.build.outputs.path }}
steps:
- uses: actions/checkout@v4
- name: Cache deps
uses: actions/cache@v4
with:
path: node_modules
key: deps-${{ hashFiles('**/package-lock.json') }}
- id: build
run: |
npm ci
npm run build
echo "path=dist/" >> $GITHUB_OUTPUT
test:
runs-on: ubuntu-latest
needs: build
steps:
- uses: actions/checkout@v4
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: build-output
- run: npm testFlakiness Mitigation
For reliable CI/CD:
- Explicit waits instead of arbitrary sleep times
- Retry logic for transient failures:
- uses: nick-fields/retry@v3
with:
timeout_minutes: 5
max_attempts: 3
command: npm test- Robust selectors in E2E tests (data-testid attributes)
- Test data isolation: Create/cleanup unique data per run
- Avoid shared state: Each job should be idempotent
Workflow Templates
Standard CI Pipeline
See assets/templates/ci-pipeline.yml for a production-ready template covering:
- Code checkout with sparse checkout option
- Dependency caching with lockfile hashing
- Matrix testing across versions
- Artifact collection and upload
- Coverage reporting integration
Multi-Environment Deployment
See assets/templates/deploy-multi-env.yml for:
- Environment-based secrets management
- Approval gates between stages
- Rollback strategies
- Health check validation
Reference Files
| File | Purpose | When to Load |
| SYNTAX_REFERENCE.md | Complete YAML schema reference | Building new workflows |
| BEST_PRACTICES.md | Industry best practices | Optimizing existing pipelines |
| TROUBLESHOOTING.md | Debug common failure modes | Diagnosing failed runs |
Scripts
Analyze Workflow Performance
Run scripts/analyze_workflow.py to:
- Identify bottlenecks in execution time
- Suggest caching opportunities
- Flag permission issues
- Detect anti-patterns
Validate Syntax
Use scripts/validate_syntax.sh to:
- Check YAML validity
- Verify action versions
- Ensure required fields present
Examples
Simple CI Pipeline
name: CI
on: [push, pull_request]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
- run: npm ci
- run: npm testMatrix Build Example
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python: ['3.9', '3.10', '3.11']
steps:
- uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
- run: pip install -r requirements.txt
- run: pytest tests/Activation Keywords
This skill activates when user mentions:
- "GitHub Actions workflow" or ".github/workflows"
- "CI/CD pipeline"
- "workflow file" or "action yml"
- "matrix build" or "parallel testing"
- "debug GitHub Actions" or "pipeline failed"
- "optimize CI time" or "cache dependencies"
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

