[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

[PATCH] svnversion should its help messages to stdout

From: Kobayashi Noritada <nori1_at_dolphin.c.u-tokyo.ac.jp>
Date: 2005-02-20 09:20:19 CET

Hi,

This patch changes output destination of help messages for 'svnversion'
and 'svnversion --help'.

Since users often read help messages with a pager such as 'more' or 'less',
commands should output its help message not to stderr but to stdout.
It seems that svn, svnadmin, svnlook, svnserve, and svndumpfilter do so,
but svnversion does not.

Thanks,

-- 
|:  Noritada KOBAYASHI (nori)
|:  Dept. of General Systems Studies,
|:  Graduate School of Arts and Sciences, Univ. of Tokyo
|:  E-mail: nori1@dolphin.c.u-tokyo.ac.jp (preferable)
|:          nori@esa.c.u-tokyo.ac.jp
--
Log:
Change output destination of help messages for svnversion from stderr
to stdout, so that users can read those messages with a pager.
* subversion/svnversion/main.c
  (usage): Replace stderr with stdout.
Index: subversion/svnversion/main.c
===================================================================
--- subversion/svnversion/main.c	(revision 13086)
+++ subversion/svnversion/main.c	(working copy)
@@ -121,7 +121,7 @@
 {
   svn_error_clear
     (svn_cmdline_fprintf
-     (stderr, pool,
+     (stdout, pool,
       _("usage: svnversion [OPTIONS] WC_PATH [TRAIL_URL]\n\n"
         "  Produce a compact 'version number' for the working copy path\n"
         "  WC_PATH.  TRAIL_URL is the trailing portion of the URL used to\n"
@@ -150,7 +150,7 @@
     {
       const char *optstr;
       svn_opt_format_option(&optstr, options, TRUE, pool);
-      svn_error_clear (svn_cmdline_fprintf(stderr, pool, "  %s\n", optstr));
+      svn_error_clear (svn_cmdline_fprintf(stdout, pool, "  %s\n", optstr));
       ++options;
     }
 }
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Feb 20 09:21:25 2005

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.