Skip to content

make github-release: refuse to re-release a commit that is already tagged #177

Description

@regnull

Goal

Make make github-release refuse to publish a commit that already has a release tag.

Context

scripts/github-release.sh works out the next vX.Y.N from existing tags, so running it twice on the same main commit publishes two releases with identical contents (for example v0.1.1 and v0.1.2). It already checks that the new tag doesn't exist, but not whether HEAD is already released.

A check such as git tag --points-at HEAD filtered to v*.*.* would catch this. It should stop with a clear message for a real release and only warn under DRY_RUN=1, like the script's other check calls.

Acceptance criteria

  • A second real release of an already-tagged HEAD stops with a message naming the existing tag
  • DRY_RUN=1 warns instead of stopping
  • The Releasing to GitHub steps in the README mention the new check

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions