[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Translation of tail
From: |
Jim Meyering |
Subject: |
Re: Translation of tail |
Date: |
Wed, 30 Dec 2009 14:26:27 +0100 |
Stéphane Raimbault wrote:
> I can't correctly format the tail help message because the string
> src/tail.c:316 (git master) is split in two parts. The first part is at
> line 316 and the second part (without new line between) is line 312.
>
> Could you join the messages together or add a new line at the end of the
> first?
Thanks for mentioning that.
While looking at it I noticed there was room for semantic improvement:
>From 71f4b3846e53109a32e9078269bceecc7c5b5057 Mon Sep 17 00:00:00 2001
From: Jim Meyering <address@hidden>
Date: Wed, 30 Dec 2009 14:23:45 +0100
Subject: [PATCH] doc: update tail's documentation to allow for new -F semantics
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
* src/tail.c (usage): Reword tail -F description, so that it no
longer mentions details specific to the non-inotify implementation.
Also, join diagnostic strings (while staying under the 509-byte limit)
to ease formatting of translations. The latter was prompted by
a report from Stéphane Raimbault.
* doc/coreutils.texi (tail invocation): Update description here, too.
---
THANKS | 1 +
doc/coreutils.texi | 6 ++++--
src/tail.c | 8 ++------
3 files changed, 7 insertions(+), 8 deletions(-)
diff --git a/THANKS b/THANKS
index 86be252..cab8773 100644
--- a/THANKS
+++ b/THANKS
@@ -543,6 +543,7 @@ Solar Designer address@hidden
Stanislav Ievlev address@hidden
Stavros Passas address@hidden
Stéphane Chazelas address@hidden
+Stéphane Raimbault address@hidden
Stephen Depooter address@hidden
Stephen Eglen address@hidden
Stephen Gildea address@hidden
diff --git a/doc/coreutils.texi b/doc/coreutils.texi
index e097c25..5e43b17 100644
--- a/doc/coreutils.texi
+++ b/doc/coreutils.texi
@@ -2770,8 +2770,10 @@ tail invocation
it has been unlinked, use @option{--follow=descriptor}. This is the default
behavior, but it is not useful if you're tracking a log file that may be
rotated (removed or renamed, then reopened). In that case, use
address@hidden to track the named file by reopening it periodically
-to see if it has been removed and recreated by some other program.
address@hidden to track the named file, perhaps by reopening it
+periodically to see if it has been removed and recreated by some other program.
+Note that the inotify-based implementation handles this case without
+the need for any periodic reopening.
No matter which method you use, if the tracked file is determined to have
shrunk, @command{tail} prints a message saying the file has been truncated
diff --git a/src/tail.c b/src/tail.c
index 28a0e26..8195dee 100644
--- a/src/tail.c
+++ b/src/tail.c
@@ -316,14 +316,10 @@ GB 1000*1000*1000, G 1024*1024*1024, and so on for T, P,
E, Z, Y.\n\
fputs (_("\
With --follow (-f), tail defaults to following the file descriptor, which\n\
means that even if a tail'ed file is renamed, tail will continue to track\n\
-its end. \
-"), stdout);
- fputs (_("\
-This default behavior is not desirable when you really want to\n\
+its end. This default behavior is not desirable when you really want to\n\
track the actual name of the file, not the file descriptor (e.g., log\n\
rotation). Use --follow=name in that case. That causes tail to track the\n\
-named file by reopening it periodically to see if it has been removed and\n\
-recreated by some other program.\n\
+named file in a way that accommodates renaming, removal and creation.\n\
"), stdout);
emit_ancillary_info ();
}
--
1.6.6.325.g6f5f