sqlfmt
sqlfmt copied to clipboard
Bug: Comments inside of --fmt:off blocks are still formatted
Describe the bug
The --fmt: off tags should stop all formatting of the contained code, but today that is not the case, since comments may be rendered differently in those blocks
To Reproduce
-- fmt: off
where something_long = something_else_long -- and there is a long comment that should stay on this line
-- fmt: on
Expected behavior
-- fmt: off
where something_long = something_else_long -- and there is a long comment that should stay on this line
-- fmt: on
Actual behavior
-- fmt: off
-- and there is a long comment that should stay on this line
where something_long = something_else_long
-- fmt: on
Additional context
What is the output of sqlfmt --version?
0.5.1