Author: rob.stryker(a)jboss.com
Date: 2012-05-24 05:24:41 -0400 (Thu, 24 May 2012)
New Revision: 41343
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/ExpressMessages.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/ExpressPublishMethod.java
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/expressMessages.properties
Log:
JBIDE-11850
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/ExpressMessages.java
===================================================================
---
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/ExpressMessages.java 2012-05-24
09:16:21 UTC (rev 41342)
+++
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/ExpressMessages.java 2012-05-24
09:24:41 UTC (rev 41343)
@@ -18,5 +18,5 @@
public static String shareProjectMessage;
public static String additionNotRequiredModule;
public static String publishFailMissingProject;
-
+ public static String publishFailMissingFolder;
}
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/ExpressPublishMethod.java
===================================================================
---
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/ExpressPublishMethod.java 2012-05-24
09:16:21 UTC (rev 41342)
+++
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/ExpressPublishMethod.java 2012-05-24
09:24:41 UTC (rev 41343)
@@ -62,6 +62,14 @@
OpenShiftUIActivator.PLUGIN_ID,
NLS.bind(ExpressMessages.publishFailMissingProject, behaviour.getServer().getName(),
destProjName)));
}
+
+ String destinationFolder =
ExpressServerUtils.getExpressDeployFolder(behaviour.getServer());
+ IContainer destFolder = "".equals(destinationFolder) ? magicProject :
(IContainer)magicProject.findMember(new Path(destinationFolder));
+ if( destFolder == null || !destFolder.isAccessible()) {
+ throw new CoreException(new Status(IStatus.ERROR,
+ OpenShiftUIActivator.PLUGIN_ID,
+ NLS.bind(ExpressMessages.publishFailMissingFolder, behaviour.getServer().getName(),
destFolder.getProjectRelativePath())));
+ }
}
@Override
Modified:
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/expressMessages.properties
===================================================================
---
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/expressMessages.properties 2012-05-24
09:16:21 UTC (rev 41342)
+++
trunk/openshift/plugins/org.jboss.tools.openshift.express.ui/src/org/jboss/tools/openshift/express/internal/core/behaviour/expressMessages.properties 2012-05-24
09:24:41 UTC (rev 41343)
@@ -6,4 +6,5 @@
additionNotRequiredModule=This server requires the {0} application.
shareProjectTitle=Share projects?
shareProjectMessage="There are {0} projects that are not connected to any git
repository. Would you like to share them now?
-publishFailMissingProject=Server {0} cannot publish. Required project "{1}" is
missing or inaccessible.
\ No newline at end of file
+publishFailMissingProject=Server {0} cannot publish. Required project "{1}" is
missing or inaccessible.
+publishFailMissingFolder=Server {0} cannot publish. Required folder "{1}" is
missing or inaccessible.
Show replies by date