git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Javier Domingo Cansino <javierdo1@gmail.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Jeff King <peff@peff.net>, Ryan Jacobs <ryan.mjacobs@gmail.com>,
	"git@vger.kernel.org" <git@vger.kernel.org>
Subject: Re: Fwd: Add git ignore as builtin
Date: Sun, 23 Nov 2014 20:25:15 +0100	[thread overview]
Message-ID: <CALZVapm0VJ9JsT3Ur86F-vYFMoRtKgDiJ3PO_aYPRyNFgz6iEw@mail.gmail.com> (raw)
In-Reply-To: <xmqq8uj9y0ck.fsf@gitster.dls.corp.google.com>

I would love to have such tool included in the toolchain, but being
able to use it to edit all the ignore chain, defaulting to .gitignore.
Explain the reason in my case.

Usually, when ignoring stuff, you will probable ignore already your
IDE/Editor files using a global gitignore. And most of the times in a
per-project basis, you will be ignoring their output files. I only use
.git/info/exclude when I have something really special that I don't
want to share publicly, such as a data/ folder to run the project or
so.

That way, most of the times I will be modifying .gitignore, sometimes
my global gitignore and very occasionally, .git/info/exclude.

That's my case, and that I know of, people have that usage order,
.gitignore > global gitignore > local gitignore.

For sake of uniformity, I would use the same context specifiers as in
git-config. Defaulting to --repo for .gitignore, using --local for the
.git/info/exclue, using --global for the global gitignore, and
--system for the system one.

Also, about adding and excluding, I would recommend using verbs
instead of arguments, which would be in consonance with git remote.

git ignore exclude ....
git ignore include ....

You could also make it "smart" by allowing to use it as the Cisco
managing commands, or the ip tool (ip a == ip address, ip a a == ip
addr add, etc.), resulting in the following:
git ignore e ....
git ignore i ....

-- 
Javier Domingo Cansino

      reply	other threads:[~2014-11-23 19:25 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CA+mQAOXPZSv2B8tVfC=4eJ7X_2j8Di4BkuE=z43=U2+VNpdQQg@mail.gmail.com>
2014-11-15 11:22 ` Fwd: Add git ignore as builtin Alberto Fanjul Alonso
2014-11-17  0:12   ` Ryan Jacobs
2014-11-17 20:59     ` Jeff King
2014-11-17 21:38       ` Junio C Hamano
2014-11-23 19:25         ` Javier Domingo Cansino [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=CALZVapm0VJ9JsT3Ur86F-vYFMoRtKgDiJ3PO_aYPRyNFgz6iEw@mail.gmail.com \
    --to=javierdo1@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=peff@peff.net \
    --cc=ryan.mjacobs@gmail.com \
    /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).