-
Notifications
You must be signed in to change notification settings - Fork 2
/
Taskfile.yml
46 lines (38 loc) · 924 Bytes
/
Taskfile.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
45
46
version: "3"
vars:
RUNNER:
sh: 'echo {{ .RUNNER | default "" }}'
SOURCES: .
tasks:
default:
cmd:
task: all
lint:
desc: Lint python source files
cmds:
- "{{.RUNNER}} ruff check {{.SOURCES}}"
- "{{.RUNNER}} ruff format --checm {{.SOURCES}}"
format:
desc: Format python source files
aliases: ["fmt"]
cmds:
- "{{.RUNNER}} ruff check --fix {{.SOURCES}}"
- "{{.RUNNER}} ruff format {{.SOURCES}}"
typecheck:
desc: Perform type-checking
cmd: "{{.RUNNER}} mypy {{.SOURCES}}"
test:
desc: Run tests
cmd: "{{.RUNNER}} coverage run"
testcov:
desc: Run tests and generate a coverage report
cmds:
- task: test
- "{{.RUNNER}} coverage report -m"
- "{{.RUNNER}} coverage xml"
all:
desc: Run the standard set of checks performed in CI
cmds:
- task: format
- task: typecheck
- task: testcov