-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Please provide documentation how to use perltidy in Visual Studio Code #147
Comments
Hi @horshack, thanks for filing the issue. Additional documentation sounds good to me, especially since Perl Navigator supports both "Format Selection" and "Format Document" options, as shown below. I'm surprised it works in "Simple Perl", but not in "Perl Navigator". Neither of them have perltidy bundled, so it must already be installed in your version of perl. Are you using the system install of Perl? If you need to point to a different installation of Perl, you can set the params "perlnavigator.perlPath". Did you provide any settings to |
Hello,
I have installed the Perlmodule perltidy in my local systemwide perl -
/usr/bin/perl
I did not provide any settings in the VSCode extension "Simple Perl", it
works in reformatting like described.
Now I disable the VSCode extention "Simple Perl" and install and
activate the VSCode extention "Perl Navigator".
Restarting VSCode.
I provide some misformatted perl code. Select all lines in file,
right-click, Menu: format selection. Error: Configuare Default Formatter
- Extension zhiyan-lin.simple-perl is configured as formatter but not
available. Cancel-configure. That's right, it WAS my code formatter for
perl, but it is not available anymore.
I press the button configure... I select from a dropdown list the only
single option: Perl Navigator bcan.perlnavigator. Nothing happens,
nothing happens to the code.
Restarting Vscode: I provide some misformatted perl code. Select all
lines in file, right-click, Menu: format selection., nothing happens to
the code.
I usually do not use system perl but perlbrew. For perlbrew I don't know
how to configure it in VScode. When I do:
perlbrew user 5-34.0
I get this as "which perl".
/Users/richard/perl5/perlbrew/perls/perl-5.34.0/bin/perl
Do I have to type this whole perl-path into the parameter
perlnavigator.perlPath?
Thanks for your good work,
Richard
…------ Originalnachricht ------
Von "bscan" ***@***.***>
An "bscan/PerlNavigator" ***@***.***>
Cc "Richard Lippmann" ***@***.***>; "Mention"
***@***.***>
Datum 16.10.2024 22:41:00
Betreff Re: [bscan/PerlNavigator] Please provide documentation how to
use perltidy in Visual Studio Code (Issue #147)
Hi @horshack <https://github.com/horshack>, thanks for filing the
issue. Additional documentation sounds good to me, especially since
Perl Navigator supports both "Format Selection" and "Format Document"
options, as shown below.
284102994-55f58d48-7c0f-4d80-bfca-98180208ffe2.gif (view on web)
<https://github.com/user-attachments/assets/490b483e-0e92-42cb-ae97-9931f151f357>
I'm surprised it works in "Simple Perl", but not in "Perl Navigator".
Neither of them have perltidy bundled, so it must already be installed
in your version of perl. Are you using the system install of Perl? If
you need to point to a different installation of Perl, you can set the
params "perlnavigator.perlPath". Did you provide any settings to
simple-perl?
—
Reply to this email directly, view it on GitHub
<#147 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABI3TFMSKUD47RJCGITEOTZ33FNZAVCNFSM6AAAAABQA53C4CVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIMJXHEYTENZUGA>.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
I try to format my perl-code with perltidy in Visual Studio Code. This can be done because mentioned in
https://github.com/bscan/PerlNavigator/
Currently Implemented Features: Code formatting via Perl::Tidy
Ok, but how can I do this? I tried it with the VSCode extension "Perl Simple" described in https://stackoverflow.com/questions/79089661/how-to-use-perltidy-to-reformat-code-in-visual-studio-code/79093098#79093098 like this:
+++
VSCode has a beautifier way for every kind of file.
A VSCode extension must get installed to use it. I installed the extension: Simple Perl. After that I highlighted some perl code in some perl file. Right-click - Menue: Format selection. The code gets formatted.
+++
I tried the same with PerlNavigator, but this changes nothing in the code. perltidy seems not to get called.
Could you please describe in
https://github.com/bscan/PerlNavigator/
how I can reformat code in Visual Studio Code with the extension PerlNavigator?
The text was updated successfully, but these errors were encountered: