git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jakub Narebski <jnareb@gmail.com>
To: Jeff King <peff@peff.net>
Cc: aaron smith <beingthexemplarylists@gmail.com>, git@vger.kernel.org
Subject: Re: suppress fatal pathspec errors from "git add"?
Date: Sun, 03 Jan 2010 01:44:02 -0800 (PST)	[thread overview]
Message-ID: <m33a2ncyj2.fsf@localhost.localdomain> (raw)
In-Reply-To: <20100103074058.GB23031@sigill.intra.peff.net>

Jeff King <peff@peff.net> writes:

> On Thu, Dec 31, 2009 at 01:24:59PM -0800, aaron smith wrote:
> 
> > I'm looking through the add documentation, I don't see a way to
> > suppress fatal pathspec errors? For example, if I'm adding 5 files,
> > but one of them is mis-spelled, can I have git just supress the errors
> > and add the other four?
> 
> Hmm. I would have thought "git add --ignore-errors" would do what you
> want, but it only ignores errors in reading the file. If we can't stat
> it, we will always die. IMHO that is an oversight in how
> "--ignore-errors" works (why should this one particular error be treated
> as fatal, when others are not?).

I have thought that this is task for --ignore-missing / --missing-ok
option, but this option(s) does not apply to git-add / git-rm; the former
is from git-write-index, the latter form from git-write-tree.

-- 
Jakub Narebski
Poland
ShadeHawk on #git

      parent reply	other threads:[~2010-01-03  9:50 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-31 21:24 suppress fatal pathspec errors from "git add"? aaron smith
2010-01-03  7:40 ` Jeff King
2010-01-03  8:00   ` aaron smith
2010-01-03  8:12   ` Junio C Hamano
2010-01-03  8:28     ` Jeff King
2010-01-03  9:44   ` Jakub Narebski [this message]

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=m33a2ncyj2.fsf@localhost.localdomain \
    --to=jnareb@gmail.com \
    --cc=beingthexemplarylists@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=peff@peff.net \
    /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).