From bd70bc119d0c8ec42ae8ea21baf481fda2fc4c53 Mon Sep 17 00:00:00 2001 From: MDW Date: Thu, 26 May 2022 17:31:24 +0200 Subject: [PATCH] Add instruction to change executable mode on windows --- pre_commit_hooks/check_shebang_scripts_are_executable.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pre_commit_hooks/check_shebang_scripts_are_executable.py b/pre_commit_hooks/check_shebang_scripts_are_executable.py index 0f35650b..621696ce 100644 --- a/pre_commit_hooks/check_shebang_scripts_are_executable.py +++ b/pre_commit_hooks/check_shebang_scripts_are_executable.py @@ -34,6 +34,8 @@ def _message(path: str) -> None: f'{path}: has a shebang but is not marked executable!\n' f' If it is supposed to be executable, try: ' f'`chmod +x {shlex.quote(path)}`\n' + f' If on Windows, you may also need to: ' + f'`git add --chmod=+x {shlex.quote(path)}`\n' f' If it not supposed to be executable, double-check its shebang ' f'is wanted.\n', file=sys.stderr,