Why are all my files marked for deletion by Git after I do "git stash pop -q"?

95 views Asked by At

I'm trying to implement the Git hook code in the following thread (last post): Git: How to re-stage the staged files in a pre-commit hook . I place the following code in my post-commit hook git stash pop -q and after it has been executed, all my files in my project are marked for deletion(!) and I need to revert all the files to get back to normal state. Except for this, everything works fine, I'm able to modify (in the pre-commit hook) the file that was already staged for commit and the commit itself is successful and afterwards it contains what I want it to contain. What could I be doing wrong? I'm a Git-beginner so please use simple terminology.

1

There are 1 answers

0
Nathan Gouy On

the -q is the issue

quiet option seems buggy

https://www.spinics.net/lists/git/msg369570.html