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
{{ message }}
This repository has been archived by the owner on Nov 10, 2022. It is now read-only.
Today I try run this script on my windows machine: install-pre-commit-hook.sh and noticed it is printing some error "??? NO Such ?????" though if flashed out.
I googled how to prevent shell script cmd closing and luckily found "sleep x" could let the window stay. And finally I found the script stop after: cd "$(git rev-parse --git-dir)/hooks"
I open .git folder in the project and can't find any hooks folder there. I think that's why "NO SUCH ???" error raised.
I created one manually there and then run the script again. Now I can find something new in the new folder.
I never delete any folder in .git folder so not sure why the hooks folder is not there. But please add following code before cd to make sure it works: mkdir -p "$(git rev-parse --git-dir)/hooks"
The text was updated successfully, but these errors were encountered:
What version of Git do you have? It's strange that the hooks directory is not there, as normally it contains sample hooks. Are the other files and directories in the .git directory as normal, including branches, refs, info, etc?
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Today I try run this script on my windows machine: install-pre-commit-hook.sh and noticed it is printing some error "??? NO Such ?????" though if flashed out.
I googled how to prevent shell script cmd closing and luckily found "sleep x" could let the window stay. And finally I found the script stop after:
cd "$(git rev-parse --git-dir)/hooks"
I open .git folder in the project and can't find any hooks folder there. I think that's why "NO SUCH ???" error raised.
I created one manually there and then run the script again. Now I can find something new in the new folder.
I never delete any folder in .git folder so not sure why the hooks folder is not there. But please add following code before cd to make sure it works:
mkdir -p "$(git rev-parse --git-dir)/hooks"
The text was updated successfully, but these errors were encountered: