braver/FileIcons

Theme overrides via User folder

C0Nd3Mnd opened this issue · 2 comments

I'm using Git to sync my Packages/User folder between computers. I followed this guide.

I'm using the "DAneo Classic" theme and wanted to use the FileIcons package with it. This works just fine, however it only works correctly if I follow the instructions under "Enable file icons for 3rd party themes".

Since the Packages/User folder is the only folder being synced between computers, would it be possible to enable file icons for 3rd party themes using a configuration/theme override file inside the Packages/User folder? I tried placing the theme file in the folder and also in Packages/User/FileIcons/theme but it doesn't work.

I really wanted the package to work without any runtime code. I.e. without reading your settings file and then writing files into the Packages dir. Of course support for third party themes could be automated that way, in a way that would also support your use case. But I wanted to avoid the added complexity. Also, now it leverages package overrides in a way that maybe teaches users a little bit about that mechanism.

So, if you want to make full use of the customization features of Sublime Text, syncing the User dir is not enough: you might want to customize other aspects of certain packages.

That said, yes, it should be possible to do what you suggest and automatically create the files needed to support any theme.

The trick here is that you want to override this package, and to do so you would put the override in Packages/FileIcons, not in User/Packages/FileIcons: that's simply how package overrides work in Sublime Text.

I'm currently running a similar setup where I use a git repo to sync my setup between two laptops. It works really well, but you absolutely need to sync the entire Packages directory, not just the User package. Of course you can use .gitignore to only sync what you need. But if you restrict yourself to the User package, you put package overrides and many other subtle possibilities out of reach for your sync solution. It's just not a practical approach, and there is really no reason at all to not sync the Packages directory as a whole if you're smart about what you ignore.

So yes, it should be possible to generate some files. But I don't feel like it's the right solution to the problem. And it goes against the basic premise of this package, and so it will simply probably never happen.