How to Setup Sublime Text 3 for Perl in Windows?

Perl is a general-purpose, high level interpreted and dynamic programming language. Perl was originally developed for text processing like extracting the required information from a specified text file and for converting the text file into a different form.
Perl programs can be written on any plain text editor like notepad, notepad++, or anything of that sort. One can also use an online IDE for writing Perl codes or can even install one on their system to make it more feasible to write these codes.

Written by a Google engineer sublime text is a cross-platform IDE developed in C++ and Python. It has basic built-in support for Python. Sublime text is fast and you can customize this editor as per your need to create a full-fledged Python development environment. You can install packages such as debugging, auto-completion, code linting, etc. There are also various packages for scientific development, Django, Flask, and so on.

Downloading and Installation

Perl can be downloaded from perl.org. To install Perl on Windows, go through How to install Perl on Windows?

Sublime Text 3 can be downloaded from its official site sublimetext.com. To install sublime text 3 on Windows, go through How to install Sublime Text 3 in Windows?

To check that perl is installed perfectly on your device just type :



perl -v

Setting up Environment Variable

  • Step 1: Click the Advanced system settings link.

  • Step 2: Click Environment Variables. In the section System Variables, find the PATH environment variable and select it. Click Edit. If the PATH environment variable does not exist, click New.

  • Step 3: In the Edit System Variable (or New System Variable) window, specify the value of the PATH environment variable. Click OK. Close all remaining windows by clicking OK.

Working on Sublime Text3

Step 1: Goto tools->build system and select New Build System.

Step 2: Copy the below code :

filter_none

edit
close

play_arrow

link
brightness_4
code

{
  "cmd": ["perl", "-w", "$file"],
  "file_regex": ".* at (.) line ([0-9])",
  "selector": "source.perl"
}

chevron_right


Then save it as Perl.sublime-build

Step 3: Last step is to create any file and save it as “anythng.pl” and press ctrl + shift + B to run.

My Personal Notes arrow_drop_up

Check out this Author's contributed articles.

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.


Article Tags :
Practice Tags :


Be the First to upvote.


Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.