This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Distributed Git not compiled under Cygwin?


On 12/29/2011 02:28 PM, cxira wrote:
> 
> 
> Jeremy Bopp-3 wrote:
>> I never had a problem with the native gVim cooperating with Cygwin's Git
>> (more accurately file permissions) either.  Can you provide more detail
>> about your situation?  How exactly are the permissions broken, and for
>> which application(s) are they broken?
> 
> Here's what I see:
> $ gvim temp
> :wq
> $ ls -al temp
> -rwx------+ 1 Doug None 0 Dec 29 15:21 temp
> 
> Expected:
> $ touch temp2
> $ ls -al temp2
> -rw-r--r--+ 1 Doug None 0 Dec 29 15:22 temp2
> 
> It isn't a problem that causes a conflict with anything, but if I commit
> these files to the repository with their file modes as 0700, other people
> that use the repository may have problems with them (not to mention the show
> in as green executables in ls). I actually pushed these files to an Apache
> webserver for production one time and the entire site was not working for a
> bit because of that.

The execute bit is the only permission that Git actually records:

http://book.git-scm.com/1_the_git_object_model.html

Unfortunately, it's the only one that's giving you grief here.  You
might try setting the noacl mount option for the Cygwin mount containing
your repository:

http://cygwin.com/cygwin-ug-net/using.html#mount-table

Another option may be to hack a post-save action into gVim that uses
Cygwin's chmod command to remove the execute bit from newly saved files:

http://stackoverflow.com/questions/4627701/vim-how-to-execute-automatically-execute-a-shell-command-after-saving-a-file

If all else fails, you could also install the Windows-native build of
Git and use that instead.  Cygwin's gVim may also make sense to use here
instead of the native one, but I remember you saying that the native
gVim integrates better for what you do.

-Jeremy

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]