Read more

git "fatal: bad config file line" after checking out branch

Thomas Eisenbarth
January 31, 2013Software engineer at makandra GmbH

If git gives you an error message such as "fatal: bad config file line 123 in .git/config" after you tried to checkout a branch with a very long branch name, you very likely come across a bug in git version < 1.8.

Illustration online protection

Rails Long Term Support

Rails LTS provides security patches for old versions of Ruby on Rails (2.3, 3.2, 4.2 and 5.2)

  • Prevents you from data breaches and liability risks
  • Upgrade at your own pace
  • Works with modern Rubies
Read more Show archive.org snapshot

You should ask someone with a newer git version (someone pushed the branch right?) to rename the branch to something shorter:

git -m old-very-very-long-branch-name new-short-branch-name
Posted by Thomas Eisenbarth to makandra dev (2013-01-31 12:13)