You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After installing, or when running mix git_hooks.install, I get multiple fatal: --git-path requires an argument.
I believe this is because there are cases that use some git commands incorrectly.
This calls resolve_git_path_based_on_git_version without any arguments.
That function then seems to default to "" and hence calls git rev-parse with the relevant argument missing:
After installing, or when running
mix git_hooks.install
, I get multiplefatal: --git-path requires an argument
.I believe this is because there are cases that use some git commands incorrectly.
One example that I found seems to be here:
elixir_git_hooks/lib/git/path.ex
Lines 23 to 24 in 79b9aec
This calls
resolve_git_path_based_on_git_version
without any arguments.That function then seems to default to
""
and hence calls git rev-parse with the relevant argument missing:elixir_git_hooks/lib/git/path.ex
Lines 56 to 70 in 79b9aec
Let's see what rev-parse does with
--git-path
but with no further arguments:Aha. That same function,
resolve_git_path_based_on_git_version
, seems to also have a case that uses--git-dir
. Let's see what that one does:No errors there. Maybe the expected git rev-parse behavior changed?
Tested under Windows 11.
The text was updated successfully, but these errors were encountered: