Skip to content

Add GitHub workflows. #1

Add GitHub workflows.

Add GitHub workflows. #1

Workflow file for this run

name: Build and publish
on:
push:
branches: [master, dev]
# release:
# types: [published]
matrix:

Check failure on line 8 in .github/workflows/build.yml

View workflow run for this annotation

GitHub Actions / Build and publish

Invalid workflow file

The workflow is not valid. .github/workflows/build.yml (Line: 8, Col: 1): Unexpected value 'matrix' .github/workflows/build.yml (Line: 36, Col: 27): Unrecognized named-value: 'os'. Located at position 1 within expression: os.version
version: ["3.9", "3.10", "3.11", "3.12"]
jobs:
build:
strategy:
matrix:
os:
- windows-latest
- macos-latest
- ubuntu-latest
version:
- "3.9"
- "3.10"
- "3.11"
- "3.12"
runs-on: ${{ matrix.os }}
steps:
- name: Check out repository code
uses: actions/checkout@v4
- name: Install Poetry
run: |
python -m pip install --upgrade pip
python -m pip install poetry
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: ${{ os.version }}
cache: "poetry"
- name: Install dependencies
run: |
poetry install
- name: Build
run: |
poetry install
# - name: Check
# run: poetry run python -c "import cshogi"
# - name: Publish
# if: github.event_name == 'release' && github.event.action == 'published'
# env:
# TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
# TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
# run: twine upload dist/*