Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
Well done!
You have completed Dependency Management with Gradle!
You have completed Dependency Management with Gradle!
Preview
Let's add some dependencies to our build script and get them downloaded
Note
- In the latest versions of Gradle, the configuration keywords have been updated. Instead of using
compileandtestCompileas shown in the video, you should now useimplementationfor main dependencies andtestImplementationfor test dependencies.
dependencies {
implementation 'org.apache.commons:commons-csv:1.2'
testImplementation group: 'junit', name: 'junit', version: '4.11'
}
- The Gradle menu on the far right is now just an image of the elephant logo instead of the word "Gradle" as seen in the video.
Learn More
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign upRelated Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up
all those libraries that the dependency
we wanted to use depended on?
0:00
You know the transitive dependencies?
0:02
Well, ready for the good news?
0:05
This transitive dependency management
is all done for you through Gradle.
0:07
It even provides a cache
of each of its dependencies
0:11
in case they're shared across libraries.
0:15
And they usually do share dependency.
0:17
This means, that it won't go and download
a version that it already has, but
0:19
where is it downloading from you ask.
0:24
Good question.
0:26
This is under control by
the build script author.
0:27
You need to sign up for Treehouse in order to download course files.
Sign upYou need to sign up for Treehouse in order to set up Workspace
Sign up