How to create a simple Java project with Maven 3?

0 comments
Managing your project with Maven gives you a lot of advantages. You can automatically compile, pack into JAR or run tests on your project. You can also manage your project dependencies with almost no effort. To create JAR project I will use a powerful Maven capability called archetypes. Maven gives you a possibility to predefine your project template (archetype in Maven terminology), so that for different projects you can use different archetypes. Maven also comes with predefined archetypes for creating different projects like simple JAR or J2EE project.

How to set up proxy for Maven ?

0 comments
When I started using Apache Maven in my company I realized that, because of proxy settings, I couldn't download dependencies from the Internet. Dependencies are really powerful features of Maven, so it would be unreasonable not to use them. I found a solution to set up proxy so that Maven requests could go out my company's network.

I had to perform a few steps in order to set up proxy for Maven:
  1. I had to find Apache Maven settings.xml file.
  2. I had to modify my proxy settings.

How to install Maven on Mac OS X ?

2 comments
There are many ways to install Apache Maven on Mac OS X. You can use Homebrew, MacPorts or just download it and set up manually. For the sake of this tutorial I will use Apache Maven 3.0.5 and JDK version 1.7.0_25, I'm using Mountain Lion.

There are a few steps which you need to perform:
  1. Check your JDK installation. If you don't have JDK, you will need to install one (1.5 or above).
  2. Install Apache Maven 3.0.5.
  3. Test your installation.