forked from qt-creator/qt-creator
Terminal: Escape spaces for powershell paths
For the users that have a space in their user name, the location of the shellintegration.ps1 is a path with a space in it. This patchset fixes the escaping of that space. Change-Id: Iae84b2e8a8f1b4e2b7e523e28417caaeb77bc5cd Reviewed-by: Marcus Tillmanns <marcus.tillmanns@qt.io>
This commit is contained in:
@@ -199,7 +199,7 @@ void ShellIntegration::prepareProcess(Utils::Process &process)
|
|||||||
m_tempDir.filePath(filesToCopy.pwsh.script.fileName()));
|
m_tempDir.filePath(filesToCopy.pwsh.script.fileName()));
|
||||||
rcPath.copyFile(tmpRc);
|
rcPath.copyFile(tmpRc);
|
||||||
|
|
||||||
cmd.addArgs(QString("-noexit -command try { . \"%1\" } catch {Write-Host \"Shell "
|
cmd.addArgs(QString("-noexit -command try { . '%1' } catch {Write-Host \"Shell "
|
||||||
"integration error:\" $_}")
|
"integration error:\" $_}")
|
||||||
.arg(tmpRc.nativePath()),
|
.arg(tmpRc.nativePath()),
|
||||||
CommandLine::Raw);
|
CommandLine::Raw);
|
||||||
|
|||||||
Reference in New Issue
Block a user