mirror of
https://github.com/yusufipk/dikte.git
synced 2026-09-11 10:56:10 +00:00
fix: expose AppImage version metadata
This commit is contained in:
@@ -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
|
||||
|
||||
@@ -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")
|
||||
|
||||
Reference in New Issue
Block a user