Skip to content

Commit a5a934d

Browse files
authored
pre-commit: add hooks check-illegal-windows-names and file-contents-sorter (#11662)
1 parent 136ea3e commit a5a934d

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

.github/linters/codespell.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -375,6 +375,7 @@ propogate
375375
provison
376376
psudo
377377
pyhsical
378+
re-use
378379
readabilty
379380
readd
380381
reccuring
@@ -411,7 +412,6 @@ retriving
411412
retrun
412413
retuned
413414
returing
414-
re-use
415415
rever
416416
rocessor
417417
runing

.pre-commit-config.yaml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,12 @@ repos:
3232
name: run gitleaks
3333
description: detect hardcoded secrets
3434
- repo: https://github.com/pre-commit/pre-commit-hooks
35-
rev: v5.0.0
35+
rev: v6.0.0
3636
hooks:
3737
#- id: check-added-large-files
3838
- id: check-case-conflict
3939
#- id: check-executables-have-shebangs
40+
- id: check-illegal-windows-names
4041
- id: check-merge-conflict
4142
- id: check-shebang-scripts-are-executable
4243
files: \.sh$
@@ -50,7 +51,7 @@ repos:
5051
exclude: >
5152
(?x)
5253
^scripts/vm/systemvm/id_rsa\.cloud$|
53-
^server/src/test/java/org/apache/cloudstack/network/ssl/CertServiceTest.java$|
54+
^server/src/test/java/org/apache/cloudstack/network/ssl/CertServiceTest\.java$|
5455
^server/src/test/java/com/cloud/keystore/KeystoreTest\.java$|
5556
^server/src/test/resources/certs/dsa_self_signed\.key$|
5657
^server/src/test/resources/certs/non_root\.key$|
@@ -61,9 +62,12 @@ repos:
6162
^services/console-proxy/rdpconsole/src/test/doc/rdp-key\.pem$|
6263
^systemvm/agent/certs/localhost\.key$|
6364
^systemvm/agent/certs/realhostip\.key$|
64-
^test/integration/smoke/test_ssl_offloading.py$
65+
^test/integration/smoke/test_ssl_offloading\.py$
6566
- id: end-of-file-fixer
6667
exclude: \.vhd$
68+
- id: file-contents-sorter
69+
args: [--unique]
70+
files: ^\.github/linters/codespell\.txt$
6771
- id: fix-byte-order-marker
6872
- id: forbid-submodules
6973
- id: mixed-line-ending

0 commit comments

Comments
 (0)