些脚本的时,注意事项

来源:互联网 发布:开发程序员 编辑:程序博客网 时间:2024/06/05 19:33

1.首先要source ~/.bashrc

2.注意环境变量

#!/bin/bashsource /home/mazi/.bashrcPath="/home/mazi/source/$1/F3"repoPath="/home/mazi/bin/repo"cd "$Path"$repoPath forall -c 'git checkout -f;git clean -fd'$repoPath forall -c 'git checkout dev'$repoPath sync -j24for gTag in `git tag | grep G6_F| grep OFF_2013` do    if [ "${gTag}" \> "${lastTag}" ]; then        lastTag=${gTag}                                                                                                                          fi  doneecho $lastTag > xxx $repoPath forall -c "git branch -D $lastTag"$repoPath forall -c "git checkout -b $lastTag $lastTag"$Path/cu.sh restore$Path/cu.sh G6echo `pwd` >> xxx $Path/build.sh G6 androidu &


原创粉丝点击