Subject: Re: ftp and tar annoyances
To: None <current-users@NetBSD.ORG>
From: Hubert Feyrer <email@example.com>
Date: 11/15/1997 09:51:05
Brad Salai <firstname.lastname@example.org> wrote:
> You have to get the options in the right order,
> tar -zxvpf bin.tar.gz works, but
> tar -zxvfp bin.tar.gz doesn't
With the latter, you give "p" as an argument to the -f option, which is
of course wrong. Please note that the semantics of option handling
for tar differ if you use a "-" to introduce options or not:
If you use a "-", the arguments to an option need to follow these option
immediately (optionally seperated by space). If you don't use an "-",
old-style option-parsing semantigs apply, in which you first specify
all the options in one block, and then all the arguments, in the order
the belonging options appear in the option block.
> Once you know this, only the occasional tyop causes problems, but why does
> it have to be that way?
This latter mode (without "-") is mainly for backward compatibility,
it does not fit into the option parsing scheme getopt(3) implements.
> As for ftp, mget is a nice idea, but it asks you to confirm that you still
> want each file as it comes up. This makes it impossible to just get a
> collection of files, either by matching a pattern, or listing the files,
> without sitting there.
> This arises in collecting up the tarballs, so it gets me frequently.
Typing "prompt" will turn off any questions, and assume a "yes" answer.
Hubert Feyrer <email@example.com>