forked from qt-creator/qt-creator
QbsProjectManager: Add "clean" and "rebuild" actions for products
... and sub-projects. We used to have only the "build" action for these. Task-number: QTCREATORBUG-15919 Change-Id: I31d06498c0cdadb8a8738be521a98e8b03de32ee Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
This commit is contained in:
@@ -87,6 +87,7 @@ bool QbsCleanStep::init(QList<const BuildStep *> &earlierSteps)
|
||||
if (!bc)
|
||||
return false;
|
||||
|
||||
m_products = bc->products();
|
||||
return true;
|
||||
}
|
||||
|
||||
@@ -97,9 +98,10 @@ void QbsCleanStep::run(QFutureInterface<bool> &fi)
|
||||
QbsProject *pro = static_cast<QbsProject *>(project());
|
||||
qbs::CleanOptions options(m_qbsCleanOptions);
|
||||
|
||||
m_job = pro->clean(options);
|
||||
|
||||
QString error;
|
||||
m_job = pro->clean(options, m_products, error);
|
||||
if (!m_job) {
|
||||
emit addOutput(error, OutputFormat::ErrorMessage);
|
||||
reportRunResult(*m_fi, false);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user