Closed sindresorhus closed 5 years ago
Yes, you can implement that into your plugin.
Just load the settings named Preferences.sublime-settings
and access the relevant fields such as trim_trailing_white_space_on_save
or ensure_newline_at_eof_on_save
.
:)
Only thing I'm wondering about is syntax-specific overrides because (I believe that) .editorconfig
files override anything that would otherwise be set by ST.
So, I think the .editorconfig
generator should attempt to iterate over all syntaxes and check if they have syntax-specific settings. Then include them in the generated .editorconfig
file along with the global settings (inherited from Preferences.sublime-settings
and overridden by project-specific settings).
I'm gonna skip this. Too complicated to get right. I think a dedicated command-line tool for this would be better.
Would be awesome if the plugin could generate an .editorconfig file from the users current settings. That would also make it less scary/hard to get started with it.
PR welcome :)