forked from qt-creator/qt-creator
Fix terminal command on macOS
After 4c88c1808c the terminal command
itself may no longer have quoted spaces (since it is directly passed to
QProcess as the program name).
Change-Id: Iee4b9a6c3a87c29cb29cc732f6027f1c742f9eb5
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
@@ -350,9 +350,10 @@ TerminalCommand ConsoleProcess::defaultTerminalEmulator()
|
||||
if (defaultTerm.command.isEmpty()) {
|
||||
defaultTerm = []() -> TerminalCommand {
|
||||
if (HostOsInfo::isMacHost()) {
|
||||
QString termCmd = QCoreApplication::applicationDirPath() + "/../Resources/scripts/openTerminal.command";
|
||||
const QString termCmd = QCoreApplication::applicationDirPath()
|
||||
+ "/../Resources/scripts/openTerminal.command";
|
||||
if (QFileInfo::exists(termCmd))
|
||||
return {termCmd.replace(' ', "\\ "), "", ""};
|
||||
return {termCmd, "", ""};
|
||||
return {"/usr/X11/bin/xterm", "", "-e"};
|
||||
}
|
||||
const Environment env = Environment::systemEnvironment();
|
||||
|
||||
Reference in New Issue
Block a user