Build app #9
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
name: Build app | |
run-name: Build app | |
on: | |
push: | |
branches: | |
- master | |
env: | |
app-name: appraiser-geo | |
build-artifact-if-no-files-found: error | |
build-arfifact-retention-days: 7 | |
build-artifact-linux-name: AppraiserGeo-Linux | |
build-artifact-macos-name: AppraiserGeo-MacOS | |
build-artifact-windows-name: AppraiserGeo-Windows | |
jobs: | |
build-linux-app: | |
runs-on: ubuntu-latest | |
name: Build app for Linux | |
steps: | |
- name: Checkout soruce code | |
uses: actions/[email protected] | |
with: | |
ref: master | |
- name: Install Python | |
uses: actions/[email protected] | |
with: | |
python-version: 3.11 | |
- name: Install requirements | |
run: pip install -r requirements.txt | |
- name: Run build | |
run: pyinstaller src/main.py --onefile --noconfirm --name ${{ env.app-name }} | |
- name: Upload build artifact | |
uses: actions/[email protected] | |
with: | |
name: ${{ env.build-artifact-linux-name }} | |
path: dist/${{ env.app-name }} | |
if-no-files-found: ${{ env.build-artifact-if-no-files-found }} | |
retention-days: ${{ env.build-arfifact-retention-days }} | |
build-mac-app: | |
runs-on: macos-latest | |
name: Build app for Mac | |
steps: | |
- name: Checkout soruce code | |
uses: actions/[email protected] | |
with: | |
ref: master | |
- name: Install Python | |
uses: actions/[email protected] | |
with: | |
python-version: 3.11 | |
- name: Install requirements | |
run: pip install -r requirements.txt | |
- name: Run build | |
run: pyinstaller src/main.py --onefile --noconfirm --name ${{ env.app-name }} | |
- name: Upload build artifact | |
uses: actions/[email protected] | |
with: | |
name: ${{ env.build-artifact-macos-name }} | |
path: dist/${{ env.app-name }} | |
if-no-files-found: ${{ env.build-artifact-if-no-files-found }} | |
retention-days: ${{ env.build-arfifact-retention-days }} | |
build-mac-win: | |
runs-on: windows-latest | |
name: Build app for Windows | |
steps: | |
- name: Checkout soruce code | |
uses: actions/[email protected] | |
with: | |
ref: master | |
- name: Install Python | |
uses: actions/[email protected] | |
with: | |
python-version: 3.11 | |
- name: Install requirements | |
run: pip install -r requirements.txt | |
- name: Run build | |
run: pyinstaller src/main.py --onedir --noconfirm --name ${{ env.app-name }} | |
- name: Upload build artifact | |
uses: actions/[email protected] | |
with: | |
name: ${{ env.build-artifact-windows-name }} | |
path: dist/${{ env.app-name }} | |
if-no-files-found: ${{ env.build-artifact-if-no-files-found }} | |
retention-days: ${{ env.build-arfifact-retention-days }} |