From 7c1844beba08bfe55e5efc3592b78ff67535aa8c Mon Sep 17 00:00:00 2001 From: 8ga Date: Fri, 10 Jan 2025 15:48:39 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20java-mvn-home.sh?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- java-mvn-home.sh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/java-mvn-home.sh b/java-mvn-home.sh index 4287ca8..9f4afc3 100644 --- a/java-mvn-home.sh +++ b/java-mvn-home.sh @@ -1 +1,7 @@ -# \ No newline at end of file +#!/bin/bash +echo 'export JAVA_HOME=/usr/local/jdk1.8.0_202' >> /etc/profile +echo 'export MAVEN_HOME=/usr/local/apache-maven-3.9.6' >> /etc/profile +echo 'export PATH=${PATH}:${JAVA_HOME}/bin:${MAVEN_HOME}/bin' >> /etc/profile +source /etc/profile +java -version +mvn -v \ No newline at end of file