-
Notifications
You must be signed in to change notification settings - Fork 0
/
Taskfile.yml
43 lines (35 loc) · 1.43 KB
/
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
version: '3'
# --------------------------------------------------------------------------------------------------------------------
# --- PATHS
# --------------------------------------------------------------------------------------------------------------------
vars:
ROOT_PATH: '{{.TASKFILE_DIR}}'
SRC_PATH: '{{.TASKFILE_DIR}}/src'
LINT_PATHS: '{{.SRC_PATH}}'
# --------------------------------------------------------------------------------------------------------------------
# --- CONFIGURATION
# --------------------------------------------------------------------------------------------------------------------
silent: true
tasks:
# ------------------------------------------- Default -------------------------------------------- #
check:
desc: Check code. Works like pre-commit.
cmds:
- echo "Checking code format...[fmt]"
- cargo fmt -- --check
- echo "Checking the package for errors...[check]"
- cargo check --all
- echo "Linting rust sources...[clippy]"
- cargo clippy --all-targets --all-features --tests --benches -- -D warnings
- echo "Executing rust tests...[nextest]"
- cargo nextest run --all-features
fmt:
desc: "Format code"
cmds:
- cargo fmt
silent: true
# -------------------------------------------- Testing ------------------------------------------- #
test:
desc: "Run tests"
cmds:
- cargo nextest run --all-features