Perl in Windows

From Bioinformatics Core Wiki
Revision as of 15:36, 2 April 2012 by Thermoso (Talk | contribs)

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

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

Find Windows terminal

The easiest way to access to terminal in Windows is by typing its name. Of course, you can decide to make a shortcut link for future uses.

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 current directory)

Windows-command-prompt-in.png

As reference:

Running Perl

Strawberry Perl adds the perl command to the Windows System and becomes accessible from the terminal. Below you can see how a small 'Hello world' script, that we check its content by using more command, is launched.

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