Repository specific config file

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

Repository specific config file

From: Pekka Riikonen <hidden>
Date: 2016-06-15 22:43:39

Hello,

Has there been any discussion or considerations adding a repository 
specific config file that would be delivered to all cloned repositories 
automatically?  This would allow the publisher of the repository to set up 
some default settings to all developers cloning the repository.  This 
could be useful to set up things like default aliases to ease up the work, 
to set that all remote branches are tracked, to list the configurations of 
submodules (so that people don't have to run submodule init), etc.

User should still be able to add configurations that overlap with the 
remote configuration and user should be able to ignore everything that 
came from the parent.  Using ~/.gitconfig and /etc/gitconfig doesn't 
always work well when the developers don't have access to the remote 
machine (other than to clone the repository).  Maybe the simplest solution 
would be to just add .gitconfig to the repository itself.

 	Pekka
________________________________________________________________________
  Pekka Riikonen                                 priikone at silcnet.org
  Secure Internet Live Conferencing (SILC)       http://silcnet.org/

Re: Repository specific config file

From: Johannes Schindelin <hidden>
Date: 2016-06-15 22:43:39

Hi,

On Sun, 7 Oct 2007, Pekka Riikonen wrote:
Has there been any discussion or considerations adding a repository 
specific config file that would be delivered to all cloned repositories 
automatically? This would allow the publisher of the repository to set 
up some default settings to all developers cloning the repository.
Sure!  Just check in the file "gitconfig" and tell the good users that 
they can append it to their config with "cat gitconfig >> .git/config".

Or have a script "gitconfig.sh" containing calls to "git config" which the 
users can execute.

But you should not _force_ people to have a certain config.  It's their 
choice.

Ciao,
Dscho
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help