Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enrich yarn web to include GH support #97708

Closed
bpasero opened this issue May 13, 2020 · 6 comments
Closed

Enrich yarn web to include GH support #97708

bpasero opened this issue May 13, 2020 · 6 comments
Assignees
Labels
plan-item VS Code - planned item for upcoming web Issues related to running VSCode in the web
Milestone

Comments

@bpasero
Copy link
Member

bpasero commented May 13, 2020

Today you can run the web version of VSCode "serverless" via yarn web. In this model we add a single extension into the staticExtensions property to run it inside the web worker and that one registers a file system provider:

context.subscriptions.push(vscode.workspace.registerFileSystemProvider(SCHEME, memFs, { isCaseSensitive: true }));

This is an in-memory provider and the idea would be to use a GH provider, maybe depending on a query parameter in the URL. This would only provide a readonly view on a repository, but that is fine to begin with. We could expand the capabilities depending on available API, e.g. allowing to search.

My understanding is that Eric you already wrote a file system provider once for GH that we could maybe use here.

@bpasero bpasero added plan-item VS Code - planned item for upcoming web Issues related to running VSCode in the web labels May 13, 2020
@bpasero bpasero added this to the May 2020 milestone May 13, 2020
@bpasero bpasero modified the milestones: May 2020, June 2020 Jun 3, 2020
@eamodio
Copy link
Contributor

eamodio commented Jun 9, 2020

This is now supported using a ?gh=<user>/<repo> query string

@eamodio eamodio closed this as completed Jun 9, 2020
@bpasero
Copy link
Member Author

bpasero commented Jun 10, 2020

@eamodio having trouble trying this out, is there something I need to do other than running yarn web with that URL?

After the auth callback, I see this in VSCode:

image

And the callback seems to be returning to a "Not Found" page?

@eamodio
Copy link
Contributor

eamodio commented Jun 10, 2020

Sorry I forgot to mention, that we can't currently support the full auth flow in yarn web (because GitHub won't allow a local host return URI). But you can provide a personal access token instead by clicking on the status bar entry when the auth flow starts. That will then be saved in local storage.

@bpasero
Copy link
Member Author

bpasero commented Jun 10, 2020

Ok thanks, will try that.

I pushed 6a927e6 to fix a bad path for callback.html that was still pointing to the old location.

@eamodio
Copy link
Contributor

eamodio commented Jun 10, 2020

Awesome, thanks!

@github-actions github-actions bot locked and limited conversation to collaborators Jul 24, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
plan-item VS Code - planned item for upcoming web Issues related to running VSCode in the web
Projects
None yet
Development

No branches or pull requests

3 participants
@eamodio @bpasero and others