git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Weird behavior of shell variables in git aliases
@ 2011-03-21 16:39 Dun Peal
  2011-03-21 21:53 ` Jeff King
  0 siblings, 1 reply; 20+ messages in thread
From: Dun Peal @ 2011-03-21 16:39 UTC (permalink / raw)
  To: git

It seems that a variable is available only once?!  How can the
following shell session be explained:

    $ git config alias.test0
    !echo $1
    $ git test0 foo
    foo
    $ git config alias.test1
    !echo $1 && echo $1
    $ git test1 foo

    foo
    $ git config alias.test2
    !BRANCH=$1 && echo $BRANCH && echo $BRANCH
    $ git test2 foo

    foo

Thanks, D.

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

end of thread, other threads:[~2011-03-23  3:01 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-03-21 16:39 Weird behavior of shell variables in git aliases Dun Peal
2011-03-21 21:53 ` Jeff King
2011-03-21 22:21   ` Junio C Hamano
2011-03-21 22:33     ` Junio C Hamano
2011-03-22 10:38       ` Lasse Makholm
2011-03-22 11:28         ` Jeff King
2011-03-22 12:59           ` Lasse Makholm
2011-03-22 10:52       ` Ævar Arnfjörð Bjarmason
2011-03-22 11:18       ` Jeff King
2011-03-22 13:28         ` Jeff King
2011-03-22 13:35           ` Lasse Makholm
2011-03-22 13:43             ` Jeff King
2011-03-22 13:53               ` Lasse Makholm
2011-03-22 15:06                 ` Dun Peal
2011-03-22 17:57               ` Junio C Hamano
2011-03-22 18:32                 ` Jeff King
2011-03-22 22:22                   ` Lasse Makholm
2011-03-23  3:01                     ` Junio C Hamano
2011-03-22 17:36           ` Junio C Hamano
2011-03-22 17:35         ` Junio C Hamano

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