Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

github-actions

БесплатноБез исполняемых скриптовНе проверен

GitHub Actions CI/CD. Covers workflows, jobs, and deployment. Use for automating builds, tests, and deployments. USE WHEN: user mentions "github actions"…

claude-dev-suiteот claude-dev-suite★ 51 звезда на GitHub

Об этом скилле

GitHub Actions Core Knowledge

Deep Knowledge: Use mcp__documentation__fetch_docs with technology: github-actions for comprehensive documentation.

Basic CI Workflow

# .github/workflows/ci.yml
name: CI

on:
  push:
    branches: [main]
  pull_request:
    branches: [main]

jobs:
  test:
    runs-on: ubuntu-latest

    steps:
      - uses: actions/checkout@v4

      - name: Setup Node.js
        uses: actions/setup-node@v4
        with:
          node-version: '20'
          cache: 'npm'

      - name: Install dependencies
        run: npm ci

      - name: Run linter
        run: npm run lint

      - name: Run tests
        run: npm test

      - name: Build
        run: npm run build

With Database

jobs:
  test:
    runs-on: ubuntu-latest

    services:
      postgres:
        image: postgres:16
        env:
          POSTGRES_USER: test
          POSTGRES_PASSWORD: test
          POSTGRES_DB: testdb
        ports:
          - 5432:5432
        options: >-
          --health-cmd pg_isready
          --health-interval 10s
          --health-timeout 5s
          --health-retries 5

    env:
      DATABASE_URL: postgresql://test:test@localhost:5432/testdb

    steps:
      - uses: actions/checkout@v4
      - run: npm ci
      - run: npx prisma migrate deploy
      - run: npm test

Deploy Workflow

name: Deploy

on:
  push:
    branches: [main]

jobs:
  deploy:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4

      - name: Deploy to Vercel
        uses: amondnet/vercel-action@v25
        with:
          vercel-token: ${{ secrets.VERCEL_TOKEN }}
          vercel-org-id: ${{ secrets.VERCEL_ORG_ID }}
          vercel-project-id: ${{ secrets.VERCEL_PROJECT_ID }}
          vercel-args: '--prod'

Matrix Strategy

jobs:
  test:
    strategy:
      matrix:
        node: [18, 20, 22]
        os: [ubuntu-latest, macos-latest]
    runs-on: ${{ matrix.os }}
    steps:
      - uses: actions/setup-node@v4
        with:
          node-version: ${{ matrix.node }}

Reusable Workflows

# .github/workflows/test.yml
on:
  workflow_call:

jobs:
  test:
    runs-on: ubuntu-latest
    steps: [...]

# Usage in another workflow
jobs:
  call-tests:
    uses: ./.github/workflows/test.yml

When NOT to Use This Skill

Skip this skill when:

  • Using GitLab CI/CD (.gitlab-ci.yml) - different syntax
  • Using Jenkins, CircleCI, Travis CI - different platforms
  • Setting up local development environments - use docker-compose skill
  • Building Docker images only (no CI needed) - use docker skill
  • Working with Bitbucket Pipelines - different platform

Anti-Patterns

Anti-Pattern Problem Solution
No permission restrictions Security risk, excessive access Set minimal permissions: per job
Using action tags like @v1 Breaking changes on updates Pin to SHA: @60edb5dd545a775178f52524783378180af0d1f8
Secrets in logs Credential exposure Never echo secrets, use env: only
No timeout set Runaway jobs consuming minutes Set timeout-minutes: 15 on jobs
Caching nothing Slow builds, wasted time Cache dependencies with actions/cache
Running on every commit Wasted CI minutes Use paths: filters or pull_request: only
Hardcoded versions Inconsistent environments Use matrix strategy or env vars
No artifact retention limit High storage costs Set retention-days: 7 on artifacts
Storing secrets in code Security breach Use GitHub Secrets, never commit
No branch protection Bypassing CI checks Require status checks in branch rules

Quick Troubleshooting

Issue Diagnosis Fix
Workflow doesn't trigger Wrong event, branch filter Check on: triggers and branch names
Job fails silently Script errors ignored Don't use `
Cache never hits Cache key changing Use stable keys: hashFiles('**/package-lock.json')
"Resource not accessible" Wrong permissions Add required permissions: to job
Secrets not available in PR Forks don't have access Use pull_request_target (carefully) or skip secret steps
Artifact upload fails Path doesn't exist Check build output path, use if: always()
Matrix job failures One config fails all Use fail-fast: false to continue other jobs
Workflow takes too long No caching, sequential jobs Add caching, parallelize with needs:
"Context access might be invalid" Wrong context syntax Use ${{ }} syntax, check context availability
Can't trigger another workflow No token permission Use PAT or GITHUB_TOKEN with write permissions

Production Readiness

Security Best Practices

# Secure workflow
name: CI

on:
  push:
    branches: [main]
  pull_request:
    branches: [main]

permissions:
  contents: read
  pull-requests: write

jobs:
  build:
Полный SKILL.md на GitHub

Установить github-actions в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Read
Grep
Glob
Write
Edit

Вложенные файлы

quick-ref/actions.mdquick-ref/workflows.md

FAQ

Что делает скилл github-actions?

GitHub Actions CI/CD. Covers workflows, jobs, and deployment. Use for automating builds, tests, and deployments. USE WHEN: user mentions "github actions", "workflow", "ci/cd", ".github/workflows", "actions/checkout", "github workflow", asks about "automate tests", "deploy on push", "build pipeline", "ci pipeline", "continuous integration", "github automation" DO NOT USE FOR: GitLab CI/CD - different syntax and features, Jenkins pipelines - different tool, Container orchestration - use `docker` or `kubernetes` skills, Local builds - workflows run on GitHub runners

Как установить скилл github-actions?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл github-actions запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить github-actions с