This is bugging me as well, and I've figured out the root cause.  The maven2 
package runs update-alternatives with a priority of 200, and maven (3) with a 
priority of 150.  If you install maven2 and maven at the same time, you will 
always get maven2.  Since maven2 is a dependency for maven-debian-helper this 
will nearly always be the case.

# apt-get install –y maven maven2
# mvn -v
Apache Maven 2.2.1 (rdebian-15)
Java version: 1.7.0_65
Java home: /usr/lib/jvm/java-7-openjdk-amd64/jre
Default locale: en_US, platform encoding: ANSI_X3.4-1968
OS name: "linux" version: "3.15.3-tinycore64" arch: "amd64" Family: "unix"
# update-alternatives --config mvn
There are 2 choices for the alternative mvn (providing /usr/bin/mvn).

  Selection    Path                       Priority   Status
* 0            /usr/share/maven2/bin/mvn   200       auto mode
  1            /usr/share/maven/bin/mvn    150       manual mode
  2            /usr/share/maven2/bin/mvn   200       manual mode

A more sensible default might be setting the priority of maven (3) to 250 so it 
becomes the default, but this may have some unexpected side effects.

Tim Potter
Cloud Systems Engineer
HP Cloud Services
M +61 419 749 832
Hewlett-Packard Australia Pty Ltd

This e-mail may contain confidential and privileged material for the sole use 
of the intended recipient. Any review, use, distribution or disclosure by 
others is strictly prohibited. If you are not the intended recipient (or 
authorised to receive for the recipient), please contact the sender by reply 
e-mail and delete all copies of this message.

This is the maintainer address of Debian's Java team
Please use for discussions and questions.

Reply via email to