From: Jason Cooper <jason@lakedaemon.net>
To: Masahiro Yamada <yamada.m@jp.panasonic.com>
Cc: linux-kbuild@vger.kernel.org
Subject: Re: [PATCH 2/7] scripts: objdiff: direct error messages to stderr
Date: Fri, 6 Jun 2014 11:28:47 -0400 [thread overview]
Message-ID: <20140606152847.GJ8664@titan.lakedaemon.net> (raw)
In-Reply-To: <1401448315-800-3-git-send-email-yamada.m@jp.panasonic.com>
Masahiro,
Thanks for the patch series!
On Fri, May 30, 2014 at 08:11:50PM +0900, Masahiro Yamada wrote:
> Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
> Cc: Jason Cooper <jason@lakedaemon.net>
> ---
> scripts/objdiff | 18 +++++++++---------
> 1 file changed, 9 insertions(+), 9 deletions(-)
>
> diff --git a/scripts/objdiff b/scripts/objdiff
> index b8f7fc6..cc67365 100755
> --- a/scripts/objdiff
> +++ b/scripts/objdiff
> @@ -28,17 +28,17 @@
> SRCTREE=$(git rev-parse --show-toplevel 2>/dev/null)
>
> if [ -z "$SRCTREE" ]; then
> - echo "ERROR: Not a git repository."
> + echo >&2 "ERROR: Not a git repository."
> exit 1
> fi
>
> TMPD=$SRCTREE/.tmp_objdiff
>
> usage() {
> - echo "Usage: $0 <command> <args>"
> - echo " record <list of object files>"
> - echo " diff <commitA> <commitB>"
> - echo " clean all | <commit>"
> + echo >&2 "Usage: $0 <command> <args>"
> + echo >&2 " record <list of object files>"
> + echo >&2 " diff <commitA> <commitB>"
> + echo >&2 " clean all | <commit>"
I must admit I've never seen it written this way, but my CDO [1]
definitely likes it :)
> exit 1
> }
>
> @@ -88,12 +88,12 @@ dodiff() {
> DSTD="$TMPD/$DST"
>
> if [ ! -d "$SRCD" ]; then
> - echo "ERROR: $SRCD doesn't exist"
> + echo >&2 "ERROR: $SRCD doesn't exist"
> exit 1
> fi
>
> if [ ! -d "$DSTD" ]; then
> - echo "ERROR: $DSTD doesn't exist"
> + echo >&2 "ERROR: $DSTD doesn't exist"
> exit 1
> fi
>
> @@ -112,7 +112,7 @@ doclean() {
> if [ -d "$TMPD/$CMT" ]; then
> rm -rf $TMPD/$CMT
> else
> - echo "$CMT not found"
> + echo >&2 "$CMT not found"
> fi
> fi
> }
> @@ -133,7 +133,7 @@ case "$1" in
> doclean $*
> ;;
> *)
> - echo "Unrecognized command '$1'"
> + echo >&2 "Unrecognized command '$1'"
> exit 1
> ;;
> esac
thx,
Jason.
[1] CDO: OCD with the letters neatly arranged in alphabetical order.
next prev parent reply other threads:[~2014-06-06 15:28 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-30 11:11 [PATCH 0/7] scripts: objdiff: various clean-up, fix and new features Masahiro Yamada
2014-05-30 11:11 ` [PATCH 1/7] scripts: objdiff: get the path to .tmp_objdiff more simply Masahiro Yamada
2014-05-30 11:11 ` [PATCH 2/7] scripts: objdiff: direct error messages to stderr Masahiro Yamada
2014-06-06 15:28 ` Jason Cooper [this message]
2014-05-30 11:11 ` [PATCH 3/7] scripts: objdiff: remove unnecessary code Masahiro Yamada
2014-05-30 11:11 ` [PATCH 4/7] scripts: objdiff: improve path flexibility for record command Masahiro Yamada
2014-06-06 15:33 ` Jason Cooper
2014-05-30 11:11 ` [PATCH 5/7] scripts: objdiff: change the extension of disassembly from .o to .dis Masahiro Yamada
2014-05-30 11:11 ` [PATCH 6/7] scripts: objdiff: fix a comment Masahiro Yamada
2014-06-06 15:35 ` Jason Cooper
2014-05-30 11:11 ` [PATCH 7/7] scripts: objdiff: support directories for the augument of record command Masahiro Yamada
2014-06-06 15:38 ` [PATCH 0/7] scripts: objdiff: various clean-up, fix and new features Jason Cooper
2014-06-09 2:21 ` Masahiro Yamada
2014-06-10 10:04 ` Michal Marek
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=20140606152847.GJ8664@titan.lakedaemon.net \
--to=jason@lakedaemon.net \
--cc=linux-kbuild@vger.kernel.org \
--cc=yamada.m@jp.panasonic.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox