mirror of
https://github.com/microsoft/vscode.git
synced 2026-05-08 09:08:48 +01:00
@@ -64,16 +64,6 @@ const serverResourceIncludes = [
|
||||
'out-build/vs/base/node/cpuUsage.sh',
|
||||
'out-build/vs/base/node/ps.sh',
|
||||
|
||||
// Terminal shell integration
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/shellIntegration.ps1',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/CodeTabExpansion.psm1',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/GitTabExpansion.psm1',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/shellIntegration-bash.sh',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/shellIntegration-env.zsh',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/shellIntegration-profile.zsh',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/shellIntegration-rc.zsh',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/shellIntegration-login.zsh',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/fish_xdg_data/fish/vendor_conf.d/shellIntegration.fish',
|
||||
];
|
||||
|
||||
const serverResourceExcludes = [
|
||||
|
||||
+10
-10
@@ -85,11 +85,11 @@ const vscodeResourceIncludes = !isAMD() ? [
|
||||
'out-build/vs/workbench/contrib/externalTerminal/**/*.scpt',
|
||||
|
||||
// Terminal shell integration
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/fish_xdg_data/fish/vendor_conf.d/*.fish',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/*.ps1',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/*.psm1',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/*.sh',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/*.zsh',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/fish_xdg_data/fish/vendor_conf.d/*.fish',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/*.ps1',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/*.psm1',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/*.sh',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/*.zsh',
|
||||
|
||||
// Accessibility Signals
|
||||
'out-build/vs/platform/accessibilitySignal/browser/media/*.mp3',
|
||||
@@ -130,11 +130,11 @@ const vscodeResourceIncludes = !isAMD() ? [
|
||||
'out-build/vs/workbench/browser/media/*-theme.css',
|
||||
'out-build/vs/workbench/contrib/debug/**/*.json',
|
||||
'out-build/vs/workbench/contrib/externalTerminal/**/*.scpt',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/fish_xdg_data/fish/vendor_conf.d/*.fish',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/*.ps1',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/*.psm1',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/*.sh',
|
||||
'out-build/vs/workbench/contrib/terminal/browser/media/*.zsh',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/fish_xdg_data/fish/vendor_conf.d/*.fish',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/*.ps1',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/*.psm1',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/*.sh',
|
||||
'out-build/vs/workbench/contrib/terminal/common/scripts/*.zsh',
|
||||
'out-build/vs/workbench/contrib/webview/browser/pre/*.js',
|
||||
'!out-build/vs/workbench/contrib/issue/**/*-dev.html',
|
||||
'!out-build/vs/workbench/contrib/issue/**/*-dev.esm.html',
|
||||
|
||||
@@ -112,7 +112,7 @@ export async function main(argv: string[]): Promise<any> {
|
||||
case 'fish': file = 'fish_xdg_data/fish/vendor_conf.d/shellIntegration.fish'; break;
|
||||
default: throw new Error('Error using --locate-shell-integration-path: Invalid shell type');
|
||||
}
|
||||
console.log(join(getAppRoot(), 'out', 'vs', 'workbench', 'contrib', 'terminal', 'browser', 'media', file));
|
||||
console.log(join(getAppRoot(), 'out', 'vs', 'workbench', 'contrib', 'terminal', 'common', 'scripts', file));
|
||||
}
|
||||
|
||||
// Extensions Management
|
||||
|
||||
@@ -321,13 +321,13 @@ enum ShellIntegrationExecutable {
|
||||
|
||||
const shellIntegrationArgs: Map<ShellIntegrationExecutable, string[]> = new Map();
|
||||
// The try catch swallows execution policy errors in the case of the archive distributable
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.WindowsPwsh, ['-noexit', '-command', 'try { . \"{0}\\out\\vs\\workbench\\contrib\\terminal\\browser\\media\\shellIntegration.ps1\" } catch {}{1}']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.WindowsPwshLogin, ['-l', '-noexit', '-command', 'try { . \"{0}\\out\\vs\\workbench\\contrib\\terminal\\browser\\media\\shellIntegration.ps1\" } catch {}{1}']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.Pwsh, ['-noexit', '-command', '. "{0}/out/vs/workbench/contrib/terminal/browser/media/shellIntegration.ps1"{1}']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.PwshLogin, ['-l', '-noexit', '-command', '. "{0}/out/vs/workbench/contrib/terminal/browser/media/shellIntegration.ps1"']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.WindowsPwsh, ['-noexit', '-command', 'try { . \"{0}\\out\\vs\\workbench\\contrib\\terminal\\common\\scripts\\shellIntegration.ps1\" } catch {}{1}']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.WindowsPwshLogin, ['-l', '-noexit', '-command', 'try { . \"{0}\\out\\vs\\workbench\\contrib\\terminal\\common\\scripts\\shellIntegration.ps1\" } catch {}{1}']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.Pwsh, ['-noexit', '-command', '. "{0}/out/vs/workbench/contrib/terminal/common/scripts/shellIntegration.ps1"{1}']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.PwshLogin, ['-l', '-noexit', '-command', '. "{0}/out/vs/workbench/contrib/terminal/common/scripts/shellIntegration.ps1"']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.Zsh, ['-i']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.ZshLogin, ['-il']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.Bash, ['--init-file', '{0}/out/vs/workbench/contrib/terminal/browser/media/shellIntegration-bash.sh']);
|
||||
shellIntegrationArgs.set(ShellIntegrationExecutable.Bash, ['--init-file', '{0}/out/vs/workbench/contrib/terminal/common/scripts/shellIntegration-bash.sh']);
|
||||
const pwshLoginArgs = ['-login', '-l'];
|
||||
const shLoginArgs = ['--login', '-l'];
|
||||
const shInteractiveArgs = ['-i', '--interactive'];
|
||||
|
||||
@@ -47,8 +47,8 @@ suite('platform - terminalEnvironment', () => {
|
||||
// These tests are only expected to work on Windows 10 build 18309 and above
|
||||
(getWindowsBuildNumber() < 18309 ? suite.skip : suite)('pwsh', () => {
|
||||
const expectedPs1 = process.platform === 'win32'
|
||||
? `try { . "${repoRoot}\\out\\vs\\workbench\\contrib\\terminal\\browser\\media\\shellIntegration.ps1" } catch {}`
|
||||
: `. "${repoRoot}/out/vs/workbench/contrib/terminal/browser/media/shellIntegration.ps1"`;
|
||||
? `try { . "${repoRoot}\\out\\vs\\workbench\\contrib\\terminal\\common\\scripts\\shellIntegration.ps1" } catch {}`
|
||||
: `. "${repoRoot}/out/vs/workbench/contrib/terminal/common/scripts/shellIntegration.ps1"`;
|
||||
suite('should override args', () => {
|
||||
const enabledExpectedResult = Object.freeze<IShellIntegrationConfigInjection>({
|
||||
newArgs: [
|
||||
@@ -126,10 +126,10 @@ suite('platform - terminalEnvironment', () => {
|
||||
new RegExp(`.+\\/${username}-vscode-zsh\\/\\.zlogin`)
|
||||
];
|
||||
const expectedSources = [
|
||||
/.+\/out\/vs\/workbench\/contrib\/terminal\/browser\/media\/shellIntegration-rc.zsh/,
|
||||
/.+\/out\/vs\/workbench\/contrib\/terminal\/browser\/media\/shellIntegration-profile.zsh/,
|
||||
/.+\/out\/vs\/workbench\/contrib\/terminal\/browser\/media\/shellIntegration-env.zsh/,
|
||||
/.+\/out\/vs\/workbench\/contrib\/terminal\/browser\/media\/shellIntegration-login.zsh/
|
||||
/.+\/out\/vs\/workbench\/contrib\/terminal\/common\/scripts\/shellIntegration-rc.zsh/,
|
||||
/.+\/out\/vs\/workbench\/contrib\/terminal\/common\/scripts\/shellIntegration-profile.zsh/,
|
||||
/.+\/out\/vs\/workbench\/contrib\/terminal\/common\/scripts\/shellIntegration-env.zsh/,
|
||||
/.+\/out\/vs\/workbench\/contrib\/terminal\/common\/scripts\/shellIntegration-login.zsh/
|
||||
];
|
||||
function assertIsEnabled(result: IShellIntegrationConfigInjection, globalZdotdir = homedir()) {
|
||||
strictEqual(Object.keys(result.envMixin!).length, 3);
|
||||
@@ -190,7 +190,7 @@ suite('platform - terminalEnvironment', () => {
|
||||
const enabledExpectedResult = Object.freeze<IShellIntegrationConfigInjection>({
|
||||
newArgs: [
|
||||
'--init-file',
|
||||
`${repoRoot}/out/vs/workbench/contrib/terminal/browser/media/shellIntegration-bash.sh`
|
||||
`${repoRoot}/out/vs/workbench/contrib/terminal/common/scripts/shellIntegration-bash.sh`
|
||||
],
|
||||
envMixin: {
|
||||
VSCODE_INJECTION: '1'
|
||||
@@ -204,7 +204,7 @@ suite('platform - terminalEnvironment', () => {
|
||||
const enabledExpectedResult = Object.freeze<IShellIntegrationConfigInjection>({
|
||||
newArgs: [
|
||||
'--init-file',
|
||||
`${repoRoot}/out/vs/workbench/contrib/terminal/browser/media/shellIntegration-bash.sh`
|
||||
`${repoRoot}/out/vs/workbench/contrib/terminal/common/scripts/shellIntegration-bash.sh`
|
||||
],
|
||||
envMixin: {
|
||||
VSCODE_INJECTION: '1',
|
||||
|
||||
Executable → Regular
Reference in New Issue
Block a user