Skip to content
Latchkey

How to Publish an Action to the Marketplace on Release in GitHub Actions

Publishing an Action means tagging a release and keeping a floating major tag (for example v1) pointing at it so consumers can pin to either.

On a version tag push, create the release, then force-update the major tag (v1) to the same commit so uses: owner/action@v1 resolves to the latest patch.

Steps

  • Publish the Action listing once from the release UI (manual, one time).
  • On each vX.Y.Z tag, create the GitHub Release.
  • Move the vX major tag to the new commit and force-push it.

Workflow

.github/workflows/release.yml
on:
  push:
    tags: ['v*.*.*']
permissions:
  contents: write
jobs:
  release:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: softprops/action-gh-release@v2
        with:
          generate_release_notes: true
      - run: |
          MAJOR="${GITHUB_REF_NAME%%.*}"
          git tag -f "$MAJOR"
          git push -f origin "$MAJOR"

Gotchas

  • The first Marketplace publish is a manual step in the release UI; the workflow handles later versions.
  • A valid action.yml with name, description, and branding is required to list on the Marketplace.

Related guides

Run this faster and cheaper on Latchkey managed runners. Start free →