Re: Feature Request: Support logic or shell execution to control values in .gitconfig

2013-08-10 Thread Jonathan Nieder
Matthieu Moy wrote: That would mean executing SOMETEXTTOEXECUTE each time the config file is read. This raises two issues: * A security issue, as SOMETEXTTOEXECUTE could also be something dangerous. It would not be much worse than the current situation (if your config file is not

Feature Request: Support logic or shell execution to control values in .gitconfig

2013-08-08 Thread Morgan McClure
I sync all my dot files (including .gitconfig) among several machines and it's currently not possible to put conditional logic in many fields (any that aren't considered strings to be executed as shell commands ie aliases, editor, etc). My specific use case is the email address. Normally I want

Re: Feature Request: Support logic or shell execution to control values in .gitconfig

2013-08-08 Thread Matthieu Moy
Morgan McClure mcclure.mor...@gmail.com writes: I propose using something reminiscent of bash syntax, either: value = $(SOMETEXTTOEXECUTE) or value = `SOMETEXTTOEXECUTE` That would mean executing SOMETEXTTOEXECUTE each time the config file is read. This raises two issues: * A security

Re: Feature Request: Support logic or shell execution to control values in .gitconfig

2013-08-08 Thread Greg Troxel
Matthieu Moy matthieu@grenoble-inp.fr writes: What I suggest instead is to edit/track/share template configuration files like ~/.gitconfig.in email = me@HOSTNAME@ and then script something like sed -e s/@HOSTNAME@/$(hostname)/ ~/.gitconfig.in ~/.gitconfig. You may also use the