Bug#395430: [PATCH] doc: note the order in which wc counts are printed

2011-07-13 Thread Benoît Knecht
Hi Pádraig,

Pádraig Brady wrote:
 On 11/07/11 22:10, Benoît Knecht wrote:
 
  diff --git a/src/wc.c b/src/wc.c
 
  +The options below may be used to select which counts are printed, always 
  in\n\
  +the following order: newline, word, character, byte, maximum line 
  length.\n\
 
 Well worth adding.
 How about rewording to line up with the long options. I.E.
 
 +the following order: lines, words, chars, bytes, max-line-length.\n\

Well I prefer not using abreviations in documentation (char -
character, max - maximum); of course, those are obvious, but I think
it's in general better to use plain words. As for line vs. newline, I
have no preference, I simply used the term from the first part of the
description (for the same reason, I used the singular form, as in
newline count).

Thanks for your comments.

-- 
Benoît Knecht



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#395430: [PATCH] doc: note the order in which wc counts are printed

2011-07-13 Thread Vincent Lefevre
Hi,

On 2011-07-13 09:28:55 +0200, Benoît Knecht wrote:
 Well I prefer not using abreviations in documentation (char -
 character, max - maximum); of course, those are obvious, but I think
 it's in general better to use plain words. As for line vs. newline, I
 have no preference, I simply used the term from the first part of the
 description (for the same reason, I used the singular form, as in
 newline count).

line would be incorrect if the last line doesn't end with a newline
character. One may wonder whether this is really a line, but according
to wc's -L option, it is:

$ echo -n abc | wc -l -L
  0   3

Since wc outputs 3 for the the length of the longest line, then
this means that abc (without a newline character) is a line. Thus
the line count is 1 and the newline count is 0.

Regards,

-- 
Vincent Lefèvre vinc...@vinc17.net - Web: http://www.vinc17.net/
100% accessible validated (X)HTML - Blog: http://www.vinc17.net/blog/
Work: CR INRIA - computer arithmetic / Arénaire project (LIP, ENS-Lyon)



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#395430: [PATCH] doc: note the order in which wc counts are printed

2011-07-13 Thread Pádraig Brady
On 13/07/11 09:07, Vincent Lefevre wrote:
 Hi,
 
 On 2011-07-13 09:28:55 +0200, Benoît Knecht wrote:
 Well I prefer not using abreviations in documentation (char -
 character, max - maximum); of course, those are obvious, but I think
 it's in general better to use plain words. As for line vs. newline, I
 have no preference, I simply used the term from the first part of the
 description (for the same reason, I used the singular form, as in
 newline count).
 
 line would be incorrect if the last line doesn't end with a newline
 character. One may wonder whether this is really a line, but according
 to wc's -L option, it is:
 
 $ echo -n abc | wc -l -L
   0   3
 
 Since wc outputs 3 for the the length of the longest line, then
 this means that abc (without a newline character) is a line. Thus
 the line count is 1 and the newline count is 0.

OK thanks guys.
I push that verbatim (well I added a '.')

cheers,
Pádraig.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#395430: [PATCH] doc: note the order in which wc counts are printed

2011-07-13 Thread Benoît Knecht
tag 395430 patch fixed-upstream
thanks

Pádraig Brady wrote:
 On 13/07/11 09:07, Vincent Lefevre wrote:
  Hi,
  
  On 2011-07-13 09:28:55 +0200, Benoît Knecht wrote:
  Well I prefer not using abreviations in documentation (char -
  character, max - maximum); of course, those are obvious, but I think
  it's in general better to use plain words. As for line vs. newline, I
  have no preference, I simply used the term from the first part of the
  description (for the same reason, I used the singular form, as in
  newline count).
  
  line would be incorrect if the last line doesn't end with a newline
  character. One may wonder whether this is really a line, but according
  to wc's -L option, it is:
  
  $ echo -n abc | wc -l -L
0   3
  
  Since wc outputs 3 for the the length of the longest line, then
  this means that abc (without a newline character) is a line. Thus
  the line count is 1 and the newline count is 0.
 
 OK thanks guys.
 I push that verbatim (well I added a '.')

Thanks! I'm just writing the commit id below to make it easier to find
out when to close the bug in Debian.

http://git.savannah.gnu.org/cgit/coreutils.git/commit/?id=2c558fd0d36162559574b7696fe485913cdd9066

-- 
Benoît Knecht



--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#395430: [PATCH] doc: note the order in which wc counts are printed

2011-07-12 Thread Pádraig Brady
On 11/07/11 22:10, Benoît Knecht wrote:

 diff --git a/src/wc.c b/src/wc.c

 +The options below may be used to select which counts are printed, always 
 in\n\
 +the following order: newline, word, character, byte, maximum line length.\n\

Well worth adding.
How about rewording to line up with the long options. I.E.

+the following order: lines, words, chars, bytes, max-line-length.\n\

cheers,
Pádraig.



-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#395430: [PATCH] doc: note the order in which wc counts are printed

2011-07-11 Thread Benoît Knecht
This information has already been added to the Texinfo manual, but was
missing from the --help output.

* src/wc.c (usage): As above, for --help.
Reported by Vincent Lefevre in http://bugs.debian.org/395430.
---
 THANKS.in |1 +
 src/wc.c  |2 ++
 2 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/THANKS.in b/THANKS.in
index 4bbee80..05d5922 100644
--- a/THANKS.in
+++ b/THANKS.in
@@ -589,6 +589,7 @@ Uwe H. Steinfeldusteinf...@gmx.net
 Vesselin Atanasov   vesse...@bgnet.bg
 Ville Skyttäville.sky...@iki.fi
 Vin Shelton a...@alumni.princeton.edu
+Vincent Lefevre vinc...@vinc17.org
 Vineet Chadha   cha...@acis.ufl.edu
 Vitali Lovich   vlov...@gmail.com
 Vitaly A. Ostanin   v...@altlinux.org
diff --git a/src/wc.c b/src/wc.c
index c4b5a91..43b46a3 100644
--- a/src/wc.c
+++ b/src/wc.c
@@ -120,6 +120,8 @@ Print newline, word, and byte counts for each FILE, and a 
total line if\n\
 more than one FILE is specified.  With no FILE, or when FILE is -,\n\
 read standard input.  A word is a non-zero-length sequence of characters\n\
 delimited by white space.\n\
+The options below may be used to select which counts are printed, always in\n\
+the following order: newline, word, character, byte, maximum line length.\n\
   -c, --bytesprint the byte counts\n\
   -m, --charsprint the character counts\n\
   -l, --linesprint the newline counts\n\
-- 
1.7.5.4




--
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org