@@ -22,12 +22,25 @@ jobs:
2222 - name : Build exe
2323 run : pyinstaller MusicPresence.spec --distpath dist --workpath build
2424
25- - name : Upload artifact
25+ - name : Build installer (Inno Setup)
26+ env :
27+ APP_VERSION : ${{ github.ref_name }}
28+ run : |
29+ mkdir installer\installer_output
30+ & "C:\Program Files (x86)\Inno Setup 6\ISCC.exe" installer\MusicPresence.iss
31+
32+ - name : Upload portable exe
2633 uses : actions/upload-artifact@v4
2734 with :
28- name : MusicPresence-windows
35+ name : MusicPresence-windows-portable
2936 path : dist/MusicPresence.exe
3037
38+ - name : Upload installer
39+ uses : actions/upload-artifact@v4
40+ with :
41+ name : MusicPresence-windows-setup
42+ path : installer/installer_output/MusicPresence-Setup-*.exe
43+
3144 build-linux :
3245 runs-on : ubuntu-latest
3346 steps :
@@ -47,37 +60,69 @@ jobs:
4760 libcairo2-dev \
4861 libgirepository-2.0-dev \
4962 gir1.2-appindicator3-0.1 \
50- pkg-config
63+ pkg-config \
64+ fuse \
65+ libfuse2
5166
5267 - name : Install dependencies
5368 run : pip install -r requirements-linux.txt
5469
5570 - name : Build binary
5671 run : pyinstaller MusicPresence.spec --distpath dist --workpath build
5772
58- - name : Upload artifact
73+ - name : Build AppImage
74+ env :
75+ APP_VERSION : ${{ github.ref_name }}
76+ run : |
77+ # Téléchargement appimagetool
78+ wget -q "https://github.com/AppImage/appimagetool/releases/download/continuous/appimagetool-x86_64.AppImage" -O appimagetool
79+ chmod +x appimagetool
80+
81+ # Structure AppDir
82+ mkdir -p AppDir/usr/bin
83+ cp dist/MusicPresence AppDir/usr/bin/MusicPresence
84+ chmod +x AppDir/usr/bin/MusicPresence
85+
86+ # Icône
87+ cp assets/icon.png AppDir/MusicPresence.png
88+
89+ # .desktop
90+ cp installer/MusicPresence.desktop AppDir/MusicPresence.desktop
91+
92+ # AppRun
93+ cat > AppDir/AppRun << 'EOF'
94+ #!/bin/bash
95+ SELF=$(readlink -f "$0")
96+ HERE="${SELF%/*}"
97+ exec "$HERE/usr/bin/MusicPresence" "$@"
98+ EOF
99+ chmod +x AppDir/AppRun
100+
101+ # Build AppImage
102+ ARCH=x86_64 ./appimagetool AppDir MusicPresence-$APP_VERSION-x86_64.AppImage
103+
104+ - name : Upload binary
59105 uses : actions/upload-artifact@v4
60106 with :
61- name : MusicPresence-linux
107+ name : MusicPresence-linux-binary
62108 path : dist/MusicPresence
63109
110+ - name : Upload AppImage
111+ uses : actions/upload-artifact@v4
112+ with :
113+ name : MusicPresence-linux-appimage
114+ path : MusicPresence-*.AppImage
115+
64116 release :
65117 needs : [build-windows, build-linux]
66118 runs-on : ubuntu-latest
67119 permissions :
68120 contents : write
69121 steps :
70- - name : Download Windows artifact
71- uses : actions/download-artifact@v4
72- with :
73- name : MusicPresence-windows
74- path : artifacts/windows
75-
76- - name : Download Linux artifact
122+ - name : Download all artifacts
77123 uses : actions/download-artifact@v4
78124 with :
79- name : MusicPresence-linux
80- path : artifacts/linux
125+ path : artifacts
81126
82127 - name : Create GitHub Release
83128 uses : softprops/action-gh-release@v2
@@ -87,10 +132,20 @@ jobs:
87132 ## Installation
88133
89134 ### Windows
90- Télécharge `MusicPresence.exe`, place ton `.env` dans le même dossier et lance l'exe.
135+ | Fichier | Description |
136+ |---|---|
137+ | `MusicPresence-Setup-*.exe` | Installeur (recommandé) |
138+ | `MusicPresence.exe` | Portable, sans installation |
91139
92140 ### Linux
93- Télécharge `MusicPresence`, rends-le exécutable (`chmod +x MusicPresence`), place ton `.env` dans le même dossier et lance-le.
141+ | Fichier | Description |
142+ |---|---|
143+ | `MusicPresence-*-x86_64.AppImage` | AppImage universel |
144+ | `MusicPresence` | Binaire portable |
145+
146+ > Placez votre fichier `.env` dans le même dossier que l'exécutable.
94147 files : |
95- artifacts/windows/MusicPresence.exe
96- artifacts/linux/MusicPresence
148+ artifacts/MusicPresence-windows-setup/MusicPresence-Setup-*.exe
149+ artifacts/MusicPresence-windows-portable/MusicPresence.exe
150+ artifacts/MusicPresence-linux-appimage/MusicPresence-*.AppImage
151+ artifacts/MusicPresence-linux-binary/MusicPresence
0 commit comments