diff --git a/.ci/travis.sh b/.ci/travis.sh index d9d91e885..bff111d15 100755 --- a/.ci/travis.sh +++ b/.ci/travis.sh @@ -48,7 +48,7 @@ if echo "$TRAVIS_SCALA_VERSION" | grep -q "^2\.10"; then SBT_COMMANDS="$SBT_COMMANDS plugin/scripted" fi -SBT_COMMANDS="$SBT_COMMANDS coreJVM/mimaReportBinaryIssues cache/mimaReportBinaryIssues" +SBT_COMMANDS="$SBT_COMMANDS tut coreJVM/mimaReportBinaryIssues cache/mimaReportBinaryIssues" if isNotPr && publish && isMaster; then SBT_COMMANDS="$SBT_COMMANDS publish" diff --git a/README.md b/README.md index 4a4b257ed..45fdebcac 100644 --- a/README.md +++ b/README.md @@ -447,7 +447,7 @@ scala> val repositories = Seq( | Cache.ivy2Local, | MavenRepository("https://repo1.maven.org/maven2") | ) -repositories: Seq[coursier.core.Repository] = List(IvyRepository(file://${user.home}/.ivy2/local/[organisation]/[module]/(scala_[scalaVersion]/)(sbt_[sbtVersion]/)[revision]/[type]s/[artifact](-[classifier]).[ext],None,None,Map(),true,true,true,true,None), MavenRepository(https://repo1.maven.org/maven2,None,false,None)) +repositories: Seq[coursier.core.Repository] = List(IvyRepository(Pattern(List(Const(file://), Var(user.home), Const(/local/), Var(organisation), Const(/), Var(module), Const(/), Opt(WrappedArray(Const(scala_), Var(scalaVersion), Const(/))), Opt(WrappedArray(Const(sbt_), Var(sbtVersion), Const(/))), Var(revision), Const(/), Var(type), Const(s/), Var(artifact), Opt(WrappedArray(Const(-), Var(classifier))), Const(.), Var(ext))),None,None,true,true,true,true,None), MavenRepository(https://repo1.maven.org/maven2,None,false,None)) ``` The first one, `Cache.ivy2Local`, is defined in `coursier.Cache`, itself from the `coursier-cache` module that we added above. As we can see, it is an `IvyRepository`, picking things under `~/.ivy2/local`. An `IvyRepository` diff --git a/doc/README.md b/doc/README.md index 299128ef6..273910e87 100644 --- a/doc/README.md +++ b/doc/README.md @@ -135,8 +135,13 @@ object Cache { // but it would then have required properties, which would have cluttered // output here. - val ivy2Local = coursier.Cache.ivy2Local.copy( - pattern = coursier.Cache.ivy2Local.pattern.replace("file:" + sys.props("user.home"), "file://${user.home}") + import coursier.ivy.Pattern.Chunk, Chunk._ + + val ivy2Local = coursier.ivy.IvyRepository.fromPattern( + coursier.ivy.Pattern( + Seq[Chunk]("file://", Var("user.home"), "/local/") ++ coursier.ivy.Pattern.default.chunks + ), + dropInfoAttributes = true ) def fetch() = coursier.Cache.fetch()