Merge pull request 'Publish APT packages for pre-tagged release drafts' (#257) from fix/apt-release-draft-trigger into main
Coulobre Panel CI / Checks (Python 3.12) (push) Successful in 1m44s
Coulobre Panel CI / Checks (Python 3.14) (push) Failing after 1m53s

Reviewed-on: #257
This commit was merged in pull request #257.
This commit is contained in:
parkel committed 2026-12-03 15:33:33 +01:00
commit 9356bc8dd8
2 files changed
+11 -2

No files matched your search

+6 -2
View File
@@ -2,7 +2,8 @@ name: Publish release to APT
on:
release:
types: [published]
# Gitea 28.1 reports publication of a draft with an existing tag as edited.
types: [published, edited]
workflow_dispatch:
inputs:
tag:
@@ -17,7 +18,10 @@ permissions:
jobs:
publish:
runs-on: ubuntu-latest
if: gitea.repository == 'hippogrief/coulobre'
if: >-
gitea.repository == 'hippogrief/coulobre' &&
(gitea.event_name == 'workflow_dispatch' ||
(gitea.event.release.tag_name && gitea.event.release.draft == false))
steps:
- name: Check out publication script
uses: https://github.com/actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
+5
View File
@@ -224,6 +224,11 @@ Set `APT_PUBLISH_USERNAME` and `APT_PUBLISH_TOKEN` as repository Actions
secrets. Use a dedicated registry publisher with package write access, not an
administrator's personal token. The job token is used only to read the release.
Gitea 28.1 can report publishing a draft with a pre-existing tag as a
release edit. The workflow handles both events and independently checks the
release is published before uploading. Editing an already published release
can rerun verification, but it does not replace existing packages.
For a retry or a release published before automation was enabled, run the
workflow manually and enter the published tag. A matching existing package is
accepted after its digest is checked in each APT index. A different package at