Use git-config to Break your Config File
- From
David E. Wheeler <david@justatheory.com>
- Date
- Apr 24, 2012, 02:57 UTC
- Message-ID
- <9E01F5E2-FB51-418D-B50C-EB6DC63A4F84@justatheory.com>
Gitsters,
I was fooling around and realized that I could assign an empty string as the name of a config section, like so:
$ git config --rename-section my ''
This leaves the config file looking like this:
[]
foo = goodbyeWhich does not appear to be valid:
$ git config --get '.foo'
fatal: bad config file line 13 in .git/configSo maybe git-config should disallow setting a section to an empty string?
Best,
David