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
Sometimes the ordering of the tables changes in the mermaid file after a schema changes (at least with postgres). This can make diffs on that file a bit noisy.
I propose that the tables are alphabetically sorted. This could be done here:
Reasonable proposal - I would sort it by default without an additional flag, because there is no downside in doing so
Ideally sorting is done on database level, but in this limited use case it is perfectly fine with me to do it programmatically (as you mentioned, it can be done independent of the database that is used and performance shouldn't be an issue here)
Feel free to implement it if you like - I will happily accept PRs :) Otherwise I'm happy to do it myself
Sometimes the ordering of the tables changes in the mermaid file after a schema changes (at least with postgres). This can make diffs on that file a bit noisy.
I propose that the tables are alphabetically sorted. This could be done here:
mermerd/analyzer/analyzer.go
Lines 58 to 61 in d02edee
so that it isn't up to the individual database analyzers to worry about this.
If this isn't desirable default behaviour, maybe we could put it behind a
--sortTables
flag.I'd be happy to have a go at implementing this if the approach is agreed upon.
The text was updated successfully, but these errors were encountered: