Skip to content

Commit a863ab0

Browse files
authored
Tauri bundles: rename file output to betaflight-app (betaflight#5071)
* Override Tauri bundle filename to betaflight-app Keeps the OS-level display name as "Betaflight App" but writes deb/rpm/AppImage/dmg/nsis bundles as betaflight-app-<version>-... so download URLs don't carry an encoded space. * Inject pre-release tag and commit SHA into desktop bundle filenames Aligns the Tauri bundle filenames with the APK pattern. After Tauri builds, the staging step rewrites e.g. 2026.6.0 → 2026.6.0-alpha-<sha8> in each bundle name, so a deb lands as betaflight-app_2026.6.0-alpha- f70ad2df_amd64.deb and an rpm as betaflight-app-2026.6.0-alpha- f70ad2d-1.x86_64.rpm. Also point the downloads page header at the canonical Betaflight logo SVG hosted on betaflight.com instead of bundling a local copy.
1 parent 410de9b commit a863ab0

4 files changed

Lines changed: 16 additions & 3 deletions

File tree

.github/workflows/tauri-nightly.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,9 @@ jobs:
131131
132132
- name: Stage desktop bundles
133133
shell: bash
134+
env:
135+
PKG_VERSION: ${{ needs.prepare.outputs.version }}
136+
COMMIT_SHA: ${{ needs.prepare.outputs.commit_sha }}
134137
run: |
135138
mkdir -p staging
136139
shopt -s nullglob
@@ -152,6 +155,16 @@ jobs:
152155
echo "No desktop bundles produced for ${{ matrix.label }}" >&2
153156
exit 1
154157
fi
158+
STRIPPED="${PKG_VERSION%%-*}"
159+
SHA_SHORT="${COMMIT_SHA:0:8}"
160+
NIGHTLY_VERSION="${PKG_VERSION}-${SHA_SHORT}"
161+
for f in staging/*; do
162+
base=$(basename "$f")
163+
new=${base/${STRIPPED}/${NIGHTLY_VERSION}}
164+
if [[ "$new" != "$base" ]]; then
165+
mv -- "$f" "staging/${new}"
166+
fi
167+
done
155168
ls -la staging
156169
157170
- name: Sync desktop bundles to R2

scripts/generate-downloads-index.mjs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
* Inputs:
66
* --manifest <path> JSON manifest of today's nightly artefact URLs (R2)
77
* --releases <path> JSON file with the GitHub releases payload (output of `gh api releases`)
8-
* --output <dir> Output directory; index.html, logo.svg and favicon.png are written here
8+
* --output <dir> Output directory; index.html and favicon.png are written here
99
* --master-url <url> URL to the master branch web app deploy
1010
* --release-url <url> URL to the release web app (default: https://app.betaflight.com)
1111
*
@@ -282,7 +282,6 @@ try {
282282
writeFileSync(join(outputDir, "index.html"), html);
283283

284284
const repoRoot = resolve(__dirname, "..");
285-
copyFileSync(join(repoRoot, "src/images/dark-wide-2-compact.svg"), join(outputDir, "logo.svg"));
286285
copyFileSync(join(repoRoot, "src-tauri/icons/bf_icon_128.png"), join(outputDir, "favicon.png"));
287286

288287
console.log(`Wrote ${join(outputDir, "index.html")}`);

scripts/templates/downloads-index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@
164164
</head>
165165
<body>
166166
<header>
167-
<img src="logo.svg" alt="Betaflight" />
167+
<img src="https://betaflight.com/img/betaflight/logo_dark.svg" alt="Betaflight" />
168168
<h1>Downloads</h1>
169169
</header>
170170
<main>

src-tauri/tauri.conf.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@
3030
},
3131
"bundle": {
3232
"active": true,
33+
"fileName": "betaflight-app",
3334
"targets": [
3435
"deb",
3536
"rpm",

0 commit comments

Comments
 (0)