work around broken bash in azure pipelines

This commit is contained in:
Anthony Sottile
2020-01-21 14:58:03 -08:00
parent dde988bd38
commit 32d32e3743
+1 -1
View File
@@ -307,7 +307,7 @@ EXISTING_COMMIT_RUN = re.compile(
def _write_legacy_hook(path):
os.makedirs(os.path.join(path, '.git/hooks'), exist_ok=True)
with open(os.path.join(path, '.git/hooks/pre-commit'), 'w') as f:
f.write('#!/usr/bin/env bash\necho "legacy hook"\n')
f.write(f'{shebang()}\nprint("legacy hook")\n')
make_executable(f.name)