fix: expose AppImage version metadata

This commit is contained in:
nomoreshow
2026-09-06 07:14:35 +03:00
parent 4b3ae8d70b
commit 1c086199c1
2 changed files with 12 additions and 0 deletions
+1
View File
@@ -55,6 +55,7 @@ cat > "$APPDIR/dikte.desktop" <<EOF
[Desktop Entry]
Type=Application
Name=Dikte
X-AppImage-Version=$VERSION
Comment=Voice dictation: record, transcribe, clean up, paste
Exec=dikte
Icon=dikte
+11
View File
@@ -20,6 +20,17 @@ PACKAGING = ROOT / "packaging" / "whisper-vulkan"
WORKFLOW = ROOT / ".github" / "workflows" / "whisper-vulkan.yml"
class AppImagePackaging(unittest.TestCase):
def test_the_desktop_exposes_the_release_version_to_appimage_managers(self):
script = (ROOT / "packaging" / "build-appimage.sh").read_text(
encoding="utf-8")
marker = 'cat > "$APPDIR/dikte.desktop" <<EOF\n'
desktop = script.split(marker, 1)[1].split("\nEOF", 1)[0]
rendered = desktop.replace("$VERSION", "1.2.0")
self.assertEqual(
1, rendered.splitlines().count("X-AppImage-Version=1.2.0"))
class WhisperVulkanPackaging(unittest.TestCase):
@unittest.skipUnless(sys.platform != "win32" and shutil.which("bash"),
"bash syntax check is unavailable")