forked from qt-creator/qt-creator
ProjectExplorer: Add executable() accessor to RunConfiguration
Amends f6c276daf0, which was a quick fix for 4.9.
Change-Id: I94281af6a9a0d0bfe197ce836488f708d5bd677d
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -279,6 +279,9 @@ PythonRunConfiguration::PythonRunConfiguration(Target *target, Core::Id id)
|
||||
addAspect<TerminalAspect>();
|
||||
|
||||
setOutputFormatter<PythonOutputFormatter>();
|
||||
setExecutableGetter([this] {
|
||||
return FileName::fromString(aspect<InterpreterAspect>()->value());
|
||||
});
|
||||
|
||||
connect(target, &Target::applicationTargetsChanged,
|
||||
this, &PythonRunConfiguration::updateTargetInformation);
|
||||
@@ -300,7 +303,7 @@ Runnable PythonRunConfiguration::runnable() const
|
||||
QtcProcess::addArg(&r.commandLineArguments, mainScript());
|
||||
QtcProcess::addArgs(&r.commandLineArguments,
|
||||
aspect<ArgumentsAspect>()->arguments(macroExpander()));
|
||||
r.executable = aspect<InterpreterAspect>()->value();
|
||||
r.executable = executable().toString();
|
||||
r.environment = aspect<EnvironmentAspect>()->environment();
|
||||
return r;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user