@@ -40,14 +40,14 @@ jobs:
4040
4141 - name : Install dependencies and PyInstaller
4242 run : |
43- pip install -r requirements.txt pyinstaller>=6.0.0 -U
43+ pip install -r requirements.txt
44+ pip install pyinstaller>=6.0.0 -U
4445 pip install pyinstaller-hooks-contrib>=2023.0 -U
45- pip install upx>=4.0.0 -U
4646
4747 # Download UPX for better compression
4848 - name : Download UPX
4949 run : |
50- $upxVersion = "4.2.1 "
50+ $upxVersion = "5.0.0 "
5151 Invoke-WebRequest -Uri "https://github.com/upx/upx/releases/download/v$upxVersion/upx-$upxVersion-win64.zip" -OutFile "upx.zip"
5252 Expand-Archive -Path "upx.zip" -DestinationPath "."
5353 Move-Item -Path "upx-$upxVersion-win64\upx.exe" -Destination "upx.exe"
6060 echo "VERSION=$version" >> $env:GITHUB_OUTPUT
6161 echo "Version extracted: $version"
6262
63- - name : Build ${{ matrix.name }}
64- run : >
65- pyinstaller -y -F ${{ matrix.mode }}
66- -i "extra/DUCE-LOGO.ico"
67- --clean
68- --upx-dir="./"
69- --name "${{ matrix.name }}"
70- --add-data "base.py;."
71- --add-data "colors.py;."
72- --add-data "default-duce-${{ matrix.script }}-settings.json;."
73- --add-data "README.md;."
74- --add-data "LICENSE;."
75- --exclude-module tkinter
76- --exclude-module matplotlib
77- --exclude-module PyQt5
78- --exclude-module numpy
79- --version-file="version-info.txt"
80- "${{ matrix.script }}.py"
81- env :
82- VERSION : ${{ steps.extract_version.outputs.VERSION }}
83-
8463 # Create version info file dynamically
8564 - name : Create version info file
8665 run : |
11089 StringStruct(u'FileDescription', u'Discounted Udemy Course Enroller'),
11190 StringStruct(u'FileVersion', u'$version'),
11291 StringStruct(u'InternalName', u'Discounted-Udemy-Course-Enroller'),
113- StringStruct(u'LegalCopyright', u'Copyright (c) 2023 techtanic'),
92+ StringStruct(u'LegalCopyright', u'Copyright (c) 2025 techtanic'),
11493 StringStruct(u'OriginalFilename', u'${{ matrix.name }}.exe'),
11594 StringStruct(u'ProductName', u'DUCE'),
11695 StringStruct(u'ProductVersion', u'$version')])
@@ -120,6 +99,32 @@ jobs:
12099 )
121100 "@ | Out-File -FilePath "version-info.txt" -Encoding utf8
122101
102+ - name : Build ${{ matrix.name }}
103+ run : >
104+ pyinstaller -y -F ${{ matrix.mode }}
105+ -i "extra/DUCE-LOGO.ico"
106+ --clean
107+ --upx-dir="./"
108+ --upx-args="--best --lzma --compress-icons=2"
109+ --name "${{ matrix.name }}"
110+ --add-data "base.py;."
111+ --add-data "colors.py;."
112+ --add-data "default-duce-${{ matrix.script }}-settings.json;."
113+ --add-data "README.md;."
114+ --add-data "LICENSE;."
115+ --exclude-module tkinter
116+ --exclude-module matplotlib
117+ --exclude-module PyQt5
118+ --exclude-module numpy
119+ --exclude-module wx
120+ --exclude-module scipy
121+ --exclude-module PIL
122+ --exclude-module pandas
123+ --version-file="version-info.txt"
124+ "${{ matrix.script }}.py"
125+ env :
126+ VERSION : ${{ steps.extract_version.outputs.VERSION }}
127+
123128 - name : Optimize executable size
124129 run : |
125130 # Clean up unnecessary files
0 commit comments