Sunday, 31 July 2022

How to find the maven installed location in my system?

Approach 1: Execute the command ‘mvn -version’ to find out the location, where Maven is installed in your system.

$mvn -version
Apache Maven 3.8.4 (9b656c72d54e5bacbed989b64718c159fe39b537)
Maven home: /Users/krishna/Documents/softwares/apache-maven-3.8.4
Java version: 1.8.0_311, vendor: Oracle Corporation, runtime: /Library/Java/JavaVirtualMachines/jdk1.8.0_311.jdk/Contents/Home/jre
Default locale: en_GB, platform encoding: UTF-8
OS name: "mac os x", version: "10.16", arch: "x86_64", family: "mac"

 

Property ‘Maven home:’ points to the maven location in your system.

 

Approach 2: If you add the maven bin directory path to your system path, then execute the command ‘which mvn’, it gives you the location of maven bin directory path. This command works in Linux and Mac systems.

$which mvn
/Users/krishna/Documents/softwares/apache-maven-3.8.4/bin/mvn

 

 

Previous                                                 Next                                                 Home

No comments:

Post a Comment