Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jgit-dev] Why is core.filemode set to true for a new or a cloned Repository?

tisdagen den 14 september 2010 13.26.21 skrev  Lay, Stefan:
> I wonder why in FileRepository.create the config setting core.filemode is
> always set to true.
> I (unfortunately) work with Windows and clone a repo which was created on a
> Mac. Although I have set core.filemode to false in the global config I get
> dirty markers in the UI. The reason is that the cloned repository gets the
> setting core.filemode true.

Git for Windows has core.filemode set to false in /etc/gitconfig. 
Unfortunately JGit has no idea where /etc is on Windows since it is a 
directory tied a particular Git installation. It is not even unique
since you can have more than one installation, each with a different /etc.

We should have a workaround for this. That could be an environment variable,
a setting in ~/.gitconfig, a system property or (in Eclipse) a workspace 
setting or we could (if git is in the path, ask git for it).

-- robin

Back to the top