Skip to content

Commit 12d1e63

Browse files
feat(ci): add stylelint check (#185)
1 parent 1aed27b commit 12d1e63

File tree

3 files changed

+11
-4
lines changed

3 files changed

+11
-4
lines changed

.github/workflows/linter.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,7 @@ jobs:
3737
run: yarn run fmt:check
3838

3939
- name: Run eslint
40-
run: yarn run lint
40+
run: yarn run lint:ts
41+
42+
- name: Run stylelint
43+
run: yarn run lint:css

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,8 @@ yarn-error.log
2222
# eslint
2323
.eslintcache
2424

25+
# stylelint
26+
.stylelintcache
27+
2528
# coverage
2629
coverage/

package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,9 @@
3838
"test": "yarn jest",
3939
"build": "webpack && node ./.scripts/set-executable.js ./dist/server.js",
4040
"package": "npx vsce package --no-yarn --readme-path editors/code/README.md",
41-
"lint": "eslint --cache .",
42-
"lint:css": "npx stylelint \"editors/**/*.css\"",
41+
"lint": "yarn run lint:ts && yarn run lint:css",
42+
"lint:ts": "eslint --cache .",
43+
"lint:css": "stylelint 'editors/**/*.css' --cache",
4344
"fmt": "prettier --write -l --cache .",
4445
"fmt:check": "prettier --check --cache .",
4546
"grammar:wasm": "yarn grammar:tolk:wasm && yarn grammar:func:wasm && yarn grammar:fift:wasm && yarn grammar:tlb:wasm",
@@ -48,7 +49,7 @@
4849
"grammar:fift:wasm": "cd server/src/languages/fift/tree-sitter-fift && tree-sitter generate && tree-sitter build --wasm",
4950
"grammar:tlb:wasm": "cd server/src/languages/tlb/tree-sitter-tlb && tree-sitter generate && tree-sitter build --wasm",
5051
"watch": "webpack --watch",
51-
"precommit": "yarn build && yarn fmt && yarn lint --fix && yarn run lint:css --fix",
52+
"precommit": "yarn build && yarn fmt && yarn lint:ts --fix && yarn run lint:css --fix",
5253
"test:grammars": "yarn test:grammars:tolk && yarn test:grammars:func && yarn test:grammars:fift && yarn test:grammars:tlb",
5354
"test:grammars:tolk": "cd ./server/src/languages/tolk/tree-sitter-tolk/ && tree-sitter test",
5455
"test:grammars:func": "cd ./server/src/languages/func/tree-sitter-func/ && tree-sitter test",

0 commit comments

Comments
 (0)