Skip to content

Commit

Permalink
ci: add build workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
kdev committed Aug 4, 2023
1 parent b70c0b4 commit 3373f5d
Showing 1 changed file with 46 additions and 0 deletions.
46 changes: 46 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Build application executables

on:
push:
branches: ['master']
pull_request:
branches: ['master']
workflow_dispatch:

permissions:
contents: read
packages: write

jobs:
build:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.10
id: cp310
uses: actions/setup-python@v3
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install pyinstaller opencv-python-headless opencv-contrib-python
pip install -r requirements.txt
- name: Make
run: make
- name: Install libgl1
if: matrix.os == 'ubuntu-latest'
run: sudo apt-get install libgl1 libegl1
- name: Run PyInstaller (windows)
if: matrix.os == 'windows-latest'
run: pyinstaller -n "OnAirScreen" -F --noconsole -i "images/oas_icon.ico" start.py
- name: Run PyInstaller (ubuntu)
if: matrix.os == 'ubuntu-latest'
run: pyinstaller -n "OnAirScreen" -F --noconsole start.py
- uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}
path: dist/*

0 comments on commit 3373f5d

Please sign in to comment.