nim-lang / vscode-nim

A VS Code plugin for the Nim language
Other
75 stars 8 forks source link

add support for `nimpretty` to format on save #108

Closed pouriyajamshidi closed 4 days ago

pouriyajamshidi commented 5 days ago

Hi,

Thanks for working on Nim's tooling. The experience has definitely improved.

I was wondering if you have any plans adding support for running nimpretty to format the code on save?

Not sure if it already exists but at least I could not find it.

Thanks in advance

jmgomez commented 4 days ago

We just released a new version that adds support for formatting via nph see https://forum.nim-lang.org/t/12525

pouriyajamshidi commented 4 days ago

The issue was about nimpretty. isn't nimpretty the official formatter for Nim?

jmgomez commented 4 days ago

It's the default formatter for the nimlangserver as people seemed to like it more. That said, feel free to submit a PR that opt-in it.