89 lines
1.8 KiB
YAML
89 lines
1.8 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [ main ]
|
|
|
|
jobs:
|
|
build-linux:
|
|
runs-on: ubuntu-16.04
|
|
|
|
steps:
|
|
- name: Install dependencies
|
|
run: sudo apt-get install libusb-1.0-0-dev libudev-dev
|
|
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-python@v1
|
|
with:
|
|
python-version: '3.6.x'
|
|
|
|
- name: Setup venv
|
|
run: |
|
|
python -m venv venv
|
|
source venv/bin/activate
|
|
pip install -r requirements.txt
|
|
|
|
- name: Build
|
|
run: |
|
|
source venv/bin/activate
|
|
fbs freeze
|
|
cd target
|
|
tar cfJ vial-linux.tar.xz Vial
|
|
|
|
- uses: actions/upload-artifact@v1
|
|
with:
|
|
name: vial-linux
|
|
path: target/vial-linux.tar.xz
|
|
|
|
build-mac:
|
|
runs-on: macos-10.15
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-python@v1
|
|
with:
|
|
python-version: '3.6.x'
|
|
|
|
- name: Setup venv
|
|
run: |
|
|
python -m venv venv
|
|
source venv/bin/activate
|
|
pip install -r requirements.txt
|
|
|
|
- name: Build
|
|
run: |
|
|
source venv/bin/activate
|
|
fbs freeze
|
|
hdiutil create -volname Vial -srcfolder "target/Vial.app" -ov -format UDZO vial-mac.dmg
|
|
|
|
- uses: actions/upload-artifact@v1
|
|
with:
|
|
name: vial-mac
|
|
path: vial-mac.dmg
|
|
|
|
build-win:
|
|
runs-on: windows-2019
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-python@v1
|
|
with:
|
|
python-version: '3.6.x'
|
|
|
|
- name: Setup venv
|
|
run: |
|
|
python -m venv venv
|
|
. .\venv\Scripts\activate.ps1
|
|
pip install -r requirements.txt
|
|
|
|
- name: Build
|
|
run: |
|
|
. .\venv\Scripts\activate.ps1
|
|
fbs freeze
|
|
Compress-Archive -Path "target\Vial" -DestinationPath vial-win.zip
|
|
|
|
- uses: actions/upload-artifact@v1
|
|
with:
|
|
name: vial-win
|
|
path: vial-win.zip
|