Skip to content

Commit

Permalink
Use editorconfig-checker as a pre-commit
Browse files Browse the repository at this point in the history
  • Loading branch information
sbrunner committed Sep 18, 2024
1 parent 65074e2 commit 8ff149f
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 6 deletions.
11 changes: 11 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,17 @@ repos:
|\.prettierignore
|examples/svg\.html
)$
- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
rev: 3.0.3
hooks:
- id: editorconfig-checker
args:
- -disable-indentation
- -disable-max-line-length
exclude: |-
(?x)^(
secrets\.tar\.enc
)$
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.10.0.1
hooks:
Expand Down
6 changes: 1 addition & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ check-examples-checker: $(CHECK_EXAMPLE_CHECKER)
check-examples: $(BUILD_EXAMPLES_CHECK_TIMESTAMP_FILES)

.PHONY: lint
lint: .build/eslint.timestamp .build/eslint-ts.timestamp eclint lint-extra
lint: .build/eslint.timestamp .build/eslint-ts.timestamp lint-extra

.PHONY: lint-extra
lint-extra:
Expand All @@ -127,10 +127,6 @@ lint-extra:
.PHONY: eslint
eslint: .build/eslint.timestamp .build/eslint-ts.timestamp

.PHONY: eclint
eclint: .build/node_modules.timestamp
npm run eclint

.PHONY: test
test: .build/node_modules.timestamp .build/build-dll.timestamp
TS_NODE_PROJECT=disable.json ./node_modules/karma/bin/karma start karma-conf.js --single-run
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
"build-gmf-examples": "TARGET=gmf-examples webpack --mode=development --progress",
"build-gmf-apps": "TARGET=gmf-apps webpack --mode=development --progress",
"build-api": "webpack --config buildtools/webpack.api.js --mode=production --progress",
"eclint": "editorconfig-checker -disable-indentation -disable-max-line-length --exclude secrets.tar.enc",
"serve-ngeo-examples": "DEV_SERVER=1 TARGET=ngeo-examples webpack serve --open --server-type=https --server-options-cert=private.crt --server-options-key=private.key --port=3000 --mode=development --progress --watch",
"serve-gmf-examples": "DEV_SERVER=1 TARGET=gmf-examples webpack serve --open --server-type=https --server-options-cert=private.crt --server-options-key=private.key --port=3000 --mode=development --progress --watch",
"serve-gmf-apps": "DEV_SERVER=1 TARGET=gmf-apps webpack serve --open --server-type=https --server-options-cert=private.crt --server-options-key=private.key --port=3000 --mode=development --progress",
Expand Down

0 comments on commit 8ff149f

Please sign in to comment.