1 |
Nikos Chantziaras <realnc@×××××.de> wrote: |
2 |
|
3 |
> Nikos Chantziaras wrote: |
4 |
> > 1) Better use -cjvpf ("f") takes an argument (the filename of that tar |
5 |
> > to be crated) so it must be at the end. |
6 |
> |
7 |
> That's why I usually use "tar -cjvp -f blabla.tar.bz2". I always |
8 |
> seperate options that take an argument from the rest. But -cjvpf works |
9 |
> too as long as "f" is at the end. This means that if you combine many |
10 |
> options after a single "-", only one one of them is allowed to take an |
11 |
> argument; the last one. |
12 |
|
13 |
You are describing the oddities of the bugs in the command line parser from |
14 |
gnu tar. Some of the problems are bugs built into the GNU getopt() function, |
15 |
others are a result from the preprocessing in gnutar. |
16 |
|
17 |
tar, ar and ps are the UNIX commands that do not follow the CLI guidelines from |
18 |
the late 1970s, see: |
19 |
|
20 |
http://www.opengroup.org/onlinepubs/007908799/xcu/tar.html |
21 |
|
22 |
and do not use options that are prepended by '-'. |
23 |
|
24 |
The origunal UNIX tar just ignores the '-' and parses the options as defined in |
25 |
1978. |
26 |
|
27 |
Star internally correctly converts the first parameter from the historic style |
28 |
to something that can be parsed by a modern command line parser such as |
29 |
getargs(). GNU tar does not correctly convert the parameters... |
30 |
|
31 |
Jörg |
32 |
|
33 |
-- |
34 |
EMail:joerg@××××××××××××××××××××××××.de (home) Jörg Schilling D-13353 Berlin |
35 |
js@××××××××××××.de (uni) |
36 |
joerg.schilling@××××××××××××××××.de (work) Blog: http://schily.blogspot.com/ |
37 |
URL: http://cdrecord.berlios.de/private/ ftp://ftp.berlios.de/pub/schily |