Remove template submodule #50
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
# Run static analysis, tests, and sync | |
name: "ci" | |
concurrency: | |
group: "${{ github.workflow }}-${{ github.ref }}" | |
cancel-in-progress: True | |
on: | |
workflow_dispatch: | |
pull_request: | |
push: | |
branches: ["main"] | |
defaults: | |
run: | |
shell: "pwsh" | |
jobs: | |
sync: | |
runs-on: "ubuntu-22.04" | |
steps: | |
- uses: "actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332" # v4.1.7 | |
with: | |
submodules: True | |
- uses: "astral-sh/setup-uv@9f1f1fece28798fe5e7ece00f4243abe886974b2" # v3.0.0 | |
with: | |
version: "0.4.15" | |
enable-cache: true | |
cache-dependency-glob: | | |
**/uv.lock | |
.github/workflows/** | |
- run: "./Invoke-Uv.ps1" | |
- uses: "actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b" # v4.3.4 | |
with: | |
name: "lock" | |
path: | | |
uv.lock | |
requirements | |
build-docs: | |
runs-on: "ubuntu-22.04" | |
steps: | |
- uses: "actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332" # v4.1.7 | |
with: | |
submodules: True | |
- uses: "astral-sh/setup-uv@9f1f1fece28798fe5e7ece00f4243abe886974b2" # v3.0.0 | |
with: | |
version: "0.4.15" | |
enable-cache: true | |
cache-dependency-glob: | | |
**/uv.lock | |
.github/workflows/** | |
- run: "./Invoke-Uv.ps1 sphinx-build -EaT docs _site" | |
- uses: "actions/upload-pages-artifact@56afc609e74202658d3ffba0e8f6dda462b719fa" # v3.0.1 | |
deploy-docs: | |
if: github.event_name != 'pull_request' | |
needs: "build-docs" | |
permissions: | |
pages: "write" | |
id-token: "write" | |
environment: | |
name: "github-pages" | |
url: "${{ steps.deployment.outputs.page_url }}" | |
runs-on: "ubuntu-22.04" | |
steps: | |
- id: "deployment" | |
uses: "actions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e" # v4.0.5 | |
ruff: | |
runs-on: "ubuntu-22.04" | |
steps: | |
- uses: "actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332" # v4.1.7 | |
with: | |
submodules: True | |
- uses: "astral-sh/setup-uv@9f1f1fece28798fe5e7ece00f4243abe886974b2" # v3.0.0 | |
with: | |
version: "0.4.15" | |
enable-cache: true | |
cache-dependency-glob: | | |
**/uv.lock | |
.github/workflows/** | |
- run: "./Invoke-Uv.ps1 ruff check --no-fix --output-format github ." | |
fawltydeps: | |
runs-on: "ubuntu-22.04" | |
steps: | |
- uses: "actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332" # v4.1.7 | |
with: | |
submodules: True | |
- uses: "astral-sh/setup-uv@9f1f1fece28798fe5e7ece00f4243abe886974b2" # v3.0.0 | |
with: | |
version: "0.4.15" | |
enable-cache: true | |
cache-dependency-glob: | | |
**/uv.lock | |
.github/workflows/** | |
- run: ". ./dev.ps1 && iuv pre-commit run fawltydeps-src && iuv pre-commit run fawltydeps-dev" | |
pyright: | |
runs-on: "ubuntu-22.04" | |
steps: | |
- uses: "actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332" # v4.1.7 | |
with: | |
submodules: True | |
- uses: "astral-sh/setup-uv@9f1f1fece28798fe5e7ece00f4243abe886974b2" # v3.0.0 | |
with: | |
version: "0.4.15" | |
enable-cache: true | |
cache-dependency-glob: | | |
**/uv.lock | |
.github/workflows/** | |
- run: "./Invoke-Uv.ps1" | |
- uses: "jakebailey/pyright-action@3bdde3b31d26f0f1f5de051b1fbd7a536a9a4e7f" # v2.3.1 | |
with: | |
pylance-version: "${{ env.PYRIGHT_PYTHON_PYLANCE_VERSION }}" | |
test: | |
strategy: | |
matrix: | |
runner: | |
- "macos-13" | |
- "ubuntu-22.04" | |
- "windows-2022" | |
python: | |
- "3.11" | |
- "3.12" | |
runs-on: "${{ matrix.runner }}" | |
steps: | |
- uses: "actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332" # v4.1.7 | |
with: | |
submodules: True | |
- uses: "astral-sh/setup-uv@9f1f1fece28798fe5e7ece00f4243abe886974b2" # v3.0.0 | |
with: | |
version: "0.4.15" | |
enable-cache: true | |
cache-dependency-glob: | | |
**/uv.lock | |
.github/workflows/** | |
# ! https://github.com/pytest-dev/pytest-cov/issues/479#issuecomment-1247444988 | |
- if: startsWith(matrix.runner, 'ubuntu') && matrix.python == '3.11' | |
run: "./Invoke-Uv.ps1 pytest --cov --cov-config=pyproject.toml --cov-report=xml" | |
- if: startsWith(matrix.runner, 'ubuntu') && matrix.python == '3.11' | |
uses: "codecov/codecov-action@e28ff129e5465c2c0dcc6f003fc735cb6ae0c673" # v4.5.0 | |
env: | |
CODECOV_TOKEN: "${{ secrets.CODECOV_TOKEN }}" | |
- if: (!(startsWith(matrix.runner, 'ubuntu') && matrix.python == '3.11')) | |
run: "./Invoke-Uv.ps1 -PythonVersion '${{ matrix.python }}' pytest" |