-
Notifications
You must be signed in to change notification settings - Fork 30.7k
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
TerminalShellExecution#cwd should not be an URI or string #208638
Comments
same for |
It will actually never be a
This is a very valid scenario, consider SSHing some remote that VS Code knows nothing about, or some shell reports via a virtual file system that we're not aware of, etc. |
How should an extension use the
Make it |
We've touched on this in a past API sync a few months ago and It's worth mentioning that there are several shell/process-related cwds as strings currently, where these are the strings directly passed to vscode/src/vscode-dts/vscode.d.ts Lines 8134 to 8139 in 738438c
vscode/src/vscode-dts/vscode.d.ts Lines 8243 to 8247 in 738438c
vscode/src/vscode-dts/vscode.d.ts Lines 11720 to 11723 in 738438c
I don't think it's possible to get this as a URI, so we would be hiding information that may be useful - for example we find it useful and display the cwd in the terminal tab, exactly as it's reported by the shell. Shells can give us whatever they want for the cwd. If we went with |
Aren't those samples all about extensions giving data to us, not us giving data to extensions? |
Yep. Thanks for the feedback, I'll have a deeper think about it next month |
Testing #208462
The
cwd: Uri | string | undefined;
doesn't seem helpful becausestring
basically means "VS Code couldn't figure this out, good luck to you". In the API we do the hard part and extensions should have easy times, meaning it should beURI | undefined
The text was updated successfully, but these errors were encountered: