Skip to content

Commit 80bf21e

Browse files
committed
Cover all modules of project in "umbrella" tasks
For the convenience of the developer, some "umbrella" tasks have been defined, which run all the specific tasks of a basic class: - `check`: run all automated checks for issues - `fix`: make automated corrections for issues where possible The project contains multiple Go modules in different folders: - `github.com/arduino/arduino-lint`: root folder - `github.com/arduino/arduino-lint/docsgen`: docsgen subfolder - `github.com/arduino/arduino-lint/ruledocsgen`: ruledocsgen subfolder `go` commands are applied to the module in the current working directory. The tasks are configured so that the working directory can be specified, defaulting to the root. Previously, the "umbrella" tasks only ran the `go:*` tasks with the default, meaning only the `github.com/arduino/arduino-lint` module was covered by these tasks. This is contrary to the intended purpose of these "umbrella" tasks, which is to allow the developer to run a couple of standardized commands to find or fix all problems, trading efficiency for convenience.
1 parent b77cc0f commit 80bf21e

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

Taskfile.yml

+33
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,24 @@ tasks:
5555
- task: general:check-formatting
5656
- task: general:check-spelling
5757
- task: go:test
58+
- task: go:test
59+
vars:
60+
GO_MODULE_PATH: ./ruledocsgen
5861
- task: go:test-integration
5962
- task: go:vet
63+
- task: go:vet
64+
vars:
65+
GO_MODULE_PATH: ./docsgen
66+
- task: go:vet
67+
vars:
68+
GO_MODULE_PATH: ./ruledocsgen
6069
- task: go:lint
70+
- task: go:lint
71+
vars:
72+
GO_MODULE_PATH: ./docsgen
73+
- task: go:lint
74+
vars:
75+
GO_MODULE_PATH: ./ruledocsgen
6176
- task: markdown:lint
6277
- task: markdown:check-links
6378
- task: python:lint
@@ -72,8 +87,26 @@ tasks:
7287
- task: general:correct-spelling
7388
- task: go:generate
7489
- task: go:fix
90+
- task: go:fix
91+
vars:
92+
GO_MODULE_PATH: ./docsgen
93+
- task: go:fix
94+
vars:
95+
GO_MODULE_PATH: ./ruledocsgen
96+
- task: go:format
97+
- task: go:format
98+
vars:
99+
GO_MODULE_PATH: ./docsgen
75100
- task: go:format
101+
vars:
102+
GO_MODULE_PATH: ./ruledocsgen
103+
- task: go:tidy
104+
- task: go:tidy
105+
vars:
106+
GO_MODULE_PATH: ./docsgen
76107
- task: go:tidy
108+
vars:
109+
GO_MODULE_PATH: ./ruledocsgen
77110
- task: markdown:fix
78111
- task: python:format
79112
- task: shell:format

0 commit comments

Comments
 (0)