107
107
| < a href ="../../../../toc2.html "> Applications</ a >
108
108
] < hr >
109
109
< div class ="doctools ">
110
- < h1 class ="doctools_title "> tar(n) 0.12.1 tcllib "Tar file handling"</ h1 >
110
+ < h1 class ="doctools_title "> tar(n) 0.13 tcllib "Tar file handling"</ h1 >
111
111
< div id ="name " class ="doctools_section "> < h2 > < a name ="name "> Name</ a > </ h2 >
112
112
< p > tar - Tar file creation, extraction & manipulation</ p >
113
113
</ div >
@@ -127,13 +127,13 @@ <h1 class="doctools_title">tar(n) 0.12.1 tcllib "Tar file handling"</h
127
127
< div class ="doctools_synopsis ">
128
128
< ul class ="doctools_requirements ">
129
129
< li > package require < b class ="pkgname "> Tcl 8.5 9</ b > </ li >
130
- < li > package require < b class ="pkgname "> tar < span class ="opt "> ?0.12.1 ?</ span > </ b > </ li >
130
+ < li > package require < b class ="pkgname "> tar < span class ="opt "> ?0.13 ?</ span > </ b > </ li >
131
131
</ ul >
132
132
< ul class ="doctools_syntax ">
133
- < li > < a href ="#1 "> < b class ="cmd "> ::tar::contents</ b > < i class ="arg "> tarball</ i > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > </ a > </ li >
134
- < li > < a href ="#2 "> < b class ="cmd "> ::tar::stat</ b > < i class ="arg "> tarball</ i > < span class ="opt "> ?file?</ span > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > </ a > </ li >
133
+ < li > < a href ="#1 "> < b class ="cmd "> ::tar::contents</ b > < i class ="arg "> tarball</ i > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > < span class =" opt " > ? < b class =" option " > -gzip </ b > ? </ span > </ a > </ li >
134
+ < li > < a href ="#2 "> < b class ="cmd "> ::tar::stat</ b > < i class ="arg "> tarball</ i > < span class ="opt "> ?file?</ span > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > < span class =" opt " > ? < b class =" option " > -gzip </ b > ? </ span > </ a > </ li >
135
135
< li > < a href ="#3 "> < b class ="cmd "> ::tar::untar</ b > < i class ="arg "> tarball</ i > < i class ="arg "> args</ i > </ a > </ li >
136
- < li > < a href ="#4 "> < b class ="cmd "> ::tar::get</ b > < i class ="arg "> tarball</ i > < i class ="arg "> fileName</ i > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > </ a > </ li >
136
+ < li > < a href ="#4 "> < b class ="cmd "> ::tar::get</ b > < i class ="arg "> tarball</ i > < i class ="arg "> fileName</ i > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > < span class =" opt " > ? < b class =" option " > -gzip </ b > ? </ span > </ a > </ li >
137
137
< li > < a href ="#5 "> < b class ="cmd "> ::tar::create</ b > < i class ="arg "> tarball</ i > < i class ="arg "> files</ i > < i class ="arg "> args</ i > </ a > </ li >
138
138
< li > < a href ="#6 "> < b class ="cmd "> ::tar::add</ b > < i class ="arg "> tarball</ i > < i class ="arg "> files</ i > < i class ="arg "> args</ i > </ a > </ li >
139
139
< li > < a href ="#7 "> < b class ="cmd "> ::tar::remove</ b > < i class ="arg "> tarball</ i > < i class ="arg "> files</ i > </ a > </ li >
@@ -165,16 +165,31 @@ <h1 class="doctools_title">tar(n) 0.12.1 tcllib "Tar file handling"</h
165
165
unstack the transformation before seeking the channel back to a suitable
166
166
position, and (b) for restacking it after.</ p > </ li >
167
167
</ ol >
168
+ < p > Regarding support for gzip compression:</ p >
169
+ < ol class ="doctools_enumerated ">
170
+ < li > < p > Errors are thrown when attempting to read from compressed tar archives
171
+ while compression support (i.e. < b class ="cmd "> ::zlib</ b > ) is not available.</ p > </ li >
172
+ < li > < p > Errors are thrown when attempting to read an uncompressed tar archive
173
+ when compression is requested by the user (< b class ="option "> -gzip</ b > ).</ p >
174
+ < p > No errors are thrown when attempting to read a compressed tar archive
175
+ when compression was not requested, and is supported. In that case the
176
+ commands automatically activate the code handling the compression.</ p > </ li >
177
+ < li > < p > Errors are thrown when attempting to edit compressed tar archives.
178
+ See the commands < b class ="cmd "> tar::add</ b > , and < b class ="cmd "> tar::remove</ b > .
179
+ This is not supported.</ p > </ li >
180
+ < li > < p > Creation of compressed tar archives however is supported, as this
181
+ sequentially writes the archive, allowing for streaming compression.</ p > </ li >
182
+ </ ol >
168
183
</ div >
169
184
< div id ="section3 " class ="doctools_section "> < h2 > < a name ="section3 "> COMMANDS</ a > </ h2 >
170
185
< dl class ="doctools_definitions ">
171
- < dt > < a name ="1 "> < b class ="cmd "> ::tar::contents</ b > < i class ="arg "> tarball</ i > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > </ a > </ dt >
186
+ < dt > < a name ="1 "> < b class ="cmd "> ::tar::contents</ b > < i class ="arg "> tarball</ i > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > < span class =" opt " > ? < b class =" option " > -gzip </ b > ? </ span > </ a > </ dt >
172
187
< dd > < p > Returns a list of the files contained in < i class ="arg "> tarball</ i > . The order is not sorted and depends on the order
173
188
files were stored in the archive.</ p >
174
189
< p > If the option < b class ="option "> -chan</ b > is present < i class ="arg "> tarball</ i > is interpreted as an open channel.
175
190
It is assumed that the channel was opened for reading, and configured for binary input.
176
191
The command will < em > not</ em > close the channel.</ p > </ dd >
177
- < dt > < a name ="2 "> < b class ="cmd "> ::tar::stat</ b > < i class ="arg "> tarball</ i > < span class ="opt "> ?file?</ span > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > </ a > </ dt >
192
+ < dt > < a name ="2 "> < b class ="cmd "> ::tar::stat</ b > < i class ="arg "> tarball</ i > < span class ="opt "> ?file?</ span > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > < span class =" opt " > ? < b class =" option " > -gzip </ b > ? </ span > </ a > </ dt >
178
193
< dd > < p > Returns a nested dict containing information on the named < span class ="opt "> ?file?</ span > in < i class ="arg "> tarball</ i > ,
179
194
or all files if none is specified. The top level are pairs of filename and info. The info is a dict with the keys
180
195
"< b class ="const "> mode</ b > < b class ="const "> uid</ b > < b class ="const "> gid</ b > < b class ="const "> size</ b > < b class ="const "> mtime</ b > < b class ="const "> type</ b > < b class ="const "> linkname</ b > < b class ="const "> uname</ b > < b class ="const "> gname</ b >
@@ -218,7 +233,7 @@ <h1 class="doctools_title">tar(n) 0.12.1 tcllib "Tar file handling"</h
218
233
}
219
234
</ pre >
220
235
</ dd >
221
- < dt > < a name ="4 "> < b class ="cmd "> ::tar::get</ b > < i class ="arg "> tarball</ i > < i class ="arg "> fileName</ i > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > </ a > </ dt >
236
+ < dt > < a name ="4 "> < b class ="cmd "> ::tar::get</ b > < i class ="arg "> tarball</ i > < i class ="arg "> fileName</ i > < span class ="opt "> ?< b class ="option "> -chan</ b > ?</ span > < span class =" opt " > ? < b class =" option " > -gzip </ b > ? </ span > </ a > </ dt >
222
237
< dd > < p > Returns the contents of < i class ="arg "> fileName</ i > from the < i class ="arg "> tarball</ i > .</ p >
223
238
< pre class ="doctools_example ">
224
239
% set readme [::tar::get tarball.tar doc/README] {
0 commit comments