X-Git-Url: http://git.argeo.org/?a=blobdiff_plain;ds=sidebyside;f=org.argeo.slc.agent%2Fsrc%2Fmain%2Fjava%2Forg%2Fargeo%2Fslc%2Fant%2FSlcAntConfig.java;fp=org.argeo.slc.agent%2Fsrc%2Fmain%2Fjava%2Forg%2Fargeo%2Fslc%2Fant%2FSlcAntConfig.java;h=61b78cc7cd4207a7b7c41e4559a22bf1de5ce827;hb=0bc20690292697d0c7950ccd8c3e1e0887d8b88a;hp=d92a5f8920ceab76be1d70c7976ab146a8eed18b;hpb=c8f58c644eb4d9b28c4e86beda00d6c0bfe1ba3d;p=gpl%2Fargeo-slc.git diff --git a/org.argeo.slc.agent/src/main/java/org/argeo/slc/ant/SlcAntConfig.java b/org.argeo.slc.agent/src/main/java/org/argeo/slc/ant/SlcAntConfig.java index d92a5f892..61b78cc7c 100644 --- a/org.argeo.slc.agent/src/main/java/org/argeo/slc/ant/SlcAntConfig.java +++ b/org.argeo.slc.agent/src/main/java/org/argeo/slc/ant/SlcAntConfig.java @@ -108,12 +108,6 @@ public class SlcAntConfig { // SLC ROOT PROPERTIES /** Property for the root file (SLC root property file). */ public final static String ROOT_FILE_PROPERTY = "slc.rootFile"; - /** Property for the root dir (SLC root property file). */ - public final static String ROOT_DIR_PROPERTY = "slc.rootDir"; - /** Property for the conf dir (SLC root property file). */ - public final static String CONF_DIR_PROPERTY = "slc.confDir"; - /** Property for the work dir (SLC root property file). */ - public final static String WORK_DIR_PROPERTY = "slc.workDir"; /** * Comma-separated list of property file names to load from the conf dir and * add to project user properties @@ -194,30 +188,30 @@ public class SlcAntConfig { final File workDir; // Root dir final File rootDir = slcRootFile.getParentFile(); - all.setProperty(ROOT_DIR_PROPERTY, fileUrlPrefix + all.setProperty(SlcAntConstants.ROOT_DIR_PROPERTY, fileUrlPrefix + rootDir.getCanonicalPath()); // Conf dir - if (all.getProperty(CONF_DIR_PROPERTY) == null) { - confDir = new File(rootProps.getProperty(CONF_DIR_PROPERTY, + if (all.getProperty(SlcAntConstants.CONF_DIR_PROPERTY) == null) { + confDir = new File(rootProps.getProperty(SlcAntConstants.CONF_DIR_PROPERTY, rootDir.getAbsolutePath() + "/../conf")) .getCanonicalFile(); - all.setProperty(CONF_DIR_PROPERTY, fileUrlPrefix + all.setProperty(SlcAntConstants.CONF_DIR_PROPERTY, fileUrlPrefix + confDir.getAbsolutePath()); } else { - confDir = new File(all.getProperty(CONF_DIR_PROPERTY)) + confDir = new File(all.getProperty(SlcAntConstants.CONF_DIR_PROPERTY)) .getCanonicalFile(); } // Work dir - if (all.getProperty(WORK_DIR_PROPERTY) == null) { - workDir = new File(rootProps.getProperty(WORK_DIR_PROPERTY, + if (all.getProperty(SlcAntConstants.WORK_DIR_PROPERTY) == null) { + workDir = new File(rootProps.getProperty(SlcAntConstants.WORK_DIR_PROPERTY, rootDir.getAbsolutePath() + "/../work")) .getCanonicalFile(); - all.setProperty(WORK_DIR_PROPERTY, fileUrlPrefix + all.setProperty(SlcAntConstants.WORK_DIR_PROPERTY, fileUrlPrefix + workDir.getAbsolutePath()); } else { - workDir = new File(all.getProperty(WORK_DIR_PROPERTY)) + workDir = new File(all.getProperty(SlcAntConstants.WORK_DIR_PROPERTY)) .getCanonicalFile(); }