Re: git-gui: executed hooks are different from command-line git if hooksPath is set

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Jan,

On Mon, 1 Apr 2019, Jan Ziak wrote:

> Command-line "git commit" and graphical "git gui" commit are invoking
> different hooks if hooksPath is set in $HOME/.gitconfig.
>
> Namely, in my case command-line "git commit" runs
> "/home/atom/dev/git-hooks/post-commit" - while "git gui" commit runs
> ".git/hooks/post-commit".
>
> Please run the attached shell script in an empty directory to
> reproduce this issue. The script is using strace to determine which
> hook is being executed. The script will run "git gui": the user is
> expected to simply commit changes from the gui and then close the gui
> for the script to finish.
>
> Script output:
>   command-line: access("/home/atom/dev/git-hooks/post-commit", X_OK)
>   gui: access(".git/hooks/post-commit", X_OK)
>
> $ cat ~/.gitconfig
> [core]
>     hooksPath = /home/atom/dev/git-hooks

Could you give `master` of https://github.com/git-for-windows/git a try?
(Despite the name, we aim to keep it functional on the same platforms as
Git itself.)

I am fairly certain that I fixed it there, and contributed a PR to the Git
GUI project, but it seems that that project is in a kind of hibernating
state right now.

Ciao,
Johannes




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux