Java environment Variables and ant/maven environment variable settings

Source: Internet
Author: User

Java environment Variables and ant/maven environment variable settings

1. Java Environment variables

The Windows environment is configured as:
CLASSPATH
.; %java_home%\lib\dt.jar;%java_home%\lib\tools.jar;
Java_home
C:\Program files\java\jdk1.6.0_45
Append to Path:
%java_home%\jre\bin;%java_home%\bin;

The Linux environment is configured as:
Under the Ubuntu14.04 version system, set to:
Export java_home=/usr/local/java/jdk1.6.0_45
Export Path= $JAVA _home/bin
Export classpath=.: $JAVA _home/lib/dt.jar: $JAVA _home/lib/tools.jar

2. Ant/maven Environment variables

The Windows environment is configured as:
Ant_home
D:\apache-ant-1.9.3
Append to Path:
%ant_home%\bin;
M2_home
D:\apache-maven-3.1.1
Append to Path:
%m2_home%\bin;

The Linux environment is configured as:
Configured under the Ubuntu14.04 version system to:
Export ant_home=/usr/local/apache-ant-1.9.3
Export m2_home=/usr/local/apache-maven-3.1.1
Export path= $JAVA _home/bin: $PATH: $ANT _home/bin: $M 2_home/bin

The path configuration paths that you see under windows are:
%java_home%\jre\bin;%java_home%\bin;%ant_home%\bin;%m2_home%\bin

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.