Clovertech
› Clovertech Forums › Read Only Archives › Cloverleaf › Cloverleaf › TCL function to compress a file using UNIX compress
proc fnCompressAFile { fileToCompress args } {
if { [ file exists $fileToCompress ] } {
if [ catch {exec compress -vf $fileToCompress} err ] {
return $err
}
return 0
return 1
Usage: fnCompressAFile $filenameToCompress
Hi,
I think these should be posted to the Tcl Library section rather than the Cloverleaf section.
I appreciate they are very simple scripts that some note about them would also be useful rather than just posting a function.
Regards
Garry