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

Add the ability to sort inline tables and inline arrays #33

Merged
merged 3 commits into from
Dec 31, 2022

Conversation

jonathangreen
Copy link
Contributor

This PR makes a few related changes:

  • Optionally add the ability to sort inline tables and arrays (new switches added for this functionality: --sort-inline-tables and --sort-inline-arrays, which are implied by the --all option
  • Add new options groups to the cli, to group the related formatting, comment, and sorting args
  • Add some additional formatting checks
    • Make sure inline arrays and tables are consistently formatted
    • normalize the formatting for key = value pairs, always one space on either side of equals sign
    • Add switch to add trailing comma to multi-line inline arrays --trailing-comma-inline-array

@jonathangreen jonathangreen force-pushed the feature/sort-everything branch from 275d00e to 38d9320 Compare December 31, 2022 03:23
@pappasam
Copy link
Owner

Love it! Tested everything locally, code looks great, the consistency additions are much-needed, and the naming choices are fantastic. 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.

2 participants