exec $c; die "$c: $!";
}
+sub rewind_raw () {
+ system "mt -f $tape rewind"; $? and die $?;
+}
+
sub readtapeid_raw () {
open T, ">>TAPEID" or die $!; close T;
unlink 'TAPEID' or die $!;
- system "mt -f $tape rewind"; $? and die $?;
+ rewind_raw();
system "mt -f $tape setblk $blocksizebytes"; $? and die $?;
system "dd if=$tape bs=${blocksize}b count=10 ".
"| tar -b$blocksize -vvxf - TAPEID";
}
}
-@ARGV==1 or die "$0: need 1 arg, new TAPEID";
+@ARGV==1 or die "$0: need 1 arg, new TAPEID\n";
($newid)= @ARGV;
readtapeid_raw();
close T or die $!;
writetapeid($newid);
+rewind_raw();
print "Labelled tape \`$newid'\n" or die $!;
exit 0;
-chiark-utils (2.1.0) experimental; urgency=low
+chiark-utils (2.0.0.999) experimental; urgency=low
* man pages for readbuffer, writebuffer from Richard Kettlewell.
* add info re last-tape and checkallused to iwjbackup.txt.
* new `backup-labeltape' utility.
- --
+ -- Ian Jackson <ian@davenant.greenend.org.uk> Fri, 9 Nov 2001 21:12:25 +0000
chiark-utils (2.0.0) experimental; urgency=low