Skip to content
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

Decouple formatting from linting #765

Open
dhs-rec opened this issue Aug 2, 2021 · 2 comments
Open

Decouple formatting from linting #765

dhs-rec opened this issue Aug 2, 2021 · 2 comments

Comments

@dhs-rec
Copy link

dhs-rec commented Aug 2, 2021

Summary of the new feature
As a user
I would like to have formatting and linting separated from each other
so that the formatter doesn't rearrange code at will based on the default linting settings, which are currently not configurable (see #764)

This could also be based on a configuration option "Formatter should use puppet-lint".

@jpogran
Copy link
Contributor

jpogran commented Aug 2, 2021

Formatting and linting are currently separated from each other, but it may not look like it at first glance.

This extension uses puppet-lint to lint Puppet code. In #764, I explained there are configuration files for puppet-lint that will be parsed by this extension. It will also respect control comments inside Puppet code.

This extension uses puppet-lint to format Puppet code. You can configure VS Code to only format when you run the format coomand, on a delay, or when you save the file. You can also configure it to only format parts of the file that have changed by setting editor.formatOnSaveMode to modifications.

@rodolfo-gonzalez
Copy link

@jpogran modifications doesn't seem to work, only works when set to file

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants