1

Sorry for the noob question. I just downloaded CAM::PDF along with Strawberry for Windows, and trying to do find/replace from the command line. Ran buidinstalldeps to get all needed prereqs.

I'm trying to run changepagestring.pl from command line. But idk how to reference the file location and have it put the output file for me in a specified location:

changepagestring.pl master-exch-manual.pdf "as shown in Figure" figure output.pdf

My goal is to replace "see above figure" with "figure" in this file. But it's in a different directory than the one I'm in, C:\Users\Me\Doc\CAM-PDF-1.60\ So how do I run and do all this from the command line. I've seen the help file with example, but I get this: CAM::PDF from command shell with PL file not recognized

ellipsical
  • 39
  • 1
  • 2

1 Answers1

0

There are a few possible solutions. The easiest one from the directory you mentioned is:

perl -Ilib bin/changepagestring.pl ...

Alternatively, if you run the usual Perl install commands from that folder, then changepagestring.pl should be included in your usual path

perl Makefile.PL
make install

Alternatively^2, you can use the "cpan" tool to automate the download, build, test and install steps in one go:

cpan install CAM::PDF
Chris Dolan
  • 8,905
  • 2
  • 35
  • 73
  • ok for the file i'm working with, would i have to move it to that directory as well to run this: perl -Ilib bin/changepagestring.pl sourcefile.pdf 'find string' 'replace string' output.pdf – ellipsical Sep 07 '17 at 02:01