Skip to content

Build

Build #8

Workflow file for this run

name: Build
on:
push:
branches:
- release
tags:
- 'v*'
workflow_dispatch:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: windows-latest
artifact: pydeej.exe
- os: ubuntu-latest
artifact: pydeej
- os: macos-latest
artifact: pydeej
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.10'
- name: Install dependencies
run: |
pip install -r requirements.txt
pip install pyinstaller
- name: Build
run: python build.py
env:
PYTHONIOENCODING: utf-8
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: pydeej-${{ matrix.os }}
path: dist/${{ matrix.artifact }}
- name: Create Release
if: github.event_name == 'push' && (startsWith(github.ref, 'refs/tags/') || github.ref == 'refs/heads/release')
uses: softprops/action-gh-release@v2
with:
files: dist/${{ matrix.artifact }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}