Closed ghost closed 1 year ago
I've been thinking about how to do this for a while, we might come up with a solution eventually 🙂
Note that vscode.dev doesn't have a backing server like replit, replit is closer to Codespaces which is backed by a dev container.
https://github.com/microsoft/vscode/issues/135207#issuecomment-944956647
@Tyriar I'll be interested to see if the team comes up with a solution someday.
StackBlitz previously announced WebContainer which supports running Node.js and npm (including http server) all in browsers. Maybe vscode.dev can adopt that after their GA or build a similar thing itself.
But ultimately, I don't expect it to support every program unless using a virtual machine. Because we only need the terminal it may not be completely impossible.
@yume-chan if web container is open sourced and has a license we can use we could leverage their work, otherwise we'd need to build our own similar thing.
what about being able to use a terminal over an ssh connection? would it be possible to do something like cloud shell from GCP?
@egeucak that would be possible, but that's a different thing and essentially what Codespaces is.
"if web container is open sourced and has a license we can use we could leverage their work, otherwise we'd need to build our own similar thing."
Or perhaps, Microsoft could buy StackBlitz in order to make the process quicker...
"StackBlitz is the first online IDE whose compute model makes sense to me."
TOM PRESTON-WERNER, founder of GitHub & investor in StackBlitz - Introducing WebContainers
What about wasi-fs-access ?
This is a demo shell powered by WebAssembly, WASI, Asyncify and File System Access API. https://github.com/GoogleChromeLabs/wasi-fs-access
Yep that would be one approach
How about adding a shell for CPython only for now? The main branch of CPython now compiles to web assembly. So it should/could be feasible to integrate it so that it can access the same data as within vscode.dev.
Example: https://repl.ethanhs.me/ Build scripts: https://github.com/ethanhs/python-wasm
@agowa338 even just that is easier said than done, also we don't include Python smarts out of the box so it would need to come in via an extension anyway. I think an extension could implements that via the Pseudoterminal extension API, my main worry there would be in pushing something out that might end up getting ripped out, angering users later.
Not planning on pursuing this anytime soon
We closed this issue because we don't plan to address it in the foreseeable future. If you disagree and feel that this issue is crucial: we are happy to listen and to reconsider.
If you wonder what we are up to, please see our roadmap and issue reporting guidelines.
Thanks for your understanding, and happy coding!
Similar to Replit, I would like to ask to add some sort of terminal to the online version of vscode. This could help people on limited devices download external packages, run their program, and more. Replit has a full shell and terminal built into each project, and it allows for full functionality of a typical shell. This would be extremely beneficial to people using languages such as Go, Python, etc. along with others using c/c++ that would like to download libraries like curlpp.