PythonEditor: Use Utils::CommandLine when creating a runnable

Change-Id: I670390f6034923d1f7f750435c0c8eb02d60b6f6
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
hjk
2019-06-04 11:05:32 +02:00
parent e6bda58033
commit 7d02a76be1

View File

@@ -299,11 +299,12 @@ void PythonRunConfiguration::updateTargetInformation()
Runnable PythonRunConfiguration::runnable() const
{
CommandLine cmd{executable(), {}};
cmd.addArg(mainScript());
cmd.addArgs(aspect<ArgumentsAspect>()->arguments(macroExpander()));
Runnable r;
QtcProcess::addArg(&r.commandLineArguments, mainScript());
QtcProcess::addArgs(&r.commandLineArguments,
aspect<ArgumentsAspect>()->arguments(macroExpander()));
r.executable = executable().toString();
r.setCommandLine(cmd);
r.environment = aspect<EnvironmentAspect>()->environment();
return r;
}