« PLS/Server/Request/TextDocument/DidChange.pm
↑ Summary
PLS/Server/Response/ServerNotInitialized.pm »
| 1 | package PLS; | ||
| 2 | |||
| 3 | use strict; | ||
| 4 | use warnings; | ||
| 5 | |||
| 6 | our $VERSION = '0.4'; | ||
| 7 | |||
| 8 | 1; | ||
| 9 | |||
| 10 | __END__ | ||
| 11 | |||
| 12 | =head1 NAME | ||
| 13 | |||
| 14 | PLS - Perl Language Server | ||
| 15 | |||
| 16 | =head1 DESCRIPTION | ||
| 17 | |||
| 18 | The Perl Language Server implements a subset of the Language Server Protocol | ||
| 19 | for the Perl language. Features currently implemented are: | ||
| 20 | |||
| 21 | =over | ||
| 22 | |||
| 23 | =item * Go to definition (for packages, subroutines, and variables) | ||
| 24 | |||
| 25 | =item * Listing all symbols in a document | ||
| 26 | |||
| 27 | =item * Hovering to show documentation | ||
| 28 | |||
| 29 | =item * Signature help (showing parameters for a function as you type) | ||
| 30 | |||
| 31 | =item * Formatting | ||
| 32 | |||
| 33 | =item * Range Formatting | ||
| 34 | |||
| 35 | =item * Auto-completion | ||
| 36 | |||
| 37 | =item * Syntax checking | ||
| 38 | |||
| 39 | =item * Linting (using perlcritic) | ||
| 40 | |||
| 41 | =item * Sorting imports | ||
| 42 | |||
| 43 | =back | ||
| 44 | |||
| 45 | =head1 OPTIONS | ||
| 46 | |||
| 47 | This application does not take any command line options. | ||
| 48 | The following settings may be configured using your text editor: | ||
| 49 | |||
| 50 | =over | ||
| 51 | |||
| 52 | =item perl.inc - a list of paths to include in @INC | ||
| 53 | |||
| 54 | You can use $ROOT_PATH to stand in for your project's root directory, | ||
| 55 | to allow for configuration to work the same for multiple directories | ||
| 56 | of the same project. This is useful if you use SVN and check out each | ||
| 57 | branch to a different directory. | ||
| 58 | |||
| 59 | =item perl.pls - path to pls | ||
| 60 | |||
| 61 | Configure this option if pls is not available in your path. | ||
| 62 | |||
| 63 | =item perl.cwd - the working directory to use for pls | ||
| 64 | |||
| 65 | =item perl.perltidyrc - the location of your C<.perltidyrc> file. | ||
| 66 | |||
| 67 | Defaults to C<~/.perltidyrc> if not configured. | ||
| 68 | |||
| 69 | =item perl.perlcritic.enabled - whether to enable linting using L<perlcritic>. | ||
| 70 | |||
| 71 | =item perl.perlcritic.perlcriticrc - the location of your C<.perlcriticrc> file. | ||
| 72 | |||
| 73 | Defaults to C<~/.perlcriticrc> if not configured. | ||
| 74 | |||
| 75 | =back | ||
| 76 | |||
| 77 | You may configure a .plsignore file in your project's root directory, with | ||
| 78 | a list of Perl glob patterns which you do not want pls to index. | ||
| 79 | |||
| 80 | By default, pls will index everything that looks like a Perl file, with the | ||
| 81 | exception of C<.t> files. | ||
| 82 | |||
| 83 | =head1 CAVEATS | ||
| 84 | |||
| 85 | pls has not been tested with editors other than Visual Studio Code. | ||
| 86 | |||
| 87 | =head1 NOTES | ||
| 88 | |||
| 89 | Install the L<fractalboy.pls|https://marketplace.visualstudio.com/items?itemName=FractalBoy.pls> | ||
| 90 | extension to Visual Studio Code in order to use this language server. | ||
| 91 | |||
| 92 | =head1 COPYRIGHT | ||
| 93 | |||
| 94 | Copyright 2021 Marc Reisner | ||
| 95 | |||
| 96 | =head1 LICENSE | ||
| 97 | |||
| 98 | This library is free software; you may redistribute it and/or | ||
| 99 | modify it under the same terms as Perl itself. |