From: Gabriel Filion <lelutin@gmail.com>
To: Stephen Boyd <bebarino@gmail.com>
Cc: git@vger.kernel.org, Junio C Hamano <gitster@pobox.com>
Subject: Re: [PATCH] pull: replace unnecessary sed invocation
Date: Thu, 18 Mar 2010 09:30:22 -0400 [thread overview]
Message-ID: <4BA22AEE.8000606@gmail.com> (raw)
In-Reply-To: <1268889045-21751-1-git-send-email-bebarino@gmail.com>
On 2010-03-18 01:10, Stephen Boyd wrote:
> Getting the shortened branch name is as easy as using the shell's
> parameter expansion.
>
> curr_branch=$(git symbolic-ref -q HEAD)
> -curr_branch_short=$(echo "$curr_branch" | sed "s|refs/heads/||")
> +curr_branch_short="${curr_branch#refs/heads/}"
This modification is a bashism. This syntax is not compatible with other
shells.
--
Gabriel Filion
next prev parent reply other threads:[~2010-03-18 13:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-18 5:10 [PATCH] pull: replace unnecessary sed invocation Stephen Boyd
2010-03-18 13:30 ` Gabriel Filion [this message]
2010-03-18 14:46 ` Brandon Casey
2010-03-18 14:48 ` Junio C Hamano
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=4BA22AEE.8000606@gmail.com \
--to=lelutin@gmail.com \
--cc=bebarino@gmail.com \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.