This repository contains a series of exercises that should build a basic understanding of how Java libraries are distributed, how archives such as JARs were distributed prior to Maven, how Maven improves on that process, and how to use Maven.
Download the repository with exercises:
git clone https://github.com/imc-trading/devschool-maven-exercise.git
You'll need to have Maven 3.5+ and Java 11+ higher to run the exercises.
On a Mac, if you have Homebrew installed, then you can install Maven with
brew install maven
This will install Java (openjdk
) as a dependency.
sudo apt-get install maven
This will install Java (openjdk
) as a dependency.
If you have Docker, you can run the exercises within a Docker image for a consistent environment:
docker run -it \
--mount type=bind,source=$(pwd),target=/usr/src/maven-training \
-w /usr/src/maven-training \
maven:latest \
/bin/bash -l
In other environments, it is up to you to install these dependencies. Here is one tutorial that provides some instructions.
This exercise is broken up into two labs, with multiple exercises in each section.
For each exercise, you don't need to write any code, or modify any pom.xml
files. Just run the commands and observe
what they do.
How Java libraries are compiled and packaged, without Maven.
Start here.
Introduction to using Maven to make everything easier.
Start here.