Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set indent-with-indicator before indicator-indent in dumper options #142

Merged

Conversation

noonian
Copy link
Contributor

@noonian noonian commented Nov 22, 2024

This change allows setting :indent and :indicator-indent to the same value.

Calling setIndicatorIndent throws org.yaml.snakeyaml.error.YAMLException with the message "Indicator indent must be smaller then indent." when (<= indent indicator-indent). If setIndentWithIndicator is true when setIndicatorIndent is called this is not an issue.

So this fix changes the order that we configure the dumper options in order to support the original usecase mentioned in #136 that motivated :indent-with-indicator.

Should resolve #31 and #37 also.

@borkdude borkdude merged commit f01e8f8 into clj-commons:master Nov 22, 2024
14 of 15 checks passed
@borkdude
Copy link
Collaborator

Thanks!

@lread
Copy link
Collaborator

lread commented Nov 22, 2024

Huh! Good find @noonian, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Is it really necessary for :indicator-indent to be less than :indent?
3 participants