diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9990685..2296597 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -5,22 +5,39 @@ on: branches: master jobs: - build: + build-exe: runs-on: ${{ matrix.os }} - strategy: - matrix: - os: [ubuntu-latest, windows-latest, macos-latest] - + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] steps: - - name: Checkout - uses: actions/checkout@v1 - - - name: Create Executable - uses: sayyid5416/pyinstaller@v1 + - uses: actions/checkout@v2 + - uses: actions/setup-python@v4 + with: + python-version: "3.10" + - name: Install redwrench + shell: bash -l {0} + run: | + pip3 install . + - name: install PyInstaller + shell: bash -l {0} + run: | + pip3 install pyinstaller==5.9.0 + - name: Build Pyinstaller .exe (macOS and Linux) + if: matrix.os != 'windows-latest' + shell: bash -l {0} + run: | + pyinstaller -n redwrench --onefile --windowed app.py + - name: Build Pyinstaller .exe (Windows) + if: matrix.os == 'windows-latest' + shell: bash -l {0} + run: | + pyinstaller -n redwrench --onefile app.py + - uses: vimtor/action-zip@v1 + with: + files: dist/ + recursive: false + dest: ${{ matrix.os }}-${{github.ref_name}}.zip + - uses: softprops/action-gh-release@v1 with: - python_ver: '3.12' - spec: 'main.py' - requirements: 'requirements.txt' - upload_exe_with_name: 'SerialToUdpTranslatorV1.0' - options: --onefile, --name "SerialToUdpTranslatorV1.0", --windowed, \ No newline at end of file + files: ${{ matrix.os }}-${{github.ref_name}}.zip \ No newline at end of file