From 0403a8cb5ae1c30bbd1859000085fcc80b52fa0a Mon Sep 17 00:00:00 2001 From: "Nabeel S." <99736+nabeelio@users.noreply.github.com> Date: Mon, 16 Nov 2026 13:07:30 -0600 Subject: [PATCH] ci(release): publish stable.zip only from a release Mirror main: a push to releases/2.0 now writes scripts/releases-2.0.zip, a preview Replane can point a 2.x channel at. Only the release job (workflow_dispatch: bump, tag, GitHub release) writes scripts/stable.zip, the file every 2.x client downloads. Start the package version at 2.0.0 so releases tag as v2.0.x. --- .github/workflows/distribute.yml | 16 ++++++++++++++-- src/package.json | 2 +- 2 files changed, 15 insertions(+), 3 deletions(-) diff --git a/.github/workflows/distribute.yml b/.github/workflows/distribute.yml index 8df064d..cc47f67 100644 --- a/.github/workflows/distribute.yml +++ b/.github/workflows/distribute.yml @@ -78,7 +78,17 @@ jobs: # AWS CLI v2.23+ sends checksum headers many S3-compatible stores reject AWS_REQUEST_CHECKSUM_CALCULATION: when_required run: | - aws s3 cp stable.zip s3://acars/scripts/stable.zip \ + # A merge to releases/2.0 publishes releases-2.0.zip, which Replane can point a + # 2.x channel at to test unreleased scripts. Only a release tag replaces + # stable.zip, the file every 2.x client downloads by default + # (https://acars.cdn.vmslabs.net/scripts/stable.zip). + if [[ "$GITHUB_REF" == refs/tags/v* ]]; then + ZIP_NAME="stable.zip" + else + ZIP_NAME="releases-2.0.zip" + fi + + aws s3 cp stable.zip "s3://acars/scripts/${ZIP_NAME}" \ --endpoint-url https://ny-s3.storage.bunnycdn.com # Same purge the acars release runs (build/release/deploy.mjs postdeploy): the pull zone @@ -96,7 +106,9 @@ jobs: -H "AccessKey: $BUNNY_API_KEY" # - # Manually triggered: bump the version, tag it, and publish a GitHub release + # Manually triggered: bump the version, tag it, publish scripts/stable.zip (what every + # 2.x client downloads) and create a GitHub release. This is the only path that + # writes stable.zip; branch pushes above only write releases-2.0.zip. # release: name: 'Create GitHub release' diff --git a/src/package.json b/src/package.json index aea85d5..da2a448 100644 --- a/src/package.json +++ b/src/package.json @@ -1,6 +1,6 @@ { "name": "acars-default", - "version": "1.0.1", + "version": "2.0.0", "type": "module", "config": { "aircraft": {