Repository navigation
Conversation
The VS Code tab only looked for VS Code's `code` command, so a machine
with only VSCodium had no way to start a server. VSCodium ships the same
command line: `codium-tunnel serve-web` takes the same arguments and
prints the same ready line, and its server is MIT-licensed with nothing
to accept.
- code_server/cli: a table of editors that serve, in precedence order
(VS Code, then VSCodium), each with its command, serving program,
macOS bundle path, and whether its server has license terms. Adding
a fork is one entry once an install of it is checked: it must ship
`serve-web` and host the server build that command downloads.
- The launcher skips the license step for an editor without terms;
VS Code still waits for Accept and start.
- Settings > Code and the tab's placeholder name the editor found
("VSCodium: …", "Starting VSCodium…"); the feature keeps the name
VS Code.
- Terminal links read and open `vscodium:` addresses as `vscode:` ones.
The settings and VS Code tab tests that name an install run only on macOS and Windows, so on Linux the re-export was unused and `just lint-linux` failed with -D warnings.
|
Also run on the same commit: |
[Medium impact] This PR appears safe to merge; no actionable issues were found. SummaryAdds VSCodium as the server for the VS Code tab when VS Code is absent.
No actionable issues were found. Tests were inspected, not run. Native UI capture was blocked because embedded pages are supported only on macOS and Windows, while this review ran on Linux. Intentional choices: vvarp explicitly describes VS Code precedence, no support for unchecked forks, no consent step for VSCodium, and opening Diagram%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Find an editor] --> B{VS Code found?}
B -->|Yes| C{License accepted?}
C -->|No| D[Show consent]
C -->|Yes| E[Start when a tab needs it]
B -->|No| F{VSCodium found?}
F -->|Yes| E
F -->|No| G[Use a configured server address]
Reviews (1) · Last reviewed commit: "test: re-export Install only for the tes..." · Reviewed by Greptile |
Hi, sorry for unannounced PR, I hope that's okay
Since I am using VS Codium (fork of VS Code with anything microsoft-related removed), I figured it could be useful to make it more first-class citizen. I went with simple solution that doesn't add any new configuration options, but simply detects which one is (VS Codium or VS Code) installed, and picks what's available with VS Code being preferred when both are installed (likely a very rare situation).
All content below the line is from agent session (CC on Opus 5.5)
Thanks!
Summary
The VS Code tab can now be served by VSCodium when VS Code isn't installed. Until now the app only looked for VS Code's
codecommand, so a Mac with only VSCodium had no server to start.VSCodium works the same way. On an installed VSCodium 1.140 I checked that:
codium-tunnel serve-webtakes the same arguments the app passes (--host,--port,--connection-token-file,--accept-server-license-terms).Web UI available atline the supervisor waits for before trusting the port./versionanswers with a 40-hex commit, so the existing probe accepts it.product.jsonhas an emptyserverLicense, so there are no terms to accept.Changes
code_server/cli: a table of editors that serve, in precedence order: VS Code, then VSCodium. Each entry has itsPATHcommand, the serving program beside it, its macOS bundle path, and whether its server has license terms. The search checks each product in turn,PATHbefore its bundle. VS Code therefore wins whenever it's installed, and current users see no change. No new setting.code_server/launcher:Cli::Foundcarries anInstall(product plus program).consent_neededandwantedreplace the three separatelicense_acceptedchecks instartup,plan, andsync. VSCodium skips the license step, and VS Code still waits for Accept and start.open_code, and Open VS Code.vscodium:addresses are read from plain text and open without a confirmation, likevscode:.[code]comment inconfig-gpui.example.toml.Other forks
Other forks aren't detected on purpose. A fork works only if it ships
serve-weband also hosts the server build that command downloads. Cursor, for example, shipscursor-tunnel serve-web, but users report it never finishes downloading. For Windsurf, Kiro, Positron, Trae, and Void I found nothing saying they supportserve-web. Once someone has checked an install of a fork, adding it is one table entry.Validation
Run on macOS arm64 at
026d7983:just ci: passedjust lint-linux: passed (it caught an unused test-only re-export on Linux, fixed in026d7983)just lint-windows: passed (x86_64-pc-windows-gnu cross check)cargo test -p herdr-gpui --locked -- code_server settings_window::controls::code links browser::view_tests::code: 223 passedQA
just ci,just lint-linux,just lint-windowspass locally (macOS arm64)codium-tunnel; VS Code wins wherever each is found; nothing installed finds nothing; VSCodium plans a start with no license; VS Code still asks for consent;synckeeps a VSCodium server running withoutlicense_accepted; Settings > Code shows no license card for VSCodium;vscodium:links are trusted and read from plain textjust run):codium-tunnel serve-webruns, and nothing is left running after the app quits.codium.cmdonPATH: it is found and the tab loads.vscodium://file/…link in a terminal: it opens in VSCodium without asking.Screenshots
None captured: I had no way to grab the native window from the session that made this change. The visible change is text only in Settings > Code and in the VS Code tab's placeholder, and no layout changed.