GitHub Action
Check out full history, select a release range, and pass one model provider. The
Action writes CHANGELOG.md by default but leaves committing and pushing to the
calling workflow.
name: Changelog
on:
workflow_dispatch:
permissions:
contents: write
jobs:
changelog:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- id: notes
uses: sparepartslabs/spareparts-changelog@v0
with:
provider: anthropic
anthropic-api-key: ${{ secrets.ANTHROPIC_API_KEY }}
from: v1.0.0
to: HEAD
title: v1.1.0
- name: Commit the changed file
if: steps.notes.outputs.repository-changed == 'true'
run: |
git config user.name github-actions[bot]
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
git add CHANGELOG.md
git commit -m "docs: update changelog"
git pushFor a GitHub Release body without changing the repository, set
write-repository: "false" and pass steps.notes.outputs.markdown to the
release step.
Inputs
| Input | Required | Default | Meaning |
|---|---|---|---|
from |
Yes | — | First revision in the release range. |
to |
No | HEAD |
Last revision in the release range. |
title |
Yes | — | Release heading and stable section identity. |
provider |
Yes | — | anthropic, openai, gemini, or vendor:model. |
instructions |
No | — | Audience, tone, terminology, emphasis, and exclusion guidance. |
changelog-path |
No | CHANGELOG.md |
File updated in repository mode. |
write-repository |
No | true |
Update the checked-out file without committing or pushing. |
Supply the matching provider secret: anthropic-api-key, openai-api-key, or
gemini-api-key. Keep API keys in GitHub Actions secrets, never repository
variables or workflow text.
Custom instructions
Instructions are editorial guidance, not a second prompt with authority over the evidence rules. For example:
instructions: >-
Write for engineering managers evaluating an upgrade. Prefer plain language,
call out removed behavior, and do not mention internal package names.Outputs
markdown: canonical generated Markdown.repository-changed: whether repository bytes changed.content-digest: stable digest of the generated artifact.repository-status,s3-status,linkedin-status: destination results.