新增dii、ghd、cvs工具;更新README.md文件

This commit is contained in:
2023-12-12 16:04:04 +08:00
committed by huty
parent 21df4c9750
commit 7f760dd608
4 changed files with 385 additions and 2 deletions

38
ghd Executable file
View File

@@ -0,0 +1,38 @@
#!/bin/bash
# 加速下载 GitHub 文件
# 相关参数
## 版本号
VERSION=0.2.0
# 相关方法
## 帮助
help () {
echo 'Usage: ghd GitHub文件URL支持 github.com 和 raw.githubusercontent.com '
echo '示例:'
echo ' ghd https://github.com/docker/compose/releases/download/v2.19.1/docker-compose-linux-x86_64'
}
## 版本号
version () {
echo 'dii '$VERSION
}
## 下载文件
download () {
echo '------------------------------ 正在通过 GitHub Proxy https://ghproxy.com 下载 GitHub 文件,请稍后... ------------------------------'
curl -O https://mirror.ghproxy.com/$1
}
# 执行方法
case $1 in
help)
help
;;
version)
version
;;
*)
curl -O https://mirror.ghproxy.com/$1
# download()
;;
esac