-
Notifications
You must be signed in to change notification settings - Fork 271
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Build of MacOS app bundle NanoVNASaver.app (#634)
* add icon for MacOS based on icon_48x48.png * add macos build script to build NanoVNASaver.app for current architecture * add releas app action to build: NanoVNASaver.app-x86_64.tar.gz action
- Loading branch information
Showing
3 changed files
with
64 additions
and
0 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
name: Mac Release App | ||
|
||
on: | ||
push: | ||
tags: | ||
- v* | ||
workflow_dispatch: | ||
|
||
jobs: | ||
release: | ||
runs-on: macos-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.11 | ||
- name: Get Target Environment | ||
id: targetenv | ||
run: | | ||
echo "arch=`uname -m`" >> "$GITHUB_ENV" | ||
- name: Install dependencies and pyinstall | ||
run: | | ||
python -m pip install pip==23.0.1 setuptools==67.6.0 | ||
pip install -r requirements.txt | ||
pip install PyInstaller==5.9.0 | ||
- name: Build binary | ||
run: | | ||
python setup.py -V | ||
pyinstaller --onedir -p src -n NanoVNASaver nanovna-saver.py --window --clean -y -i icon_48x48.icns | ||
tar -C dist -zcf ./dist/NanoVNASaver.app-${{ env.arch }}.tar.gz NanoVNASaver.app | ||
echo "Created: NanoVNASaver.app-${{ env.arch }}.tar.gz" | ||
- name: Archive production artifacts | ||
uses: actions/upload-artifact@v1 | ||
with: | ||
name: NanoVNASaver.app-${{ env.arch }}.tar.gz | ||
path: dist/NanoVNASaver.app-${{ env.arch }}.tar.gz |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Builds a NanoVNASaver.app on MacOS | ||
# ensure you have pyqt >=6.4 installed (brew install pyqt) | ||
# | ||
export VENV_DIR=macbuildenv | ||
|
||
# setup build venv | ||
python3 -m venv ${VENV_DIR} | ||
. ./${VENV_DIR}/bin/activate | ||
|
||
# install required dependencies (pyqt libs must be installed on the system) | ||
python3 -m pip install pip==23.0.1 setuptools==67.6.0 | ||
pip install -r requirements.txt | ||
pip install PyInstaller==5.9.0 | ||
|
||
python3 setup.py -V | ||
|
||
pyinstaller --onedir -p src -n NanoVNASaver nanovna-saver.py --window --clean -y -i icon_48x48.icns | ||
tar -C dist -zcf ./dist/NanoVNASaver.app-`uname -m`.tar.gz NanoVNASaver.app | ||
|
||
deactivate | ||
rm -rf ${VENV_DIR} |
Binary file not shown.