* recursive aliases
@ 2010-09-23 6:07 Ramana Kumar
2010-09-23 11:34 ` Andreas Ericsson
0 siblings, 1 reply; 3+ messages in thread
From: Ramana Kumar @ 2010-09-23 6:07 UTC (permalink / raw)
To: git
Are recursive aliases in any way allowed?
What about aliases that don't refer to themselves, but refer to other aliases?
Obviously I can just call git from the shell with a ! alias, but
wondering if there's any better way.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: recursive aliases
2010-09-23 6:07 recursive aliases Ramana Kumar
@ 2010-09-23 11:34 ` Andreas Ericsson
2010-09-23 22:49 ` Andreas Schwab
0 siblings, 1 reply; 3+ messages in thread
From: Andreas Ericsson @ 2010-09-23 11:34 UTC (permalink / raw)
To: Ramana Kumar; +Cc: git
On 09/23/2010 08:07 AM, Ramana Kumar wrote:
> Are recursive aliases in any way allowed?
They're not just not allowed; they're not even possible.
> What about aliases that don't refer to themselves, but refer to other aliases?
>
Again, this isn't possible. How could you configure something like that?
> Obviously I can just call git from the shell with a ! alias, but
> wondering if there's any better way.
There isn't. The simple aliases are there to let you run certain
commands with certain default parameters as a new command. Normal
commands have no way of calling other commands (or themselves)
recursively. That's what shell-scripts are for.
--
Andreas Ericsson andreas.ericsson@op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
Considering the successes of the wars on alcohol, poverty, drugs and
terror, I think we should give some serious thought to declaring war
on peace.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: recursive aliases
2010-09-23 11:34 ` Andreas Ericsson
@ 2010-09-23 22:49 ` Andreas Schwab
0 siblings, 0 replies; 3+ messages in thread
From: Andreas Schwab @ 2010-09-23 22:49 UTC (permalink / raw)
To: Andreas Ericsson; +Cc: Ramana Kumar, git
Andreas Ericsson <ae@op5.se> writes:
> On 09/23/2010 08:07 AM, Ramana Kumar wrote:
>> Are recursive aliases in any way allowed?
>
> They're not just not allowed; they're not even possible.
$ git config alias.foo foo
$ git foo
fatal: recursive alias: foo
:-)
Andreas.
--
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-09-23 22:50 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-09-23 6:07 recursive aliases Ramana Kumar
2010-09-23 11:34 ` Andreas Ericsson
2010-09-23 22:49 ` Andreas Schwab
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).