Add Action
This commit is contained in:
parent
58fb900269
commit
38d9e6c7c4
62
.github/workflows/main.yml
vendored
Normal file
62
.github/workflows/main.yml
vendored
Normal file
|
@ -0,0 +1,62 @@
|
|||
# This is a basic workflow to help you get started with Actions
|
||||
|
||||
name: Python
|
||||
|
||||
# Controls when the action will run.
|
||||
on:
|
||||
# Triggers the workflow on push or pull request events but only for the main branch
|
||||
push:
|
||||
branches: [ main ]
|
||||
pull_request:
|
||||
branches: [ main ]
|
||||
|
||||
# Allows you to run this workflow manually from the Actions tab
|
||||
workflow_dispatch:
|
||||
|
||||
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||
jobs:
|
||||
pyinstaller:
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
matrix:
|
||||
os: ['ubuntu-20.04', 'windows-latest']
|
||||
fail-fast: true
|
||||
max-parallel: 3
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/setup-python@v2
|
||||
with:
|
||||
python-version: '3.8'
|
||||
|
||||
- name: Dependencies
|
||||
run: pip3 install --upgrade
|
||||
pyinstaller
|
||||
requests
|
||||
setuptools
|
||||
wheel
|
||||
PyQt5
|
||||
QtAwesome
|
||||
pillow
|
||||
notify-py
|
||||
|
||||
- name: Strip
|
||||
id: strip
|
||||
run: echo ::set-output name=option::--strip
|
||||
if: runner.os != 'Windows'
|
||||
|
||||
- name: Build
|
||||
working-directory: Rare
|
||||
run: pyinstaller
|
||||
--onefile
|
||||
--name Rare
|
||||
--add-data="Rare/Styles/languages/*;Rare/Styles/"
|
||||
--add-data="Rare/languages/*;Rare/languages"
|
||||
${{ steps.strip.outputs.option }}
|
||||
__main__.py
|
||||
|
||||
- uses: actions/upload-artifact@v2
|
||||
with:
|
||||
name: ${{ runner.os }}-package
|
||||
path: Rare/dist/*
|
Loading…
Reference in a new issue