Voltage Park migration -- set up workflows and pre-commit #3
This file contains hidden or 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: Build | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| python-version: [3.12] | |
| # Skip CI if 'skip ci' is in the latest commit message or if PR is a draft | |
| if: | | |
| !contains(github.event.head_commit.message, 'skip ci') && | |
| (github.event_name != 'pull_request' || !github.event.pull_request.draft) | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Setup UV and python version | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| version: "0.10.6" | |
| python: ${{ matrix.python-version }} | |
| - name: Install dependencies | |
| run: uv sync --group dev | |
| - name: Run tests | |
| env: | |
| TEST_DATA_DIR: ${{ github.workspace }}/tests/test_files | |
| run: uv run pytest |