From de24023dd1ca9bf63d37adaec2d5f11a31d67f49 Mon Sep 17 00:00:00 2001 From: Tracey Yoshima Date: Fri, 28 May 2021 12:09:31 -0700 Subject: [PATCH] Updated instantiation of RocksdbMavenPomCache. (#176) Bumped rewrite version to 7.7.0-SNAPSHOT. --- pom.xml | 2 +- .../java/org/openrewrite/maven/AbstractRewriteMojo.java | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pom.xml b/pom.xml index 566a51e0..eb604f26 100644 --- a/pom.xml +++ b/pom.xml @@ -40,7 +40,7 @@ - 7.6.0 + 7.7.0-SNAPSHOT scm:git:ssh://git@github.com/openrewrite/rewrite-maven-plugin.git diff --git a/src/main/java/org/openrewrite/maven/AbstractRewriteMojo.java b/src/main/java/org/openrewrite/maven/AbstractRewriteMojo.java index 3aeac504..f26a30ac 100644 --- a/src/main/java/org/openrewrite/maven/AbstractRewriteMojo.java +++ b/src/main/java/org/openrewrite/maven/AbstractRewriteMojo.java @@ -151,11 +151,11 @@ protected Maven parseMaven(Path baseDir, ExecutionContext ctx) { if (pomCacheEnabled) { try { if (pomCacheDirectory == null) { - //Default directory is "~/.rewrite/cache/pom" - mavenParserBuilder.cache(new RocksdbMavenPomCache(Paths.get(System.getProperty("user.home"), ".rewrite", "cache", "pom").toFile())); + //Default directory in the RocksdbMavenPomCache is ".rewrite-cache" + mavenParserBuilder.cache(new RocksdbMavenPomCache(Paths.get("."))); } else { - mavenParserBuilder.cache(new RocksdbMavenPomCache(Paths.get(pomCacheDirectory).toFile())); + mavenParserBuilder.cache(new RocksdbMavenPomCache(Paths.get(pomCacheDirectory))); } } catch (Exception e) { getLog().warn("Unable to initialize RocksdbMavenPomCache, falling back to InMemoryMavenPomCache");