Skip to content

Restrict pypi-publish workflow to version tags only#27

Merged
digreatbrian merged 3 commits intomainfrom
copilot/deploy-on-tags-only
Feb 16, 2026
Merged

Restrict pypi-publish workflow to version tags only#27
digreatbrian merged 3 commits intomainfrom
copilot/deploy-on-tags-only

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Feb 16, 2026

The pypi-publish.yml workflow could be manually triggered on any branch, bypassing tag-based version control. This change enforces tag-only deployment for all trigger types.

Changes

  • Added explicit tag trigger: Workflow now triggers on push: tags: ["v*.*.*"] in addition to existing triggers
  • Updated job conditional: All three trigger types now validate tag presence:
    • push: Checks startsWith(github.ref, 'refs/tags/v')
    • workflow_dispatch: Checks startsWith(github.ref, 'refs/tags/v')
    • workflow_run: Checks startsWith(github.event.workflow_run.head_branch, 'v')

The workflow can still be triggered manually or automatically after TestPyPI completion, but only when running against a version tag.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI and others added 2 commits February 16, 2026 18:40
Co-authored-by: digreatbrian <119015367+digreatbrian@users.noreply.github.com>
Co-authored-by: digreatbrian <119015367+digreatbrian@users.noreply.github.com>
Copilot AI changed the title [WIP] Update deployment configuration for tags only Restrict pypi-publish workflow to version tags only Feb 16, 2026
Copilot AI requested a review from digreatbrian February 16, 2026 18:44
@digreatbrian digreatbrian marked this pull request as ready for review February 16, 2026 18:45
@digreatbrian digreatbrian merged commit 006c78f into main Feb 16, 2026
4 checks passed
@digreatbrian digreatbrian deleted the copilot/deploy-on-tags-only branch February 16, 2026 18:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants