From: "Paolo G. Giarrusso" <p.giarrusso@gmail.com>
To: git@vger.kernel.org
Cc: "Paolo G. Giarrusso" <p.giarrusso@gmail.com>
Subject: [PATCH] git-subtree: Avoid using echo -n even indirectly
Date: Wed, 9 Oct 2013 05:57:25 +0200 [thread overview]
Message-ID: <1381291045-98372-1-git-send-email-p.giarrusso@gmail.com> (raw)
Since say uses echo, this uses echo -n, which is not portable - see
19c3c5fdcb35b66b792534c5dc4e8d87a3952d2a.
Without this commit, the output looks like:
...
-n 1891/ 1936 (1883)
-n 1892/ 1936 (1884)
-n 1893/ 1936 (1885)
...
Signed-off-by: Paolo G. Giarrusso <p.giarrusso@gmail.com>
---
Please CC me on replies, as I am not subscribed to this mailing list.
I am tracking this submission via https://github.com/git/git/pull/61, which I'll
duly close myself when the discussion is resolved.
contrib/subtree/git-subtree.sh | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/contrib/subtree/git-subtree.sh b/contrib/subtree/git-subtree.sh
index 7d7af03..ebfb78f 100755
--- a/contrib/subtree/git-subtree.sh
+++ b/contrib/subtree/git-subtree.sh
@@ -592,7 +592,9 @@ cmd_split()
eval "$grl" |
while read rev parents; do
revcount=$(($revcount + 1))
- say -n "$revcount/$revmax ($createcount)
"
+ if [ -z "$quiet" ]; then
+ printf "%s" "$revcount/$revmax ($createcount)
" >&2
+ fi
debug "Processing commit: $rev"
exists=$(cache_get $rev)
if [ -n "$exists" ]; then
--
1.8.4
next reply other threads:[~2013-10-09 3:57 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-09 3:57 Paolo G. Giarrusso [this message]
2013-10-09 10:20 ` [PATCH] git-subtree: Avoid using echo -n even indirectly Tay Ray Chuan
[not found] ` <CAAcnjCT1bdR+9kDW=q_326OhiSMm3_j-yOh0-ayTkObK3bZ3bQ@mail.gmail.com>
2013-10-09 10:32 ` Fwd: " Paolo Giarrusso
2013-10-09 10:46 ` Johannes Sixt
2013-10-09 11:26 ` Matthieu Moy
2013-10-09 12:03 ` Paolo Giarrusso
2013-10-09 19:48 ` Jeff King
2013-10-09 21:11 ` Jonathan Nieder
2013-10-11 9:32 ` Paolo Giarrusso
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
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1381291045-98372-1-git-send-email-p.giarrusso@gmail.com \
--to=p.giarrusso@gmail.com \
--cc=git@vger.kernel.org \
/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.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).