123 lines
3.5 KiB
YAML
123 lines
3.5 KiB
YAML
name: build
|
|
|
|
on:
|
|
push:
|
|
tags:
|
|
- '*'
|
|
|
|
jobs:
|
|
|
|
build-win64:
|
|
runs-on: windows-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Set up Python 3.9
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: '3.9.5'
|
|
- name: Upgrade pip and enable wheel support
|
|
run: python -m pip install --upgrade pip setuptools wheel
|
|
- name: Install Requirements
|
|
run: |
|
|
pip install -r requirements.txt
|
|
pip install pyinstaller
|
|
shell: bash
|
|
- name: Build
|
|
run: |
|
|
powershell -File build-win.ps1
|
|
mv inno-output\gotify-tray-installer.exe gotify-tray-installer-win.exe
|
|
shell: cmd
|
|
- name: Upload artifact
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: gotify-tray-installer-win.exe
|
|
path: gotify-tray-installer-win.exe
|
|
|
|
build-ubuntu:
|
|
strategy:
|
|
matrix:
|
|
tag: [focal, hirsute, impish, jammy]
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: '3.9.5'
|
|
- name: Upgrade pip and enable wheel support
|
|
run: python -m pip install --upgrade pip setuptools wheel
|
|
- name: Build
|
|
run: |
|
|
make build
|
|
cp dist/gotify-tray_amd64.deb gotify-tray_amd64_ubuntu_${{ matrix.tag }}.deb
|
|
- name: Upload artifact
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: gotify-tray_amd64_ubuntu_${{ matrix.tag }}.deb
|
|
path: gotify-tray_amd64_ubuntu_${{ matrix.tag }}.deb
|
|
|
|
build-debian:
|
|
strategy:
|
|
matrix:
|
|
tag: [bullseye, bookworm]
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: '3.9.5'
|
|
- name: Upgrade pip and enable wheel support
|
|
run: python -m pip install --upgrade pip setuptools wheel
|
|
- name: Build
|
|
run: |
|
|
make build
|
|
cp dist/gotify-tray_amd64.deb gotify-tray_amd64_debian_${{ matrix.tag }}.deb
|
|
- name: Upload artifact
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: gotify-tray_amd64_debian_${{ matrix.tag }}.deb
|
|
path: gotify-tray_amd64_debian_${{ matrix.tag }}.deb
|
|
|
|
build-macos:
|
|
runs-on: macos-12
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v2
|
|
with:
|
|
python-version: '3.9.5'
|
|
- name: Upgrade pip and enable wheel support
|
|
run: python -m pip install --upgrade pip setuptools wheel
|
|
- name: Build
|
|
run: |
|
|
make build-macos
|
|
brew install create-dmg
|
|
create-dmg --volname "Gotify Tray" --app-drop-link 0 0 --no-internet-enable "gotify-tray.dmg" "./dist/Gotify-Tray.app"
|
|
- name: Upload artifact
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: gotify-tray.dmg
|
|
path: gotify-tray.dmg
|
|
|
|
release:
|
|
runs-on: ubuntu-latest
|
|
needs: [build-win64, build-ubuntu, build-debian, build-macos]
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/download-artifact@master
|
|
- name: Release
|
|
uses: marvinpinto/action-automatic-releases@latest
|
|
with:
|
|
repo_token: "${{ secrets.GITHUB_TOKEN }}"
|
|
prerelease: false
|
|
files: |
|
|
gotify-tray-installer-win.exe
|
|
gotify-tray_amd64_ubuntu_focal.deb
|
|
gotify-tray_amd64_ubuntu_hirsute.deb
|
|
gotify-tray_amd64_ubuntu_impish.deb
|
|
gotify-tray_amd64_ubuntu_jammy.deb
|
|
gotify-tray_amd64_debian_bullseye.deb
|
|
gotify-tray_amd64_debian_bookworm.deb
|
|
gotify-tray.dmg
|