[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: 5.93 tail -N foo bar invalid option
From: |
Karl Berry |
Subject: |
Re: 5.93 tail -N foo bar invalid option |
Date: |
Mon, 30 Jan 2006 12:12:22 -0600 |
Hi Paul,
When I ran into this a while ago, I decided not to change GNU tail to
support 7th Edition Unix behavior,
I certainly agree with that. I remember running into this in the past
and being puzzled by the bogus behavior.
However, if some actual programs rely on the 7th Edition Unix
I don't rely on it. I just expected GNU tail -3 to behave the same as
GNU head -3, since GNU is supposed to do things right :).
The error `invalid option -- 3' just confused me more, since it's not
the -3 that is invalid. It made me think some POSIX spec was getting in
the way of doing the right thing. It would seem the right error/warning
message, if you choose to reject this usage, would be something like
"invalid second argument `bar', use tail -3 foo; tail -3 bar"?
But how about just making it work the same as head -3 in the first
place, instead of forcing these inconveniences on GNU users?
This says "tail -3 foo bar" is not supported, but it does not say so
explicitly. Do you think an explicit statement would be helpful?
Going along that path, a clear description of the situation in the
manual could only help. I would be hard-pressed to parse the sentence
as it stands into "tail -3 foo bar is rejected with `invalid option -- 3'".
For compatibility @command{tail} also supports an obsolete usage
This characterization as "obsolete" of the way tail is actually used 99%
of the time (regardless of what POSIX has foisted on the world) seems
unwarranted.
Thanks,
Karl