#!/bin/bash #wget http://archive.apache.org/dist/ant/ant-current-bin.zip ls -slh ant-current-bin.zip sleep 5 if [ -e ant-current-bin.zip ] then unzip ant-current-bin.zip -d /usr/local/ else echo "this ant-current-bin.zip don't exist" fi cd /usr/local/ mv apache-ant-1.7.1/ ant sed -i '/export PATH/i ANT_HOME=/usr/local/ant; export ANT_HOME' /etc/profile sed -i '/export PATH/i PATH=$PATH:$ANT_HOME/bin' /etc/profile source /etc/profile ant -version
ant_autoz-install
最新推荐文章于 2025-06-03 18:24:41 发布
本文介绍如何通过wget下载Apache Ant的当前版本,并使用bash脚本进行解压及安装到指定目录。此外还详细说明了如何修改系统的环境变量以确保Ant可以在任何位置被调用。
1121

被折叠的 条评论
为什么被折叠?



