Merge pull request #1339 from andrewhare/andrewhare/post-checkout

Add post-checkout
This commit is contained in:
Anthony Sottile 2020-02-23 10:39:28 -08:00 committed by GitHub
commit 566f1afcd4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 77 additions and 5 deletions

View file

@ -325,6 +325,9 @@ def run(
environ['PRE_COMMIT_REMOTE_NAME'] = args.remote_name
environ['PRE_COMMIT_REMOTE_URL'] = args.remote_url
if args.checkout_type:
environ['PRE_COMMIT_CHECKOUT_TYPE'] = args.checkout_type
with contextlib.ExitStack() as exit_stack:
if stash:
exit_stack.enter_context(staged_files_only(store.directory))