Auto-build with latest python version #22
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Python | |
on: [push] | |
jobs: | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: [3.9, "3.10", 3.11] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install poetry | |
poetry install | |
- name: Test with pytest | |
run: | | |
poetry run pytest | |
#* I want to eventually run a linter against this project, but it is not ready for that level of scrutiny just yet. | |
# lint: | |
# runs-on: ubuntu-latest | |
# steps: | |
# - uses: actions/checkout@v2 | |
# - name: Set up Python | |
# uses: actions/setup-python@v2 | |
# with: | |
# python-version: 3.9 | |
# - name: Install linter | |
# run: python -m pip install flake8 | |
# - name: Run linter | |
# run: flake8 | |
build: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, windows-latest, macos-latest] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.11 | |
- name: Install dependencies | |
run: | | |
python -m pip install poetry | |
poetry install | |
- name: Create executable | |
run: poetry run python -m PyInstaller --onefile --name mcmm binary.py | |
- name: Upload artifact | |
uses: actions/upload-artifact@v2 | |
with: | |
name: mcmm-${{ matrix.os }}-amd64 | |
path: ${{ github.workspace }}/dist/mcmm* |