github-actions

GitHub Actions CI/CD workflows with reusable actions. Use for GitHub automation.

7 stars

Best use case

github-actions is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

GitHub Actions CI/CD workflows with reusable actions. Use for GitHub automation.

Teams using github-actions should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/github-actions/SKILL.md --create-dirs "https://raw.githubusercontent.com/G1Joshi/Agent-Skills/main/skills/devops/github-actions/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/github-actions/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How github-actions Compares

Feature / Agentgithub-actionsStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

GitHub Actions CI/CD workflows with reusable actions. Use for GitHub automation.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# GitHub Actions

GitHub Actions is the CI/CD platform native to GitHub. In 2025, it is the dominant CI/CD tool, characterized by **Reusable Workflows** and **OIDC** integration for passwordless deployments.

## When to Use

- **GitHub-Hosted**: Your code is already on GitHub. Deep integration with Issues/PRs.
- **Simplicity**: No servers to manage (unlike Jenkins).
- **Marketplace**: Thousands of pre-built actions (setup-node, docker-build-push).

## Quick Start

```yaml
# .github/workflows/ci.yml
name: CI
on: [push, pull_request]

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-node@v4
        with:
          node-version: "20"
      - run: npm ci
      - run: npm test
```

## Core Concepts

### Workflows

Defined in `.github/workflows/*.yml`. Triggered by events (`push`, `release`, `schedule`).

### Runners

Virtual machines (Ubuntu/Windows/MacOS) that run your jobs. You can also host **Self-Hosted Runners** for cheaper/faster builds in your VPC.

### Actions

Reusable steps. `actions/checkout` is an action. You can write your own in JS or Docker.

## Best Practices (2025)

**Do**:

- **Use Reusable Workflows**: Define a standard "Deploy to Prod" workflow in one repo, and call it from 50 microservices.
- **Use OIDC**: Authenticate to AWS/Azure/GCP using `permissions: id-token: write` instead of long-lived secrets.
- **Pin Actions**: Use `actions/checkout@v4` or a specific SHA for immutability.

**Don't**:

- **Don't hardcode secrets**: Use Repository Secrets or Environment Secrets.
- **Don't write huge shell scripts**: If a step is >10 lines of bash, move it to a script file or a custom Action.

## References

- [GitHub Actions Documentation](https://docs.github.com/en/actions)