CI: publish a fixed-URL latest AppImage for Shelly #7

Merged
jknapp merged 1 commits from ci/latest-appimage-url into main 2026-10-04 19:19:40 +00:00
Owner

Why

Shelly's static-URL mode polls one constant URL with a HEAD request and compares ETag (falling back to Last-Modified). Gitea 1.27 has no /releases/latest/download/ redirect and release URLs always contain the tag, so there was no constant URL.

What

After the versioned release is published, .gitea/scripts/update-latest.sh replaces the AppImage on a rolling pre-release tagged latest:

https://repo.anhonesthost.net/streamer-tools/whats-that-music/releases/download/latest/WhatsThatMusic-latest-linux-x86_64.AppImage

  • Pre-release, so Gitea's own "latest release" stays the newest vX.Y.Z (verified).
  • The publish job now checks out first: actions/checkout cleans the workspace and would delete the downloaded artifacts if it ran after them.

Testing

Ran the script against the live API twice (create, then replace) using the v1.0.1 CI AppImage. The URL stayed constant and the ETag changed on replace. The latest release is already seeded with v1.0.1.

Not tested: the workflow step itself, which only runs on a v* tag. First real exercise will be the next release.

🤖 Generated with Claude Code

## Why Shelly's static-URL mode polls one constant URL with a HEAD request and compares `ETag` (falling back to `Last-Modified`). Gitea 1.27 has no `/releases/latest/download/` redirect and release URLs always contain the tag, so there was no constant URL. ## What After the versioned release is published, `.gitea/scripts/update-latest.sh` replaces the AppImage on a rolling pre-release tagged `latest`: `https://repo.anhonesthost.net/streamer-tools/whats-that-music/releases/download/latest/WhatsThatMusic-latest-linux-x86_64.AppImage` - Pre-release, so Gitea's own "latest release" stays the newest `vX.Y.Z` (verified). - The publish job now checks out first: `actions/checkout` cleans the workspace and would delete the downloaded artifacts if it ran after them. ## Testing Ran the script against the live API twice (create, then replace) using the v1.0.1 CI AppImage. The URL stayed constant and the ETag changed on replace. The `latest` release is already seeded with v1.0.1. Not tested: the workflow step itself, which only runs on a `v*` tag. First real exercise will be the next release. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
jknapp added 1 commit 2026-10-04 19:17:48 +00:00
Gitea has no /releases/latest/download/ redirect and release URLs always
include the tag, so updaters that poll a constant URL (Shelly) cannot use
them. After publishing a vX.Y.Z release, replace the asset on a rolling
pre-release tagged "latest":

  .../releases/download/latest/WhatsThatMusic-latest-linux-x86_64.AppImage

Replacing the asset changes its ETag and Last-Modified, which Shelly
compares. The pre-release flag keeps Gitea's own "latest release" on the
newest vX.Y.Z. The logic lives in .gitea/scripts/update-latest.sh so it can
be run against the API outside CI. The publish job now checks out first,
since checkout cleans the workspace and would delete downloaded artifacts.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
jknapp merged commit d3a67688f8 into main 2026-10-04 19:19:40 +00:00
Sign in to join this conversation.
No Reviewers
No labels
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: streamer-tools/whats-that-music#7