blob: 3ee179b0ed61821d953e90d57abe9eaef608e3b9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
#!/usr/bin/perl -w
# Copyright 2012 Ben Hall bhall@cs.queensu.ca
# School of Computing, Queen's University
# This program is free software, licensed under the GNU GPL, >=2.0.
# This software comes with absolutely NO WARRANTY.
#
# Usage: rename_enc fontdirectory fontabbreviation
#
# Grab font dir and font abbreviation from command line
my $dir = $ARGV[0];
my $font = $ARGV[1];
@files = <fonts/enc/dvips/$dir/*.enc>;
foreach $file (@files) {
# print $file . "\n"; #echo file name for testing.
# rename each file with name of the form a_xxxxxx.enc
# to $font_xxxxxx.enc
$_ = $file;
$prefix = $font . "_";
s/a_/$prefix/;
`mv $file $_`;
}
|