viatsko / linter-perl-remote

Lint Perl 5 on the fly, using perl (B::Lint).

Home Page:https://atom.io/packages/linter-perl-remote

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

linter-perl-remote package

This linter plugin for Linter provides an interface to perl. It will be used with files that have the "Perl" syntax.

Installation

  • Install Perl 5.
  • apm install linter (optional)
    • If you didn't install linter package, it will be installed on first activation.
  • apm install linter-perl

Settings

You can configure linter-perl by editing ~/.atom/config.cson (choose Open Your Config in Atom menu):

"linter-perl":
  # The absolute path of perl interpreter.
  # If this was given, executeCommandViaShell and autoDetectCarton are ignored.
  "executablePath": null
  # Is the command executed via `$SHELL -l`?
  # This is useful when PATH is setup in .bash_profile, etc.
  # If true, executablePath option is ignored.
  "executeCommandViaShell": false
  # Is carton enabled if there are both "cpanfile.snapshot" and "local/"
  # in the current root directory?
  "autoDetectCarton": true
  # This is passed to the perl interpreter directly.
  "additionalPerlOptions": null
  # Relative include paths from the current root directory.
  "incPathsFromProjectRoot": [".", "lib"]
  # B::Lint options. "-MO=Lint,HERE"
  # ex. "all,no-bare-subs,no-context"
  "lintOptions": "all"

In order to work with remote server, you need this in the root of your perl project:

{
  "host": "dev-star",
  "root": "/usr/local/myremotetreerepo",
  "executable": "/usr/local/bin/perl"
}

NOTE: "The current root directory" is the root directory in tree-view which contains the file opened in the active text editor. If no root directories contain the file, its parent directory is selected as the current root directory.

plenv Support

There are three ways to use this package with plenv:

  • Open a project by atom . in your shell.
  • Otherwise (e.g. drag & drop),
    • set "/absolute/path/to/.plenv/shims" to perlExecutablePath (this way is not portable)
    • set true to executeCommnadViaShell (perlExecutablePath is ignored)

Perlbrew is not tested, but those methods could be used.

Contributing

If you would like to contribute enhancements or fixes, please do the following:

  1. Fork the plugin repository.
  2. Hack on a separate topic branch created from the latest master.
  3. Commit and push the topic branch.
  4. Make a pull request.
  5. welcome to the club

Please note that modifications should follow these coding guidelines:

  • Indent is 2 spaces.
  • Code should pass coffeelint linter.
  • Vertical whitespace helps readability, don’t be afraid to use it.

Thank you for helping out!

About

Lint Perl 5 on the fly, using perl (B::Lint).

https://atom.io/packages/linter-perl-remote


Languages

Language:CoffeeScript 100.0%