GNU bug report logs -
#10976
bugreport tail (GNU coreutils) 5.97
Previous Next
Reported by: Streit Andreas <streit <at> heidenhain.de>
Date: Fri, 9 Mar 2012 07:55:01 UTC
Severity: normal
Tags: notabug
Done: Eric Blake <eblake <at> redhat.com>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 10976 in the body.
You can then email your comments to 10976 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-coreutils <at> gnu.org
:
bug#10976
; Package
coreutils
.
(Fri, 09 Mar 2012 07:55:01 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Streit Andreas <streit <at> heidenhain.de>
:
New bug report received and forwarded. Copy sent to
bug-coreutils <at> gnu.org
.
(Fri, 09 Mar 2012 07:55:01 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi,
i just tried the following command with more than one file:
tail -50 files_*.txt
i get an error:
tail: invalid option -- 5
Try `tail --help' for more information.
If i try the same command with only one file it works properly:
tail -50 files.txt
If i try the modified command with more than one file it works properly:
tail --lines=50 files_*.txt
regards
Andreas
------------------------------------------------------------
mailto:streit <at> heidenhain.de
tel.: +49 8669 31 2789
fax: +49 8669 32 2789
------------------------------------------------------------
DR. JOHANNES HEIDENHAIN GmbH
Dr.-Johannes-Heidenhain-Str. 5
83301 Traunreut, Deutschland
http://www.heidenhain.de/
[Message part 2 (text/html, inline)]
[Message part 3 (text/plain, inline)]
------------------------------------------------------------------------------------------------------
Registergericht: Traunstein / Registry Court: HRB 275 - Sitz / Head Office: Traunreut
Aufsichtsratsvorsitzender / Chairman of Supervisory Board: Rainer Burkhard
Geschäftsführung / Management Board: Thomas Sesselmann (Vorsitzender / Chairman),
Michael Grimm, Matthias Fauser, Sebastian Tondorf
E-Mail Haftungsausschluss / E-Mail Disclaimer <http://www.heidenhain.de/disclaimer>
[Message part 4 (text/html, inline)]
Added tag(s) notabug.
Request was from
Eric Blake <eblake <at> redhat.com>
to
control <at> debbugs.gnu.org
.
(Fri, 09 Mar 2012 17:58:02 GMT)
Full text and
rfc822 format available.
Reply sent
to
Eric Blake <eblake <at> redhat.com>
:
You have taken responsibility.
(Fri, 09 Mar 2012 17:58:02 GMT)
Full text and
rfc822 format available.
Notification sent
to
Streit Andreas <streit <at> heidenhain.de>
:
bug acknowledged by developer.
(Fri, 09 Mar 2012 17:58:03 GMT)
Full text and
rfc822 format available.
Message #12 received at 10976-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
tag 10976 notabug
thanks
On 03/09/2012 12:47 AM, Streit Andreas wrote:
> Hi,
>
> i just tried the following command with more than one file:
>
> tail -50 files_*.txt
> i get an error:
> tail: invalid option -- 5
> Try `tail --help' for more information.
Thanks for the report. However, this behavior is intentional. POSIX
says that you should be using -n50, and that while implementations may
support -50 as an extension, it is not a requirement. Your usage is
non-portable, and coreutils is alerting you to the fact.
Per 'info tail',
>> For compatibility `tail' also supports an obsolete usage `tail
>> -[COUNT][bcl][f] [FILE]', which is recognized only if it does not
>> conflict with the usage described above. This obsolete form uses
>> exactly one option and at most one file. In the option, COUNT is an
>> optional decimal number optionally followed by a size letter (`b', `c',
>> `l') to mean count by 512-byte blocks, bytes, or lines, optionally
>> followed by `f' which has the same meaning as `-f'.
>>
>> On older systems, the leading `-' can be replaced by `+' in the
>> obsolete option syntax with the same meaning as in counts, and obsolete
>> usage overrides normal usage when the two conflict. This obsolete
>> behavior can be enabled or disabled with the `_POSIX2_VERSION'
>> environment variable (*note Standards conformance::).
> If i try the same command with only one file it works properly:
> tail -50 files.txt
Yes, this is an example of the obsolete usage.
>
> If i try the modified command with more than one file it works properly:
> tail --lines=50 files_*.txt
Yes, this is the preferred style (simplified to -n).
Since the behavior is intentional, I'm closing this as not a bug.
--
Eric Blake eblake <at> redhat.com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
[signature.asc (application/pgp-signature, attachment)]
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Sat, 07 Apr 2012 11:24:04 GMT)
Full text and
rfc822 format available.
This bug report was last modified 13 years and 72 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.