puppet-vscode icon indicating copy to clipboard operation
puppet-vscode copied to clipboard

Decouple formatting from linting

Open dhs-rec opened this issue 4 years ago • 2 comments

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".

dhs-rec avatar Aug 02 '21 09:08 dhs-rec

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.

jpogran avatar Aug 02 '21 15:08 jpogran

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

rodolfo-gonzalez avatar Apr 25 '23 22:04 rodolfo-gonzalez