File tree Expand file tree Collapse file tree 5 files changed +63
-0
lines changed Expand file tree Collapse file tree 5 files changed +63
-0
lines changed Original file line number Diff line number Diff line change 1+ # yamllint disable-line rule:line-length
2+ # yaml-language-server: $schema=https://raw.githubusercontent.com/BlankSpruce/gersemi/master/gersemi/configuration.schema.json
3+
4+ line_length: 100
5+ list_expansion: "favour-expansion"
Original file line number Diff line number Diff line change 1+ cmake_minimum_required (VERSION 3.16.3)
2+ project (YSTDLIB_CPP LANGUAGES CXX)
3+
4+ set (YSTDLIB_CPP_VERSION "0.0.1" CACHE STRING "Project version." )
Original file line number Diff line number Diff line change 1+ colorama>=0.4.6
2+ gersemi>=0.16.2
13yamllint>=1.35.1
Original file line number Diff line number Diff line change 1+ version : " 3"
2+
3+ tasks :
4+ cmake-check :
5+ desc : " Runs the CMake linters."
6+ sources : &cmake_format_src_files
7+ - " {{.ROOT_DIR}}/**/*.cmake"
8+ - " {{.ROOT_DIR}}/**/*.cmake.in"
9+ - " {{.ROOT_DIR}}/**/CMakeLists.txt"
10+ - " {{.TASKFILE}}"
11+ - exclude : " {{.ROOT_DIR}}/**/build/*"
12+ - exclude : " {{.ROOT_DIR}}/**/submodules/*"
13+ - exclude : " {{.ROOT_DIR}}/**/tools/*"
14+ cmds :
15+ - task : " gersemi"
16+ vars :
17+ FLAGS : " --diff --color"
18+ - task : " gersemi"
19+ silent : true
20+ vars :
21+ FLAGS : " --check"
22+
23+ cmake-fix :
24+ desc : " Runs the CMake linters and fixes all violations."
25+ sources : *cmake_format_src_files
26+ cmds :
27+ - task : " gersemi"
28+ vars :
29+ FLAGS : " --in-place"
30+
31+ gersemi :
32+ internal : true
33+ requires :
34+ vars :
35+ - " FLAGS"
36+ dir : " {{.ROOT_DIR}}"
37+ deps :
38+ - " venv"
39+ cmds :
40+ - |-
41+ . "{{.G_LINT_VENV_DIR}}/bin/activate"
42+ find . \
43+ \( -path '**/build' -o -path '**/submodules' -o -path '**/tools' \) -prune -o \
44+ \( -iname "CMakeLists.txt" -o -iname "*.cmake" -o -iname "*.cmake.in" \) \
45+ -print0 | \
46+ xargs -0 --no-run-if-empty gersemi {{.FLAGS}}
Original file line number Diff line number Diff line change 11version : " 3"
22
33includes :
4+ cmake :
5+ flatten : true
6+ taskfile : " ./lint-cmake.yaml"
47 yaml :
58 flatten : true
69 taskfile : " ./lint-yaml.yaml"
@@ -13,11 +16,13 @@ tasks:
1316 check :
1417 desc : " Runs the full suite of linters to identify warnings and violations."
1518 cmds :
19+ - task : " cmake-check"
1620 - task : " yaml-check"
1721
1822 fix :
1923 desc : " Runs the full suite of linters and fixes some violations."
2024 cmds :
25+ - task : " cmake-fix"
2126 - task : " yaml-fix"
2227
2328 venv :
3136 - " lint-requirements.txt"
3237 generates :
3338 - " {{.CHECKSUM_FILE}}"
39+ run : " once"
3440 deps :
3541 - " :init"
3642 - task : " :utils:validate-checksum"
You can’t perform that action at this time.
0 commit comments