diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-03-19 10:19:07 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-03-19 10:19:07 +0000 |
commit | 48bb2fbcf5dc4b7c775f9745dcd2a02588e37300 (patch) | |
tree | 610ea82daf36c55d57749047efe9baf484b99f0b /pre_commit/commands/run.py | |
parent | Releasing debian version 3.1.1-1. (diff) | |
download | pre-commit-48bb2fbcf5dc4b7c775f9745dcd2a02588e37300.tar.xz pre-commit-48bb2fbcf5dc4b7c775f9745dcd2a02588e37300.zip |
Merging upstream version 3.2.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | pre_commit/commands/run.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/pre_commit/commands/run.py b/pre_commit/commands/run.py index c9bc55b..c867799 100644 --- a/pre_commit/commands/run.py +++ b/pre_commit/commands/run.py @@ -254,6 +254,7 @@ def _all_filenames(args: argparse.Namespace) -> Collection[str]: # these hooks do not operate on files if args.hook_stage in { 'post-checkout', 'post-commit', 'post-merge', 'post-rewrite', + 'pre-rebase', }: return () elif args.hook_stage in {'prepare-commit-msg', 'commit-msg'}: @@ -389,6 +390,10 @@ def run( environ['PRE_COMMIT_FROM_REF'] = args.from_ref environ['PRE_COMMIT_TO_REF'] = args.to_ref + if args.pre_rebase_upstream and args.pre_rebase_branch: + environ['PRE_COMMIT_PRE_REBASE_UPSTREAM'] = args.pre_rebase_upstream + environ['PRE_COMMIT_PRE_REBASE_BRANCH'] = args.pre_rebase_branch + if ( args.remote_name and args.remote_url and args.remote_branch and args.local_branch |