RunConfigurationAspect: Re-enable macro substitution

Re-enable macro substitution in work directory of run configurations.

This makes it possible to do %{sourceDir} or %{buildDir} again.

Task-number: QTCREATORBUG-16338
Change-Id: Ifff7831bf3aa0078d13185da5f5e7c6a3be2f852
Reviewed-by: hjk <hjk@theqtcompany.com>
This commit is contained in:
Tobias Hunger
2016-06-24 11:44:34 +02:00
parent ab30724b00
commit 9db6897e55

View File

@@ -215,16 +215,12 @@ void WorkingDirectoryAspect::toMap(QVariantMap &data) const
FileName WorkingDirectoryAspect::workingDirectory() const
{
if (m_chooser) {
return m_chooser->fileName();
} else {
auto envAspect = runConfiguration()->extraAspect<EnvironmentAspect>();
const Utils::Environment env = envAspect ? envAspect->environment()
: Utils::Environment::systemEnvironment();
return FileName::fromString(
runConfiguration()->macroExpander()->expandProcessArgs(
PathChooser::expandedDirectory(m_workingDirectory.toString(), env, QString())));
}
}
FileName WorkingDirectoryAspect::defaultWorkingDirectory() const