Skip to content

Commit a2be03c

Browse files
committed
Generate Linux binaries on releases (only tar.gz, no installer)
1 parent cf0f1db commit a2be03c

File tree

6 files changed

+72
-21
lines changed

6 files changed

+72
-21
lines changed
Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
name: Generate Linux Packages
2+
3+
on:
4+
release:
5+
types: [ published ]
6+
7+
permissions:
8+
contents: write
9+
10+
jobs:
11+
generate-windows-installer:
12+
name: Generate Linux Packages
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- name: Git Checkout ${{github.event.release.tag_name}}
17+
uses: actions/checkout@v6
18+
19+
- name: Set up Python
20+
uses: actions/setup-python@v6
21+
with:
22+
python-version: '3.14'
23+
24+
- name: Install dependencies
25+
run: |
26+
python -m pip install --upgrade pip
27+
python -m pip install -r requirements.txt
28+
29+
- name: Run PyInstaller to create binaries
30+
run: |
31+
pyinstaller --noconfirm turing-system-monitor.spec
32+
echo "${{github.event.release.tag_name}}" > ./dist/turing-system-monitor/version.txt
33+
ln -s configure ./dist/turing-system-monitor/turing-smart-screen
34+
35+
- name: Create archive from generated binaries
36+
run: |
37+
rm -rf "./dist/turing-system-monitor/res/themes/--Theme examples"
38+
tar -czvf "turing-system-monitor-${{github.event.release.tag_name}}-linux.tar.gz" -C "./dist/turing-system-monitor/" .
39+
40+
- name: '📦 Archive Linux binaries'
41+
uses: actions/upload-artifact@v7
42+
with:
43+
name: turing-system-monitor-${{github.event.release.tag_name}}-linux
44+
path: turing-system-monitor-${{github.event.release.tag_name}}-linux.tar.gz
45+
if-no-files-found: error
46+
47+
- name: '📩 Publish Linux binaries to Release'
48+
run: |
49+
gh release upload ${{github.event.release.tag_name}} turing-system-monitor-${{github.event.release.tag_name}}-linux.tar.gz
50+
env:
51+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/generate-windows-packages-debug.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -44,30 +44,30 @@ jobs:
4444
- name: Create portable zip archive from generated binaries
4545
run: |
4646
Remove-Item -r ".\dist\turing-system-monitor\res\themes\--Theme examples\"
47-
7z a -tzip turing-system-monitor-${{github.event.release.tag_name}}-portable-debug.zip ".\dist\turing-system-monitor"
47+
7z a -tzip turing-system-monitor-${{github.event.release.tag_name}}-debug-portable-windows.zip ".\dist\turing-system-monitor"
4848
4949
- name: '📦 Archive Windows installer'
5050
uses: actions/upload-artifact@v7
5151
with:
52-
name: turing-system-monitor-${{github.event.release.tag_name}}-debug
53-
path: tools\windows-installer\Output\turing-system-monitor-${{github.event.release.tag_name}}-debug.exe
52+
name: turing-system-monitor-${{github.event.release.tag_name}}-debug-windows
53+
path: tools\windows-installer\Output\turing-system-monitor-${{github.event.release.tag_name}}-debug-windows.exe
5454
if-no-files-found: error
5555

5656
- name: '📦 Archive Windows portable archive'
5757
uses: actions/upload-artifact@v7
5858
with:
59-
name: turing-system-monitor-${{github.event.release.tag_name}}-portable-debug
60-
path: turing-system-monitor-${{github.event.release.tag_name}}-portable-debug.zip
59+
name: turing-system-monitor-${{github.event.release.tag_name}}-debug-portable-windows
60+
path: turing-system-monitor-${{github.event.release.tag_name}}-debug-portable-windows.zip
6161
if-no-files-found: error
6262

6363
- name: '📩 Publish Windows installer to Release'
6464
run: |
65-
gh release upload ${{github.event.release.tag_name}} tools\windows-installer\Output\turing-system-monitor-${{github.event.release.tag_name}}-debug.exe
65+
gh release upload ${{github.event.release.tag_name}} tools\windows-installer\Output\turing-system-monitor-${{github.event.release.tag_name}}-debug-windows.exe
6666
env:
6767
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6868

6969
- name: '📩 Publish Windows portable zip to Release'
7070
run: |
71-
gh release upload ${{github.event.release.tag_name}} turing-system-monitor-${{github.event.release.tag_name}}-portable-debug.zip
71+
gh release upload ${{github.event.release.tag_name}} turing-system-monitor-${{github.event.release.tag_name}}-debug-portable-windows.zip
7272
env:
7373
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/generate-windows-packages.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -44,30 +44,30 @@ jobs:
4444
- name: Create portable zip archive from generated binaries
4545
run: |
4646
Remove-Item -r ".\dist\turing-system-monitor\res\themes\--Theme examples\"
47-
7z a -tzip turing-system-monitor-${{github.event.release.tag_name}}-portable.zip ".\dist\turing-system-monitor"
47+
7z a -tzip turing-system-monitor-${{github.event.release.tag_name}}-portable-windows.zip ".\dist\turing-system-monitor"
4848
4949
- name: '📦 Archive Windows installer'
5050
uses: actions/upload-artifact@v7
5151
with:
52-
name: turing-system-monitor-${{github.event.release.tag_name}}
53-
path: tools\windows-installer\Output\turing-system-monitor-${{github.event.release.tag_name}}.exe
52+
name: turing-system-monitor-${{github.event.release.tag_name}}-windows
53+
path: tools\windows-installer\Output\turing-system-monitor-${{github.event.release.tag_name}}-windows.exe
5454
if-no-files-found: error
5555

5656
- name: '📦 Archive Windows portable archive'
5757
uses: actions/upload-artifact@v7
5858
with:
59-
name: turing-system-monitor-${{github.event.release.tag_name}}-portable
60-
path: turing-system-monitor-${{github.event.release.tag_name}}-portable.zip
59+
name: turing-system-monitor-${{github.event.release.tag_name}}-portable-windows
60+
path: turing-system-monitor-${{github.event.release.tag_name}}-portable-windows.zip
6161
if-no-files-found: error
6262

6363
- name: '📩 Publish Windows installer to Release'
6464
run: |
65-
gh release upload ${{github.event.release.tag_name}} tools\windows-installer\Output\turing-system-monitor-${{github.event.release.tag_name}}.exe
65+
gh release upload ${{github.event.release.tag_name}} tools\windows-installer\Output\turing-system-monitor-${{github.event.release.tag_name}}-windows.exe
6666
env:
6767
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6868

6969
- name: '📩 Publish Windows portable zip to Release'
7070
run: |
71-
gh release upload ${{github.event.release.tag_name}} turing-system-monitor-${{github.event.release.tag_name}}-portable.zip
71+
gh release upload ${{github.event.release.tag_name}} turing-system-monitor-${{github.event.release.tag_name}}-portable-windows.zip
7272
env:
7373
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

tools/windows-installer/turing-system-monitor.iss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ AppSupportURL={#MyAppURL}/wiki
2222
AppUpdatesURL={#MyAppURL}/releases
2323
DefaultDirName={autopf}\{#MyAppName}
2424
DefaultGroupName={#MyAppName}
25-
OutputBaseFilename=turing-system-monitor-{#MyAppVersion}
25+
OutputBaseFilename=turing-system-monitor-{#MyAppVersion}-windows
2626
AllowNoIcons=yes
2727
PrivilegesRequired=lowest
2828
Compression=lzma

turing-system-monitor-debug.spec

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ configure_a = Analysis(
77
pathex=[],
88
binaries=[],
99
datas=[('res', 'res'), ('config.yaml', '.'), ('external', 'external')],
10-
hiddenimports=[],
10+
hiddenimports=['PIL', 'PIL._imagingtk', 'PIL._tkinter_finder'],
1111
hookspath=[],
1212
hooksconfig={},
1313
runtime_hooks=[],
@@ -45,7 +45,7 @@ main_a = Analysis(
4545
pathex=[],
4646
binaries=[],
4747
datas=[('res', 'res'), ('config.yaml', '.'), ('external', 'external')],
48-
hiddenimports=[],
48+
hiddenimports=['PIL', 'PIL._imagingtk', 'PIL._tkinter_finder'],
4949
hookspath=[],
5050
hooksconfig={},
5151
runtime_hooks=[],
@@ -83,7 +83,7 @@ editor_a = Analysis(
8383
pathex=[],
8484
binaries=[],
8585
datas=[('res', 'res'), ('config.yaml', '.'), ('external', 'external')],
86-
hiddenimports=[],
86+
hiddenimports=['PIL', 'PIL._imagingtk', 'PIL._tkinter_finder'],
8787
hookspath=[],
8888
hooksconfig={},
8989
runtime_hooks=[],

turing-system-monitor.spec

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ configure_a = Analysis(
77
pathex=[],
88
binaries=[],
99
datas=[('res', 'res'), ('config.yaml', '.'), ('external', 'external')],
10-
hiddenimports=[],
10+
hiddenimports=['PIL', 'PIL._imagingtk', 'PIL._tkinter_finder'],
1111
hookspath=[],
1212
hooksconfig={},
1313
runtime_hooks=[],
@@ -45,7 +45,7 @@ main_a = Analysis(
4545
pathex=[],
4646
binaries=[],
4747
datas=[('res', 'res'), ('config.yaml', '.'), ('external', 'external')],
48-
hiddenimports=[],
48+
hiddenimports=['PIL', 'PIL._imagingtk', 'PIL._tkinter_finder'],
4949
hookspath=[],
5050
hooksconfig={},
5151
runtime_hooks=[],
@@ -83,7 +83,7 @@ editor_a = Analysis(
8383
pathex=[],
8484
binaries=[],
8585
datas=[('res', 'res'), ('config.yaml', '.'), ('external', 'external')],
86-
hiddenimports=[],
86+
hiddenimports=['PIL', 'PIL._imagingtk', 'PIL._tkinter_finder'],
8787
hookspath=[],
8888
hooksconfig={},
8989
runtime_hooks=[],

0 commit comments

Comments
 (0)