Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/Publisher.java13
1 files changed, 10 insertions, 3 deletions
diff --git a/bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/Publisher.java b/bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/Publisher.java
index 49eeb0cab..76df6080f 100644
--- a/bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/Publisher.java
+++ b/bundles/org.eclipse.equinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/Publisher.java
@@ -229,7 +229,7 @@ public class Publisher {
IStatus finalStatus = null;
if (info.getArtifactRepository() != null) {
finalStatus = info.getArtifactRepository().executeBatch(artifactProcess, sub);
- if (finalStatus.isOK())
+ if (!finalStatus.matches(IStatus.ERROR | IStatus.CANCEL))
// If the batch process didn't report any errors, then
// Use the status from our actions
finalStatus = artifactProcess.getStatus();
@@ -240,17 +240,24 @@ public class Publisher {
if (Tracing.DEBUG_PUBLISHING)
Tracing.debug("Publishing complete. Result=" + finalStatus); //$NON-NLS-1$
+
+ // if there were no errors, publish all the ius.
+ if (finalStatus.isOK() || finalStatus.matches(IStatus.INFO | IStatus.WARNING))
+ savePublishedIUs();
+
if (!finalStatus.isOK())
return finalStatus;
+ return Status.OK_STATUS;
} finally {
sub.done();
}
- // if there were no errors, publish all the ius.
+ }
+
+ protected void savePublishedIUs() {
IMetadataRepository metadataRepository = info.getMetadataRepository();
if (metadataRepository != null) {
Collection<IInstallableUnit> ius = results.getIUs(null, null);
metadataRepository.addInstallableUnits(ius);
}
- return Status.OK_STATUS;
}
}

Back to the top