Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to stop git from making files non-executable on cygwin?

I use git on Windows via cygwin and soon decided to use filemode=false (since otherwise I've got a lot of changes after the initial git clone). I'm definitely not interested in tracking permission at all, the only think I need is for some files to be executable. From time to time, I find that the x flag on some files gets lost and I strongly suppose it's because of git.

I'd be happy with a solution allowing to execute chmod a+x ... when needed.

like image 310
maaartinus Avatar asked Aug 13 '11 01:08

maaartinus


1 Answers

I believe you want git update-index --chmod=+x <file>, followed by a commit.

like image 93
Karl Bielefeldt Avatar answered Sep 23 '22 06:09

Karl Bielefeldt