Is it possible to limit yaml formatting to just indentation and preserving empty lines
Hello,
my question is whether it is possible to limit yaml formatting to just indentation and preserving empty lines. In other words if it's possible to avoid using jackson and sneakyaml, since they have some limitations as mentioned https://github.com/diffplug/spotless/pull/1478#issuecomment-1378634351
Thanks!
Jackson has indeed limitation, amongst which comments removal (https://github.com/diffplug/spotless/issues/1795).
SnakeYAML might be the way to go for this need. (I suspect indentation-only is not that simple, and preserving empty-lines would be an option).
@aldex32 where did you find any SnakeYAML limitations? The above mentioned issue does not contain any limitations for SnakeYAML
https://github.com/google/yamlfmt may also be the way to go to circumvent current Jackson limitations.
@asomov I believe the only limitation is the lack of contribution around SnakeYAML into Spotless. Such a formatter would circumvent many of current issues around Jackson (even it is based on SnakeYAML).