From: Jakub Narebski <jnareb@gmail.com>
To: Michael J Gruber <git@drmicha.warpmail.net>
Cc: David Reitter <david.reitter@gmail.com>, git@vger.kernel.org
Subject: Re: git config -> "fatal: bad config file"
Date: Fri, 14 Aug 2009 07:28:23 -0700 (PDT) [thread overview]
Message-ID: <m3ocqio4gz.fsf@localhost.localdomain> (raw)
In-Reply-To: <4A85724C.5060406@drmicha.warpmail.net>
Michael J Gruber <git@drmicha.warpmail.net> writes:
> David Reitter venit, vidit, dixit 14.08.2009 15:38:
> > I made a mistake editing my config file using "git config -e". This
> > caused git commands to fail.
> >
> > Trying to fix the problem, I did
> >
> > git config -e
> > fatal: bad config file line 7 in .git/config
> >
> > I think the refusal to edit a broken config file is not a good idea.
> > It's easy to fix for me of course by editing .git/config directly, but
> > git-config should probably not read the config file at all.
> >
> > Thanks for your consideration.
> >
>
> git needs to read the file because the editor could be configured there!
> The only option would be to make git config -e continue past that error.
Well, it shows you which file the error is, but I think as a special
case "git config [file] --edit" should show also (absolute?) pathname
of the file it tired to open.
core.editor can be in any place.
--
Jakub Narebski
Poland
ShadeHawk on #git
next prev parent reply other threads:[~2009-08-14 14:28 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-14 13:38 git config -> "fatal: bad config file" David Reitter
2009-08-14 14:18 ` Michael J Gruber
2009-08-14 14:26 ` David Reitter
2009-08-14 14:28 ` Jakub Narebski [this message]
2009-08-14 15:10 ` [PATCH] git-config: Parse config files leniently Michael J Gruber
2009-08-14 19:52 ` Junio C Hamano
2009-08-17 18:47 ` Michael J Gruber
2009-08-17 19:49 ` Junio C Hamano
2009-09-02 20:17 ` [PATCHv2] " Michael J Gruber
2009-09-03 7:00 ` Junio C Hamano
2009-09-03 7:41 ` Michael J Gruber
2009-09-03 23:42 ` Junio C Hamano
2009-09-04 7:13 ` Michael J Gruber
2009-09-04 8:40 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m3ocqio4gz.fsf@localhost.localdomain \
--to=jnareb@gmail.com \
--cc=david.reitter@gmail.com \
--cc=git@drmicha.warpmail.net \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).