feat(pytauri): add path::PathResolver
#116
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
# WARNING: Do not change the name of this file, keep `lint-test.yml`. | |
# `workflow_call` needs the name of the workflow file to work. | |
name: Lint check and test | |
# We only automatically run checks for PRs. | |
# It is best to avoid direct commits to the main branch, instead make a PR for checks. | |
on: | |
pull_request: | |
workflow_dispatch: | |
# NOTE: set `secrets: inherit` when call this workflow from other workflow. | |
workflow_call: | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
pre-commit-run: | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"] | |
os: ["ubuntu-latest", "windows-latest"] | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: setup-envs-ver | |
id: setup-envs-ver | |
uses: ./.github/actions/setup-envs-ver | |
- name: Install uv | |
uses: astral-sh/setup-uv@v4 | |
with: | |
# see: <https://docs.astral.sh/uv/guides/integration/github/> | |
version: ${{ steps.setup-envs-ver.outputs.uv }} | |
enable-cache: true | |
- name: Setup Python | |
uses: actions/setup-python@v5 | |
id: setup-python | |
with: | |
python-version: ${{ matrix.python-version }} | |
# see: <https://github.com/pnpm/action-setup> | |
- name: Install pnpm | |
uses: pnpm/action-setup@v4 | |
# see: <https://github.com/actions/setup-node> | |
- name: Install Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version-file: package.json | |
cache: "pnpm" | |
# see: <https://github.com/dtolnay/rust-toolchain> | |
- name: install Rust stable | |
uses: dtolnay/rust-toolchain@stable | |
with: | |
components: rustfmt, clippy | |
# see: <https://github.com/swatinem/rust-cache> | |
- name: Rust cache | |
uses: swatinem/rust-cache@v2 | |
with: | |
key: py-${{ matrix.python-version }} | |
- name: Cache pre-commit | |
uses: ./.github/actions/cache-pre-commit | |
- name: setup-sys-deps | |
if: matrix.os == 'ubuntu-latest' | |
uses: ./.github/actions/setup-sys-deps | |
- name: pnpm install | |
run: pnpm install --frozen-lockfile | |
- name: pnpm build frontend | |
run: pnpm -r build | |
- name: pre-commit run | |
run: | | |
uv run --all-extras \ | |
-- pre-commit run --show-diff-on-failure --color=always --hook-stage=manual --all-files |