You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When managing dbt sources and schema YAML files, the lack of built-in sorting often leads to inconsistent ordering of elements like sources, tables, and models. Over time, especially in large projects with many contributors, this inconsistency makes the files harder to read, review, and maintain.
It would be highly beneficial to introduce a built-in or officially supported way to sort YAML definitions by name, particularly for:
sources under schema.yml
tables under each source
models and other dbt resource declarations
This could be implemented as:
A command-line utility (e.g., dbt sort-yaml)
A pre-commit plugin maintained under the dbt-labs ecosystem
Adding such a feature would improve YAML consistency, reduce merge conflicts, and make diffs easier to interpret in pull requests.
Let me know if this proposal aligns with the dbt community’s direction or if there’s an existing solution worth contributing to.
If this feature does not currently exist in the dbt ecosystem or roadmap, I’m happy to contribute by developing the functionality myself and submitting a pull request. Please let me know if this would be a welcome contribution or if there are existing guidelines I should follow.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
When managing dbt sources and schema YAML files, the lack of built-in sorting often leads to inconsistent ordering of elements like sources, tables, and models. Over time, especially in large projects with many contributors, this inconsistency makes the files harder to read, review, and maintain.
It would be highly beneficial to introduce a built-in or officially supported way to sort YAML definitions by name, particularly for:
This could be implemented as:
Adding such a feature would improve YAML consistency, reduce merge conflicts, and make diffs easier to interpret in pull requests.
Let me know if this proposal aligns with the dbt community’s direction or if there’s an existing solution worth contributing to.
If this feature does not currently exist in the dbt ecosystem or roadmap, I’m happy to contribute by developing the functionality myself and submitting a pull request. Please let me know if this would be a welcome contribution or if there are existing guidelines I should follow.
Beta Was this translation helpful? Give feedback.
All reactions