Merge branch 'docs/polish' #3
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: macos app | |
| on: | |
| push: | |
| tags: ["v*"] | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| build: | |
| runs-on: macos-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.12" | |
| - name: Install the emulator and the packaging tools | |
| run: pip install -e .[gui,package] | |
| - name: Run the test suite first | |
| run: | | |
| pip install pytest pytest-timeout | |
| pytest -q | |
| - name: Draw the icon | |
| run: | | |
| python packaging/make_icon.py packaging/icon.iconset | |
| iconutil -c icns packaging/icon.iconset -o packaging/PySP.icns | |
| - name: Build PySP.app | |
| run: | | |
| pyinstaller \ | |
| --windowed \ | |
| --name PySP \ | |
| --icon packaging/PySP.icns \ | |
| --osx-bundle-identifier me.necati.pysp \ | |
| packaging/app_entry.py | |
| ls -la dist | |
| - name: Zip the bundle | |
| run: | | |
| cd dist | |
| zip -ry PySP-macOS.zip PySP.app | |
| - name: Upload the artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: PySP-macOS | |
| path: dist/PySP-macOS.zip | |
| - name: Attach to the release | |
| if: startsWith(github.ref, 'refs/tags/') | |
| env: | |
| GH_TOKEN: ${{ github.token }} | |
| run: gh release create "${GITHUB_REF_NAME}" dist/PySP-macOS.zip --generate-notes || gh release upload "${GITHUB_REF_NAME}" dist/PySP-macOS.zip |