Re: Bypassing hooks while cherry-picking

2016-03-03 Thread Grégoire PARIS
Le 03/03/2016 23:55, Junio C Hamano a écrit : Grégoire PARIS writes: Not sure how cherry-picking is managed, and whether commit is able to see that we are doing a cherry-pick, and end it up properly. Anyway, with Kevin's patch, we should be able to happily use

Re: Bypassing hooks while cherry-picking

2016-03-03 Thread Junio C Hamano
Grégoire PARIS writes: > Not sure how cherry-picking is managed, and whether commit is able to > see that we are doing a cherry-pick, and end it up properly. Anyway, > with Kevin's patch, we should be able to happily use cherry-pick [Please do not top post] It is

Re: Bypassing hooks while cherry-picking

2016-03-03 Thread Grégoire PARIS
Not sure how cherry-picking is managed, and whether commit is able to see that we are doing a cherry-pick, and end it up properly. Anyway, with Kevin's patch, we should be able to happily use cherry-pick greg0ire Le 03/03/2016 22:30, Junio C Hamano a écrit : greg0ire

Re: Bypassing hooks while cherry-picking

2016-03-03 Thread Grégoire PARIS
Oh great, glad to see that, good job! greg0ire Le 03/03/2016 22:17, Kevin Daudt a écrit : On Tue, Mar 01, 2016 at 12:01:53PM +0100, greg0ire wrote: Hello, using git 2.1.4 here, and it seems there is no option to bypass pre-commit hooks while cherry-picking, while git commit provides a

Re: Bypassing hooks while cherry-picking

2016-03-03 Thread Junio C Hamano
greg0ire writes: > Steps to reproduce : > > 1. create a pre-commit hook > 2. create a commit that fails the hook, and bypass the hook > 3. checkout another branch > 4. might be optional : create a conflicting change with the previously > created commit > 5. cherry-pick

Re: Bypassing hooks while cherry-picking

2016-03-03 Thread Kevin Daudt
On Tue, Mar 01, 2016 at 12:01:53PM +0100, greg0ire wrote: > Hello, > > using git 2.1.4 here, and it seems there is no option to bypass pre-commit > hooks while cherry-picking, while git commit provides a --no-verify option. > I ended up doing this to disable hooks while cherry picking : > >

Bypassing hooks while cherry-picking

2016-03-01 Thread greg0ire
Hello, using git 2.1.4 here, and it seems there is no option to bypass pre-commit hooks while cherry-picking, while git commit provides a --no-verify option. I ended up doing this to disable hooks while cherry picking : test -f "$GIT_DIR"/CHERRY_PICK_HEAD && exit 0 Wouldn't it be best