With clj-yaml is there anyway to retain comments that exist in the file? I am trying to work with a helm chart values file that has loads of useful comments that I want to retain.
a quick google on snakeyaml + comments leads us here: https://github.com/oyse/yedit/issues/15#issuecomment-224613193 so probably no, in the same manner that an EDN or Clojure s-expression parser does not preserve comments
Thanks. This is where the tension between files being for human and computers is an issue. The comments are really useful to explain to auser what they should be doing.
Maybe you can just use string fields as comments then
This question seems to point at some option in snakeyaml: https://stackoverflow.com/questions/76781250/how-to-use-snakeyaml-setprocesscomments-on-loaderoptions-and-dumperoptions
Is there any chance of exposing those options?
you can just use snakeyaml directly, right
In bb?
I guess we could expose some options here: https://github.com/clj-commons/clj-yaml/blob/ab980163accdaf679090dc5ee93e7858e18768f0/src/clojure/clj_yaml/core.clj#L106 Feel free to file an issue + a PR which includes tests.
In bb those snakeyaml things aren't directly exposed
I think we can publish a clj-yaml release, but might as well https://github.com/clj-commons/clj-yaml/issues/104 before doing so, ya?
was thinking of adding native image tests to CI as well, do you think that would be useful/helpful @borkdude?
I'll likely also bump internal deps.