Windows support
[lgpl/argeo-commons.git] / org.argeo.osgi.boot / src / org / argeo / osgi / boot / OsgiBoot.java
index b400bf43ad5172318fe3edf733508ab8b0f17d5b..effdcf3baf3bc7daf3e46d0692855a667e93001a 100644 (file)
@@ -19,6 +19,7 @@ import static org.argeo.osgi.boot.OsgiBootUtils.debug;
 import static org.argeo.osgi.boot.OsgiBootUtils.warn;
 
 import java.io.File;
+import java.nio.file.Paths;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.Iterator;
@@ -95,8 +96,8 @@ public class OsgiBoot implements OsgiBootConstants {
        /** Constructor */
        public OsgiBoot(BundleContext bundleContext) {
                this.bundleContext = bundleContext;
-               localCache = getProperty(PROP_ARGEO_OSGI_LOCAL_CACHE,
-                               "file://" + System.getProperty("user.home") + "/.m2/repository/");
+               String homeUri = Paths.get(System.getProperty("user.home")).toUri().toString();
+               localCache = getProperty(PROP_ARGEO_OSGI_LOCAL_CACHE, homeUri + ".m2/repository/");
        }
 
        /*