Git development
 help / color / mirror / Atom feed
From: Frans Pop <elendil@planet.nl>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: Conflicting "-n" short options for git-pull?
Date: Sun, 16 Sep 2007 13:17:11 +0200	[thread overview]
Message-ID: <200709161317.12339.elendil@planet.nl> (raw)
In-Reply-To: <7vfy1f8pmm.fsf@gitster.siamese.dyndns.org>

On Sunday 16 September 2007, Junio C Hamano wrote:
> Frans Pop <elendil@planet.nl> writes:
> > According to the man page for git-pull from git-core 1.5.3.1 (Debian
> > package), two options are defined as having the short option "-n":
> >
> >      -n, --no-summary
> >          Do not show diffstat at the end of the merge.
> > [...]
> >      -n, --no-tags
> >          By default, git-fetch fetches tags that point at objects that
> > are downloaded from the remote repository and stores them locally. This
> > option disables this automatic tag following.
>
> The manpage option descriptions are shared between the
> commands.  Maybe we should drop mention of the shorthand form.

Not sure if that last is the correct solution. Wouldn't it mean that short 
options would not be documented at all anymore?

> When git-fetch is used -n means --no-tags because there is no
> other -n; when git-pull indirectly invokes git-fetch, you need
> to spell it --no-tags because --no-summary takes precedence.

That does explain, but it is not at all obvious from the documentation.
Guess this is a general "problem" in git then.


Another question.
Is it possible to set default options for commands somehow?
I'd like to run git-pull with '--no-summary' by default. I could of course 
define an alias, but that only covers 'git-pull' and not 'git pull'.
Does git itself have some mechanism for this?

Thanks,
Frans Pop

      reply	other threads:[~2007-09-16 11:17 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-15 19:14 Conflicting "-n" short options for git-pull? Frans Pop
2007-09-15 23:39 ` Junio C Hamano
2007-09-16 11:17   ` Frans Pop [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=200709161317.12339.elendil@planet.nl \
    --to=elendil@planet.nl \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.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