Open annappropriate opened 4 years ago
You can't install monkey patch in vscode server. What would be the point?
Monkey patch is used to customize vscode UI, and the UI is not running in vscode-server instances, only extensions are.
The UI is running on your windows machine, that's where you need to have customize UI installed.
@knopp that makes sense, but I don't see any option to install it locally. For anyone wondering how to make this work with WSL, here's how to do it:
@knopp, if I may, you could add this to iocave/customize-ui's README ;) (I can do a PR if you want)
PS: Each time you want to change a setting, you'll have to get out of the WSL Host, as customize-ui's settings won't appear while vscode is hosted by WSL.
I also hope that extensions can declare this in some manifest in the future, as to handle this properly without having to switch back. Some extensions already do this (i.e. when you install them you see the "Installed locally" instead of "Installed on WSL: Ubuntu") but I'm guessing that this is reserved to color themes
You just install the extension before logging to remote server. The vscode server is a headless instance, it doesn't have any UI and there is nothing cutomize-ui can do there.
When you edit configuration while being connected to remote vscode (Preferences: Open User Settings
) you will not get the Reload window prompt, but you can still reload the window manually (Developer: Reload window
) to refresh changes.
Documenting this would be nice. I did get this error every time I opened a WSL window which is pretty annoying. Would be also great to silence the error if possible.
There shouldn't be any error if you don't install the extension in the remote host. It simply shouldn't be installed there. As for documentations, pull requests are always welcome :)
Yeah, I got that, but I was just saying that, for the end user, knowing the implementation details is not important, and—just as installing color themes from the WSL installs them locally without any user friction—I was wondering if there was a way to mark the extension as "local only" so that it could be installed locally, but from WSL, because having to switch back is just an inconvenience. If Color Themes are a special case and there's no way to tell vscode where to install it, then yes adding this atop the README will help, I can definitely do a pr for that.
Users can add this to settings.json file:
"remote.extensionKind": {
"iocave.customize-ui": ["ui"],
"iocave.monkey-patch": ["ui"]
},
Extension developers can add this to the manifest (package.json):
"extensionKind": ["ui"]
Extension developers can add this to the manifest (package.json):
There, this is what I was talking about: developers should be telling vscode where to install the extension, not users
@QWp6t @ewen-lbh just opened PR #18 for this matter
"Cannot activate the 'Customize UI' extension because it depends on the 'Monkey Patch' extension, which is not loaded. Would you like to reload the window to load the extension? "
I have this message on remote but Customize UI works fine. how to get rid of the message prompt ?
I'm using vscode to connect to a WSL instance and work in Linux. Monkey patch fails to enable. The error I get is:
There's no
code
directory at all:No workbench.htlm file could be found in ~/.vscode-server either.
Any ideas? Extension works fine on local Windows and throws error only in WSL.