tomcrypt/fixupind.pl
Francois Perrad 808616d406 sanitize some Perl scripts
(Perl4 is gone)
2017-02-28 19:59:58 +01:00

17 lines
292 B
Perl
Executable File

#!/usr/bin/perl
use strict;
use warnings;
open(my $in, '<', 'crypt.ind');
open(my $out, '>', 'crypt.ind.tmp');
my $a = <$in>;
print {$out} "$a\n\\addcontentsline{toc}{chapter}{Index}\n";
while (<$in>) {
print {$out} $_;
}
close $out;
close $in;
system("mv -f crypt.ind.tmp crypt.ind");