Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify redate behaviour during cherry-picks #9

Open
cburkert opened this issue May 4, 2020 · 4 comments
Open

Unify redate behaviour during cherry-picks #9

cburkert opened this issue May 4, 2020 · 4 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@cburkert
Copy link
Member

cburkert commented May 4, 2020

Newer versions of Git (since when?) now trigger post-commit hooks during a cherry-pick which invokes redate. This causes a different user experience than for older version where no redating took place during cherry-picks.

@cburkert
Copy link
Member Author

cburkert commented May 4, 2020

As of now, I found no reliable why to detect, whether post-commit is triggered as a result of a cherry-pick. Looking for the presence of CHERRY_PICK_HEAD is not reliable since it constitutes a race condition, because it vanishes as soon as the cherry pick is finished, which can be before, during or after the post-commit hook is invoked.

@cburkert
Copy link
Member Author

cburkert commented May 4, 2020

Related to fc0047b

@cburkert cburkert added enhancement New feature or request help wanted Extra attention is needed labels May 4, 2020
@fapdash
Copy link
Contributor

fapdash commented May 5, 2020

@cburkert Can you detect a cherry pick at the time a pre-commit hook is triggered?

@cburkert
Copy link
Member Author

cburkert commented May 6, 2020

@fapdash Strangely, my experiments show that a cherry-pick does not trigger a pre-commit hook. More indication that the triggering of post-commit is a bug of Git...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants