git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] Document git aliases support
@ 2006-06-07 18:43 Petr Baudis
  2006-06-07 18:58 ` Junio C Hamano
  0 siblings, 1 reply; 4+ messages in thread
From: Petr Baudis @ 2006-06-07 18:43 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: git

This patch ports and modifies appropriately the git aliases documentation
from my patch, shall it rest in peace.

Signed-off-by: Petr Baudis <pasky@suse.cz>
---

 Documentation/config.txt |    7 +++++++
 Documentation/git.txt    |    3 +++
 2 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/Documentation/config.txt b/Documentation/config.txt
index c861c6c..ad9ec3e 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -91,6 +91,13 @@ core.warnAmbiguousRefs::
 	If true, git will warn you if the ref name you passed it is ambiguous
 	and might match multiple refs in the .git/refs/ tree. True by default.
 
+alias.*::
+	Command aliases for the gitlink:git[1] command wrapper - e.g.
+	after defining "alias.last = cat-file commit HEAD", the invocation
+	"git last" is equivalent to "git cat-file commit HEAD". You cannot
+	override even existing command names with aliases. Arguments are
+	split by spaces, the usual shell quoting and escaping is supported.
+
 apply.whitespace::
 	Tells `git-apply` how to handle whitespaces, in the same way
 	as the '--whitespace' option. See gitlink:git-apply[1].
diff --git a/Documentation/git.txt b/Documentation/git.txt
index 24ca55d..e474bdf 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -21,6 +21,9 @@ link:everyday.html[Everyday Git] for a u
 "man git-commandname" for documentation of each command.  CVS users may
 also want to read link:cvs-migration.html[CVS migration].
 
+The COMMAND is either a name of a Git command (see below) or an alias
+as defined in the configuration file (see gitlink:git-repo-config[1]).
+
 OPTIONS
 -------
 --version::

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] Document git aliases support
@ 2006-06-07 18:43 Petr Baudis
  0 siblings, 0 replies; 4+ messages in thread
From: Petr Baudis @ 2006-06-07 18:43 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: git

This patch ports and modifies appropriately the git aliases documentation
from my patch, shall it rest in peace.

Signed-off-by: Petr Baudis <pasky@suse.cz>
---

 Documentation/config.txt |    7 +++++++
 Documentation/git.txt    |    3 +++
 2 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/Documentation/config.txt b/Documentation/config.txt
index c861c6c..ad9ec3e 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -91,6 +91,13 @@ core.warnAmbiguousRefs::
 	If true, git will warn you if the ref name you passed it is ambiguous
 	and might match multiple refs in the .git/refs/ tree. True by default.
 
+alias.*::
+	Command aliases for the gitlink:git[1] command wrapper - e.g.
+	after defining "alias.last = cat-file commit HEAD", the invocation
+	"git last" is equivalent to "git cat-file commit HEAD". You cannot
+	override even existing command names with aliases. Arguments are
+	split by spaces, the usual shell quoting and escaping is supported.
+
 apply.whitespace::
 	Tells `git-apply` how to handle whitespaces, in the same way
 	as the '--whitespace' option. See gitlink:git-apply[1].
diff --git a/Documentation/git.txt b/Documentation/git.txt
index 24ca55d..e474bdf 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -21,6 +21,9 @@ link:everyday.html[Everyday Git] for a u
 "man git-commandname" for documentation of each command.  CVS users may
 also want to read link:cvs-migration.html[CVS migration].
 
+The COMMAND is either a name of a Git command (see below) or an alias
+as defined in the configuration file (see gitlink:git-repo-config[1]).
+
 OPTIONS
 -------
 --version::

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] Document git aliases support
  2006-06-07 18:43 [PATCH] Document git aliases support Petr Baudis
@ 2006-06-07 18:58 ` Junio C Hamano
  2006-06-07 20:11   ` Petr Baudis
  0 siblings, 1 reply; 4+ messages in thread
From: Junio C Hamano @ 2006-06-07 18:58 UTC (permalink / raw)
  To: git

Petr Baudis <pasky@suse.cz> writes:

>  Documentation/config.txt |    7 +++++++
>  Documentation/git.txt    |    3 +++
>  2 files changed, 10 insertions(+), 0 deletions(-)

Thanks.

> diff --git a/Documentation/config.txt b/Documentation/config.txt
> index c861c6c..ad9ec3e 100644
> --- a/Documentation/config.txt
> +++ b/Documentation/config.txt
> @@ -91,6 +91,13 @@ core.warnAmbiguousRefs::
>  	If true, git will warn you if the ref name you passed it is ambiguous
>  	and might match multiple refs in the .git/refs/ tree. True by default.
>  
> +alias.*::
> +	Command aliases for the gitlink:git[1] command wrapper - e.g.
> +	after defining "alias.last = cat-file commit HEAD", the invocation
> +	"git last" is equivalent to "git cat-file commit HEAD". You cannot
> +	override even existing command names with aliases. Arguments are
> +	split by spaces, the usual shell quoting and escaping is supported.
> +

"even"?  How about: "alias that hides existing command names are
not used to avoid confusion"?

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [PATCH] Document git aliases support
  2006-06-07 18:58 ` Junio C Hamano
@ 2006-06-07 20:11   ` Petr Baudis
  0 siblings, 0 replies; 4+ messages in thread
From: Petr Baudis @ 2006-06-07 20:11 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: git

Dear diary, on Wed, Jun 07, 2006 at 08:58:57PM CEST, I got a letter
where Junio C Hamano <junkio@cox.net> said that...
> Petr Baudis <pasky@suse.cz> writes:
> > diff --git a/Documentation/config.txt b/Documentation/config.txt
> > index c861c6c..ad9ec3e 100644
> > --- a/Documentation/config.txt
> > +++ b/Documentation/config.txt
> > @@ -91,6 +91,13 @@ core.warnAmbiguousRefs::
> >  	If true, git will warn you if the ref name you passed it is ambiguous
> >  	and might match multiple refs in the .git/refs/ tree. True by default.
> >  
> > +alias.*::
> > +	Command aliases for the gitlink:git[1] command wrapper - e.g.
> > +	after defining "alias.last = cat-file commit HEAD", the invocation
> > +	"git last" is equivalent to "git cat-file commit HEAD". You cannot
> > +	override even existing command names with aliases. Arguments are
> > +	split by spaces, the usual shell quoting and escaping is supported.
> > +
> 
> "even"?  How about: "alias that hides existing command names are
> not used to avoid confusion"?

Oops, that "even" was not meant to be there. I have rephrased it a bit.

---

This patch ports and modifies appropriately the git aliases documentation
from my patch, shall it rest in peace.

Signed-off-by: Petr Baudis <pasky@suse.cz>
---

 Documentation/config.txt |    8 ++++++++
 Documentation/git.txt    |    3 +++
 2 files changed, 11 insertions(+), 0 deletions(-)

diff --git a/Documentation/config.txt b/Documentation/config.txt
index c861c6c..91615c1 100644
--- a/Documentation/config.txt
+++ b/Documentation/config.txt
@@ -91,6 +91,14 @@ core.warnAmbiguousRefs::
 	If true, git will warn you if the ref name you passed it is ambiguous
 	and might match multiple refs in the .git/refs/ tree. True by default.
 
+alias.*::
+	Command aliases for the gitlink:git[1] command wrapper - e.g.
+	after defining "alias.last = cat-file commit HEAD", the invocation
+	"git last" is equivalent to "git cat-file commit HEAD". It is not
+	allowed to redefine existing command names using aliases to avoid
+	confusion and troubles with script usage. Arguments are split by
+	spaces, the usual shell quoting and escaping is supported.
+
 apply.whitespace::
 	Tells `git-apply` how to handle whitespaces, in the same way
 	as the '--whitespace' option. See gitlink:git-apply[1].
diff --git a/Documentation/git.txt b/Documentation/git.txt
index 24ca55d..e474bdf 100644
--- a/Documentation/git.txt
+++ b/Documentation/git.txt
@@ -21,6 +21,9 @@ link:everyday.html[Everyday Git] for a u
 "man git-commandname" for documentation of each command.  CVS users may
 also want to read link:cvs-migration.html[CVS migration].
 
+The COMMAND is either a name of a Git command (see below) or an alias
+as defined in the configuration file (see gitlink:git-repo-config[1]).
+
 OPTIONS
 -------
 --version::

-- 
				Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
A person is just about as big as the things that make them angry.

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2006-06-07 20:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-06-07 18:43 [PATCH] Document git aliases support Petr Baudis
2006-06-07 18:58 ` Junio C Hamano
2006-06-07 20:11   ` Petr Baudis
  -- strict thread matches above, loose matches on Subject: below --
2006-06-07 18:43 Petr Baudis

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).