-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathTaskfile.yml
68 lines (62 loc) · 1.44 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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
# https://taskfile.dev
version: "3"
tasks:
run-host:
internal: true
cmds:
- mv .cargo/config.toml .cargo/config.toml.bck
- defer: mv .cargo/config.toml.bck .cargo/config.toml
- cargo {{.COMMAND}}
run-web:
internal: true
cmds:
- mv .cargo/config.toml .cargo/config.toml.bck
- defer: mv .cargo/config.toml.bck .cargo/config.toml
- mv rust-toolchain.toml rust-toolchain.toml.bck
- defer: mv rust-toolchain.toml.bck rust-toolchain.toml
- cargo {{.COMMAND}} --target wasm32-unknown-unknown
build-esp:
- cargo build
build-host:
- task: run-host
vars: { COMMAND: build }
build-web:
- task: run-web
vars: { COMMAND: build }
test-host:
cmds:
- task: run-host
vars: { COMMAND: test }
test:
- task: build-esp
- task: build-host
- task: test-host
lint-esp:
cmds:
- cargo clippy
lint-host:
cmds:
- task: run-host
vars: { COMMAND: clippy }
lint:
- task: lint-esp
- task: lint-host
format:
desc: run code formatters
cmds:
- cargo fmt
release:
desc: build and publish release
cmds:
- test {{.CLI_ARGS}}
- grep -F '"{{.CLI_ARGS}}"' Cargo.toml
# - cargo publish
- git tag {{.CLI_ARGS}}
- git push
- git push --tags
- gh release create --generate-notes {{.CLI_ARGS}}
all:
cmds:
- task: format
- task: lint
- task: test