1
0
镜像自地址 https://github.com/tuna/tunasync.git 已同步 2025-12-06 06:26:46 +00:00
文件
tunasync/scripts/homebrew.sh
2015-05-19 20:15:07 +08:00

18 行
481 B
Bash
可执行文件

#!/bin/bash
if [ ! -d "$TUNASYNC_WORKING_DIR" ]; then
echo "Directory not exists, fail"
exit 1
fi
function update_homebrew_git() {
repo_dir="$1"
cd $repo_dir
echo "==== SYNC $repo_dir START ===="
/usr/bin/timeout -s INT 3600 git remote -v update
echo "==== SYNC $repo_dir DONE ===="
}
update_homebrew_git "$TUNASYNC_WORKING_DIR/homebrew.git"
update_homebrew_git "$TUNASYNC_WORKING_DIR/homebrew-python.git"
update_homebrew_git "$TUNASYNC_WORKING_DIR/homebrew-science.git"