#!/usr/bin/perl -w

use strict;

my $SCALE = shift @ARGV;
my $p = shift @ARGV;

my $x = 210 * ($SCALE - 1) / 2;
my $y = 297 * ($SCALE - 1) / 2 + $p;

my $spec = sprintf("\@$SCALE(%.0fmm,%.0fmm)", -$x, -$y);
print "<$spec>\n";
for my $f (@ARGV) {
    my $stem = $f;
    $stem =~ s/\.ps$//;
    my $cmd = "pstops \"$spec\" $f > $stem.sz.ps";
    print $cmd, "\n";
    print `$cmd`;
}

__END__

script to enlarge a ps. file.
Eg. running

 Pcb2ps.pl 1.8 30 regulator.v02.pcb.ps

gives me nearly double the size of a board, shifted down
30mm so I can see the drill sizes in the fab drawing.
