Close Editor Shortcut collides with Chrome Close Tab which kills GitPod

When GitPod runs in Chrome on Mac, the File > Close Editor shortcut is Command+W , which coincides with the Chrome close Tab shortcut. Effectively resulting in killing the whole GitPod environment when I mean to just close the file I’m currently editing in GitPod (for example the frequent github COMMIT_EDITMSG file).

Is there a reason the default shortcut for Chrome on Mac was chosen to be Command+W. If I am not mistaken in a previous version of GitPod the shortcut was Option+W which worked fine.

I assume you are using VS Code, not Theia. VS Code team decided to avoid having different shortcuts between desktop and Web versions. If you have any dirty changes you should see a dialog preventing you to close the page. You can also configure "window.confirmBeforeClose": "always", to see this dialog always.

Notice we are looking into providing PWA to have more control: https://github.com/gitpod-io/gitpod/pull/3699 But even on desktop if you have no editors opened VS Code will close the window.

That’s a good question. I was happy with Theia, but when I recently enabled Preview Features, I got switched to VS Code as a recommended editor.

Which editor is the recommended default going forward?

VS Code should be default, in long run Theia will go away. But in regards to this issue it is the same in both (basically a browser limitation).

OK, thank you for clarifying. Very helpful to have some long term visibility.

For now I just changed the shortcut to Option+W in my GitPod VS Code instance.

Maybe something to consider for future GitPod versions is to change the VS Code default settings file within GitPod deployments. It’s probably a fairly common issue for Mac users.