-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTaskfile.yml
More file actions
101 lines (84 loc) · 2.91 KB
/
Taskfile.yml
File metadata and controls
101 lines (84 loc) · 2.91 KB
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
version: "3"
tasks:
default:
silent: true
desc: List all tasks.
cmd: task --list
setup:
desc: Setup the dev environment.
summary: |
Setup the development environment.
This command is involved in setting up the development environment locally. The
command starts by installing all the necessary Pre-Commit hooks followed by
installing all the necessary Node.js dependencies.
cmds:
- task: setup:pre-commit
- task: setup:npm
- task: setup:docs
setup:npm:
internal: true
sources: [package.json]
generates: [pnpm-lock.yaml]
setup:pre-commit:
internal: true
sources: [.pre-commit-config.yaml]
generates:
- .git/hooks/commit-msg
- .git/hooks/pre-commit
setup:docs:
internal: true
dir: ./docs
sources: [package.json]
generates: [pnpm-lock.yaml]
cmd: pnpm install --frozen-lockfile
test:
silent: true
desc: Run the test suite.
summary: |
Run the test suite.
This command will run the entire test suite using Vitest. Post completion of the
test execution, Vitest will print out a coverage report which can be used as a
reference to identify missing test coverage.
cmd: pnpm test
qa:
desc: Run code quality checks.
summary: |
Run code quality checks.
This command will run ESLint and Prettier on the source code to enforce a uniform
coding standard across the entire source code.
NOTE: The commands are run sequentially, hence ESLint will ALWAYS run before
Prettier.
cmds:
- pnpm lint
- pnpm format
build:
desc: Build and compile the package.
summary: |
Build and compile the package.
This command will compile and build the package in preparation for distribution to
a registry (like npm.js). Although the locally compiled package will NOT be
distributed, the purpose of the command is primarily to serve as a sanity check for
other devs to check of correctness of the compiled package.
cmd: pnpm build
all:
desc: Run the entire development pipeline.
summary: |
Run the entire developmnet pipeline.
This command will run the entire development pipeline, from dependency installation
to building the package, including running the QA checks on the source code. The
command is expected to be run as a means of a sanity check to ensure everything
works as expected.
cmds:
- task: setup
- task: qa
- task: test
- task: build
docs:
desc: Run the development version of the documentation.
summary: |
Run the development version of the documentation.
This command will run the development version of the documentation. It will change
the current working directory to the "docs" and run the necessary command to spin up
the development server for the documentation.
dir: ./docs
cmd: pnpm dev --host