Difference between revisions of "Perl in Windows"

From Bioinformatics Core Wiki
 
Line 2: Line 2:
  
 
* You can download last Perl version from Windows here: [http://strawberryperl.com/ Strawberry Perl]
 
* You can download last Perl version from Windows here: [http://strawberryperl.com/ Strawberry Perl]
* YouTube step-by-step video on how to install Perl on Windows: [http://www.youtube.com/watch?v=1RHYPM6e55o]
+
* YouTube step-by-step video on how to install Perl on Windows: [http://www.youtube.com/watch?v=1RHYPM6e55o Installation of Perl]
  
 
Below, there are some screenshots and some hints for starting to use Perl in Windows.
 
Below, there are some screenshots and some hints for starting to use Perl in Windows.

Latest revision as of 06:59, 3 April 2012

Perl programming language is included by default in most Linux distributions and also in all Mac OS X versions up to day. Windows users need to install it by themselves.

Below, there are some screenshots and some hints for starting to use Perl in Windows.

Find Windows terminal

The easiest way for accessing the terminal in Windows is by typing its name in the launch bar or directly writing CMD. Of course, afterwards, you can decide to make a shortcut link in the desktop or in the Windows bar.

Windows-command-prompt.png

Windows Terminal commands

Commands are not exactly the same as in UNIX (Linux & Mac OS X) systems.

At least, you should know:

  • dir (list a directory content)
  • cd (change to a directory)

Windows-command-prompt-in.png

As reference:

Running Perl

Strawberry Perl adds perl command to Windows System. From that moment, it becomes available from the terminal. Below you can see how a small 'Hello world' script is launches. We also check its content by using more command.

perl hello.pl

Windows-command-prompt-perl.png

Shebang line (the first one of the script and starting with #!), typical of UNIX systems, is ignored in Windows.

Bioinformatics Core Facility @ CRG — 2011-2024