Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update tutorial's ivy resolver docs. #1228

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion docs/developers/tutorial.md
Original file line number Diff line number Diff line change
Expand Up @@ -754,10 +754,16 @@ custom repository like Bintray or a private Nexus.
scalafixResolvers.in(ThisBuild) ++= List(
coursierapi.MavenRepository.of("https://dl.bintray.com/scalacenter/releases"),
coursierapi.MavenRepository.of("https://oss.sonatype.org/content/repositories/snapshots"),
coursierapi.IvyRepository.of("https://dl.bintray.com/sbt/sbt-plugin-releases")
coursierapi.IvyRepository.of("https://dl.bintray.com/sbt/sbt-plugin-releases/[defaultPattern]"),
coursierapi.IvyRepository.of("https://foo.com/a/b/c/[defaultPattern]")
)
```

Notice for Ivy resolvers, `coursierapi.IvyRepository.of` is interpolated as a pattern. Appending `[defaultPattern]`
uses this [convenience method](https://github.com/coursier/coursier/blob/a92e4f263f494199078adfb1c5db67ba0b076674/modules/core/shared/src/main/scala/coursier/ivy/Pattern.scala#L107)
to substitute in [this default pattern](https://github.com/coursier/coursier/blob/a92e4f263f494199078adfb1c5db67ba0b076674/modules/core/shared/src/main/scala/coursier/ivy/Pattern.scala#L236-L245).
Tests showing a working example can found [here](https://github.com/coursier/coursier/blob/master/modules/tests/jvm/src/test/scala/coursier/test/IvyTests.scala).

### Conclusion

Don't be intimidated by publishing to Maven Central, it gets easier once you've
Expand Down