File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11#! /bin/bash
22
3- master_only =1
3+ main_only =1
44folder=" "
55if [ ! -z $1 ]; then
66 cd $1
3535 fi
3636
3737 for branch in ${branches[@]} ; do
38- master =" origin/master "
39- if [ $branch == $master ]; then
38+ main =" origin/main "
39+ if [ $branch == $main ]; then
4040 continue
4141 fi
42- if [ $master_only == 1 ]; then
43- if [ $branch != " master " ]; then
42+ if [ $main_only == 1 ]; then
43+ if [ $branch != " main " ]; then
4444 continue
4545 fi
4646 fi
47- git rev-list --left-right ${branch} ...${master } -- 2> /dev/null > ${temp_file} || continue
47+ git rev-list --left-right ${branch} ...${main } -- 2> /dev/null > ${temp_file} || continue
4848 LEFT_AHEAD=$( grep -c ' ^<' ${temp_file} )
4949 RIGHT_AHEAD=$( grep -c ' ^>' ${temp_file} )
50- printf " %s (ahead %s) | (behind %s) %s %-16s%s\n" $branch $LEFT_AHEAD $RIGHT_AHEAD $master $folder $mods
50+ printf " %s (ahead %s) | (behind %s) %s %-16s%s\n" $branch $LEFT_AHEAD $RIGHT_AHEAD $main $folder $mods
5151 done
5252done
You can’t perform that action at this time.
0 commit comments