[Guide] Omarchy Themes - VS Code extension override #5508
Replies: 1 comment
|
Thanks for the guide @cfulton — really useful pattern. One edge case worth flagging: the override approach assumes there's an alternative extension on Open VSX to point to. For some Omarchy-shipped themes that's not true. Concrete example — the Ethereal theme uses Same applies (I suspect) to other For those themes there's no OVSX alternative to swap to via your override pattern, so VSCodium users have only two options:
Long-term I think the cleanest fix is for theme authors to dual-publish to Open VSX (free via |
Uh oh!
There was an error while loading. Please reload this page.
Omarchy Themes - VS Code extension override
Each theme in Omarchy is stored in the themes/ directory. Within each theme, there is a
vscode.configfile that specifies the extension and theme names for Omarchy to use when applying a theme to VS Code (code,code-insiders,codium, andcursor).After installing Omarchy, those themes are located in the system at
~/.local/share/omarchy/themes/. Users looking to make changes to their themes should not update from this.localdirectory, as those changes are likely to be lost during updates. Instead, users should create their theme overrides in their.configdirectory for themes~/.config/omarchy/themes/.Omarchy theme selection works by calling
omarchy-theme-set, which does the following in order:Copies the
.localversion of the theme~/.local/share/omarchy/themes/<theme>/to~/.config/omarchy/current/theme/Copies the
.configversion of the theme~/.config/omarchy/themes/<theme>/to~/.config/omarchy/current/theme/. This overrides any of the.localfiles for the current theme with the.configfiles.Handles updating the current theme for applications.
Knowing this, we can update the VS Code theme extension used by Omarchy Themes on our system.
How to create a VS Code theme override
The current Everforest theme uses the VS Code theme extension
sainnhe.everforest, that extension is deprecated causing warning about the deprecated extension.I will use this as an example of how to change the theme's extension in VS Code to
reesew.everforest-theme. If you are making changes that are not for the Everforest theme VS Code extension, then you will need to change some of the commands.vscode.config~/.config/omarchy/themes/everforest/vscode.jsonIt will look like this:
{ "name": "Everforest Dark", "extension": "sainnhe.everforest" }Update it so it looks like this:
{ "name": "Everforest Dark", "extension": "reesew.everforest-theme" }omarchy-theme-refreshin the terminal, or next time you change Omarchy's theme to Everforest, it will refresh the VS Code theme to the new extension theme.Note: Don't forget to remove the previous no longer needed extension from VS Code.
Alternatively, if you are game to update the repo and fix the issue, see PR #5498.
All reactions