-
Notifications
You must be signed in to change notification settings - Fork 3
44 lines (35 loc) · 1.12 KB
/
linting.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# This workflow does static type checking and checks for formatting and linting errors.
# The same stack as explained in https://docs.nerf.studio/en/latest/reference/contributing.html is used to ensure consistency.
name: formatting-linting
on:
push:
jobs:
formatting-linting:
runs-on: ubuntu-latest
steps:
- uses: actions/setup-python@v4
with:
python-version: '3.8'
# load cached env (otherwise nerfstudio can take quite long to install)
- uses: actions/cache@v3
with:
path: ${{ env.pythonLocation }}
key: ${{ env.pythonLocation }}-${{ hashFiles('pyproject.toml') }}
# checkout seathru-nerf (this repo)
- uses: actions/checkout@v3
with:
path: seathru_nerf
- name: Install seathru
working-directory: ./seathru_nerf
run: |
pip install -e .
# stuff
- name: run ruff
working-directory: ./seathru_nerf
run: ruff check seathru/ tests/
- name: run black
working-directory: ./seathru_nerf
run: black seathru/ tests/ --check
- name: run pyright
working-directory: ./seathru_nerf
run: pyright