Menu
releaser docs

Inputs and Flags

Every action input maps to a CLI flag of the same name.

- uses: orochibraru/releaser@v1
  with:
    branch: main
    rules: ""
    prepare: ""
    commit: ""
    artifacts: ""
    docker: false
    docker-image: ""
    docker-platforms: ""
    draft: false
    prerelease: ""
    release-pr: false
    dry-run: false
    token: ${{ github.token }}
Input / flagDefaultDescription
branchmainBranch to release from. Any other branch is a no-op.
rulesBump overrides, e.g. breaking=patch,feat=patch. See Versioning.
prepareShell command run before the release commit. ${version} is replaced with the new version, e.g. 1.2.3. It doesn't see GITHUB_TOKEN or GH_TOKEN; pass what it needs under another name.
commitExtra files for the release commit, comma separated. CHANGELOG.md and package.json (when present) are always committed.
artifactsEnables artifact mode. path[=name], comma or newline separated.
dockerfalseEnables Docker mode.
docker-imageghcr.io/<owner>/<repo>Image to push.
docker-platformse.g. linux/amd64,linux/arm64.
draftfalseCreate the GitHub release as a draft, assets still attached. Publish it yourself (gh release edit).
prereleaseShip every push as X.Y.Z-<id>.N: tag and GitHub prerelease, no commit. See Canaries and release PR.
release-prfalseOpen or update a release PR instead of committing; merging it releases. See Canaries and release PR.
dry-runfalse in CIOnly print the next version and notes. The CLI defaults to true when CI is unset.
tokengithub.tokenAction only; the CLI reads GITHUB_TOKEN or GH_TOKEN. Used for the release, uploads, the release PR and the ghcr.io login.

Outputs

OutputExampleDescription
releasedtruefalse when nothing shipped, dry runs included.
version1.2.3The version released, or that a dry run would release.
tagv1.2.3Same as version, with the v.
prereleasefalsetrue when version is a prerelease (1.2.3-canary.4).
Casereleasedversion
releasedtrueset
dry run with a release pendingfalseset
nothing to release, or wrong branchfalseempty
- id: release
  uses: orochibraru/releaser@v1
- if: steps.release.outputs.released == 'true'
  run: echo "shipped ${{ steps.release.outputs.tag }}"

Environment

The CLI reads the usual Actions variables, so it behaves the same inside the action or as a plain run: step:

VariableUsed for
CIUnset → dry run by default.
GITHUB_TOKEN / GH_TOKENGitHub release, uploads, release PR, ghcr.io.
GITHUB_REF_NAMECurrent branch (falls back to git).
GITHUB_REPOSITORYowner/repo (falls back to the origin URL).
GITHUB_SERVER_URL, GITHUB_API_URLGitHub Enterprise Server.
GITHUB_ACTORghcr.io login username.
GITHUB_OUTPUTWhere the outputs above are written.

This guide lives in the project repo: edit it there, and this page follows within a day.