Add check executables have shebangs (in pre-commit and CI) (#33703)

* Add check executables have shebangs (in pre-commit and CI)

* Fix file permissions

* Adjust Azure Pipelines
This commit is contained in:
Franck Nijhof
2020-04-05 18:45:43 +02:00
committed by GitHub
parent f89c73d79d
commit d33cf28936
22 changed files with 11 additions and 1 deletions
+1
View File
@@ -45,6 +45,7 @@ repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.4.0
hooks:
- id: check-executables-have-shebangs
- id: check-json
- id: no-commit-to-branch
args:
+4
View File
@@ -44,6 +44,10 @@ stages:
. venv/bin/activate
pip install -r requirements_test.txt -c homeassistant/package_constraints.txt
pre-commit install-hooks
- script: |
. venv/bin/activate
pre-commit run check-executables-have-shebangs --all-files
displayName: 'Run executables check'
- script: |
. venv/bin/activate
pre-commit run codespell --all-files
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
View File
+6 -1
View File
@@ -68,7 +68,12 @@ enum34==1000000000.0.0
pycrypto==1000000000.0.0
"""
IGNORE_PRE_COMMIT_HOOK_ID = ("check-json", "no-commit-to-branch", "prettier")
IGNORE_PRE_COMMIT_HOOK_ID = (
"check-executables-have-shebangs",
"check-json",
"no-commit-to-branch",
"prettier",
)
def has_tests(module: str):
View File
View File
View File
View File
View File
View File
View File
View File