- 
  Notifications
 You must be signed in to change notification settings 
- Fork 520
 Pass the path to shellIntegration.ps1 directly to the server
 #4959
 
 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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | 
|---|---|---|
|  | @@ -610,6 +610,11 @@ export class SessionManager implements Middleware { | |
| }); | ||
| }; | ||
|  | ||
| // When Terminal Shell Integration is enabled, we pass the path to the script that the server should execute. | ||
| // Passing an empty string implies integration is disabled. | ||
| const shellIntegrationEnabled = vscode.workspace.getConfiguration("terminal.integrated.shellIntegration").get<boolean>("enabled"); | ||
| const shellIntegrationScript = path.join(vscode.env.appRoot, "out", "vs", "workbench", "contrib", "terminal", "browser", "media", "shellIntegration.ps1"); | ||
| There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @Tyriar I'm taking a hard dependency on this relative-to-app-root path. You all have too, but just internally as far as I can tell. Trust me, it was no good going down the road of passing  There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Good to know, chances of that path changing are very slim anyway | ||
|  | ||
| const clientOptions: LanguageClientOptions = { | ||
| documentSelector: this.documentSelector, | ||
| synchronize: { | ||
|  | @@ -622,7 +627,7 @@ export class SessionManager implements Middleware { | |
| initializationOptions: { | ||
| enableProfileLoading: this.sessionSettings.enableProfileLoading, | ||
| initialWorkingDirectory: await validateCwdSetting(this.logger), | ||
| shellIntegrationEnabled: vscode.workspace.getConfiguration("terminal.integrated.shellIntegration").get<boolean>("enabled"), | ||
| shellIntegrationScript: shellIntegrationEnabled ? shellIntegrationScript : "", | ||
| }, | ||
| errorHandler: { | ||
| // Override the default error handler to prevent it from | ||
|  | ||