ActivePERL - PERL for Windows - using perl
PERL comes pre-installed on many operating systems, like Linux for example.
For those of us running a version of Windows however, we must download and install some sort of program that allows us to access PERL scripts from DOS. There are many PERL compilations available for your machine. A simple Google search yields several million results.
ActivePERL is the simplest of installers available and it is also free to download. Download the program, follow the onscreen installation guide, and you should have an active installation of PERL ready to go.
Download ActivePERL link
To test the installation, make sure the program has fully completed installation and then run through the following:
1. Click on Start, go to Run.
2. Please enter 'Command' or 'cmd' into the display box to open up the command prompt.
3. At the command prompt type 'perl -v'
You should get some documentation about Larry Wall 1987-200X, and that means you are officially done installing
PERL and ready to start creating some PERL scripts.
PERL - Testing...Testing Script
Just to be sure everything is running correctly. Open up notepad or your preferred simple text editor and let's make a beginning script. We'll have our script print to the command prompt with the print function just as we would if we were printing text to our web browser.
print "Hello PERL!";
Copy the two lines above and save them in a directory that you are capable of accessing through DOS with the name as testing.pl
For eg: When you launch command prompt you get-->
C:\Documents and Settings\pradeep
Create a new directory named perl in it.
Locate that directory (perl) in your DOS prompt and simply type the name of your PERL script into the command prompt to execute your script.
C:\Documents and Settings\pradeep\perl> testing.pl
Check that you get an output in the command prompt as: Hello PERL!
Teach yourself Perl in 21 Days !
- David Till (pdf file)