Guidelines for agentic coding agents operating in this repository.
This is a GitHub Actions Composite Action template. The main file is action.yml.
- Language: YAML (GitHub Actions)
- Package Manager: None
- Testing: GitHub Actions workflows
Tests run via GitHub Actions. The test workflow (.github/workflows/test.yml) runs on:
pusheventspull_requestevents
Tests on multiple OSes: ubuntu-latest, macos-latest, windows-latest.
act -W .github/workflows/test.ymlAutomated via .github/workflows/release-please.yml:
- Triggered on push to
masterbranch - Uses "simple" release type
- Creates semantic version tags
- Keep it simple: Minimal composite action template
- YAML format: 2-space indentation
- Descriptive names: Clear names for inputs, steps, and jobs
Required: Use Conventional Commits format:
<type>(<scope>): <description>
Types: fix, feat, docs, chore, refactor, test
Examples:
feat: add new input parameter
fix: resolve issue with default value
docs: update README
- 2-space indentation
- Hyphen
-for list items - Quote strings with special characters
- Use anchor aliases (
&anchor,*alias) for reusable fragments
name: <action-name>
description: <description>
author: <username>
inputs:
<input-name>:
description: <description>
required: false
default: <value>
runs:
using: composite
steps:
- name: <step-name>
uses: <action>
with:
<key>: <value>
shell: bash
run: |
<commands>
env:
<VAR>: ${{ inputs.<input> }}
branding:
icon: <icon-name>
color: <color>- Action name: kebab-case
- Input names: kebab-case
- Step names: Title case
- Job names: kebab-case
- Environment variables: SCREAMING_SNAKE_CASE
- Always specify
permissions(principle of least privilege) - Use pinned action versions (e.g.,
actions/checkout@v6) - Use
with:for inputs instead of environment variables - Set
continue-on-error: falseexplicitly - Use
id:on steps when referencing outputs
- Steps fail on errors by default
- Use
if: ${{ always() }}orif: ${{ failure() }}when continuing is needed - Check for required inputs
.
├── action.yml
├── .github/workflows/
│ ├── test.yml
│ ├── commitlint.yml
│ └── release-please.yml
├── README.md
├── LICENSE
└── version.txt
- Add to
inputs:inaction.yml - Add
with:in steps using it - Update
README.mdwith documentation
Add a step in .github/workflows/test.yml:
- name: Run action with <scenario>
uses: ./
with:
<input>: <value>Update action versions in .github/workflows/*.yml and .github/dependabot.yml.