使用简单、方便更新,不过要安装有git。
git clone git://github.com/oldratlee/useful-scripts.git
cd useful-scripts
# 使用Release分支的内容
git checkout release-2.x
# 更新脚本
git pull包含2个分支:
dev-2.x:开发分支release-2.x:发布分支,功能稳定的脚本
当然如果你不想安装git,github是支持svn的:
svn co https://github.com/oldratlee/useful-scripts/branches/release-2.x
cd useful-scripts
# 更新脚本
svn upPS:
我的做法是把useful-scripts checkout到$HOME/bin目录下,再把$HOME/bin/useful-scripts/bin配置到PATH变量上,这样方便我本地使用所有的脚本。
下载文件release-2.x.zip:
wget --no-check-certificate https://github.com/oldratlee/useful-scripts/archive/release-2.x.zip
unzip release-2.x.zipcurl -sLk 'https://raw.github.com/oldratlee/useful-scripts/release-2.x/bin/show-busy-java-threads' | bashwget --no-check-certificate https://raw.github.com/oldratlee/useful-scripts/release-2.x/bin/show-busy-java-threads
chmod +x show-busy-java-threads
./show-busy-java-threads