我正在使用ubuntu,我有一个文件夹gitrepos,它有许多来自github的多个git repos克隆.
我想要一个脚本,可以在我的所有回购中自动执行git pull.
说
[gitrepos]
[repo1]
[repo2]
[repo3]
...
Run Code Online (Sandbox Code Playgroud)
我想要一个脚本从所有repox
注释git pull 回购名称是不同的.
任何shell或py脚本可用于此?
log*_*yth 15
这行可行:
来自〜/ gitrepos:
for REPO in `ls`; do (cd "$REPO"; git pull); done;
Run Code Online (Sandbox Code Playgroud)
从任何地方:
for REPO in "`find ~/gitrepos -maxdepth 0 -type d`"; do (cd "$REPO"; git pull); done;
Run Code Online (Sandbox Code Playgroud)