From: Pete Wyckoff <pw@padd.com>
To: Junio C Hamano <gitster@pobox.com>
Cc: Clemens Buchacher <drizzd@aon.at>,
git@vger.kernel.org, Luke Diamand <luke@diamand.org>,
Vitor Antunes <vitor.hda@gmail.com>
Subject: Re: [RFC PATCH 0/3] git-p4: move to toplevel
Date: Mon, 13 Feb 2012 18:32:45 -0500 [thread overview]
Message-ID: <20120213233245.GA29582@padd.com> (raw)
In-Reply-To: <7vhayuctwm.fsf@alter.siamese.dyndns.org>
gitster@pobox.com wrote on Mon, 13 Feb 2012 13:20 -0800:
> Clemens Buchacher <drizzd@aon.at> writes:
>
> >> Erm,... do you really need the alias if you add git-p4 in a directory on
> >> your $PATH?
> >
> > With recent git versions, this has stopped working.
>
> Erm, I am confused.
>
> $ git --exec-path
> /home/junio/g/Debian-6.X-x86_64/git-jch/libexec/git-core
> $ type git-hello
> bash: type: git-hello: not found
> $ cat >~/bin/common/git-hello <<EOF
> #!/bin/sh
> echo hello world
> EOF
> $ chmod +x ~/bin/common/git-hello
> $ type git-hello
> git-hello is /home/junio/bin/common/git-hello
> $ git hello
> hello world
>
> What am I missing???
Neat. I never knew this worked. That lets me remove quite a
few aliases. Apparently this has been possible since the
conversion from git.sh to git.c.
I tried to find where in the documentation this is talked about,
or where it should go. This doesn't feel like the best spot,
though.
------------8<-----------
>From 574669898aa891ffe3e785b280ac36177116658e Mon Sep 17 00:00:00 2001
From: Pete Wyckoff <pw@padd.com>
Date: Mon, 13 Feb 2012 18:17:10 -0500
Subject: [PATCH] document git-<command> can be found in PATH
Explain up front to users that arbitrary git "commands" can
be found anywhere in the PATH. For example, ~/bin/git-hello
will be invoked by "git hello".
---
Documentation/git.txt | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/Documentation/git.txt b/Documentation/git.txt
index f7e201f..0ef7f40 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -30,6 +30,8 @@ introduction.
The '<command>' is either a name of a Git command (see below) or an alias
as defined in the configuration file (see linkgit:git-config[1]).
+A '<command>' can also refer to an executable with the name git-'<command>'
+anywhere in your PATH.
Formatted and hyperlinked version of the latest git
documentation can be viewed at
--
1.7.9.193.g1d4a5.dirty
next prev parent reply other threads:[~2012-02-13 23:33 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-12 18:13 [RFC PATCH 0/3] git-p4: move to toplevel Pete Wyckoff
2012-02-12 18:13 ` [RFC PATCH 1/3] " Pete Wyckoff
2012-02-12 18:13 ` [RFC PATCH 2/3] git p4: update name in script Pete Wyckoff
2012-02-12 18:13 ` [RFC PATCH 3/3] git p4: use "git p4" directly in tests Pete Wyckoff
2012-02-12 18:54 ` [RFC PATCH 0/3] git-p4: move to toplevel Luke Diamand
2012-02-13 6:17 ` Junio C Hamano
2012-02-13 23:37 ` Pete Wyckoff
2012-02-13 20:00 ` Junio C Hamano
2012-02-13 20:37 ` Clemens Buchacher
2012-02-13 21:20 ` Junio C Hamano
2012-02-13 23:32 ` Pete Wyckoff [this message]
2012-02-14 9:20 ` Clemens Buchacher
2012-02-14 18:40 ` Junio C Hamano
2012-02-14 19:05 ` Jeff King
2012-02-14 19:25 ` Junio C Hamano
2012-02-14 19:49 ` Clemens Buchacher
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=20120213233245.GA29582@padd.com \
--to=pw@padd.com \
--cc=drizzd@aon.at \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=luke@diamand.org \
--cc=vitor.hda@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).