diff options
Diffstat (limited to 'sh')
| -rwxr-xr-x | sh/ccp | 14 | 
1 files changed, 12 insertions, 2 deletions
| @@ -32,14 +32,24 @@ for commit in $(git rev-list --reverse "$picked..HEAD"); do  		branch_pick="$all_branch_no_master"  	fi  	for branch in $branch_pick; do -		git checkout "$branch" +		# Mostly due to cherry-pick error. It seems if cherry-pick passed, +		# checkout will work. It is easier to check checkout error here and do +		# a while loop here to make sure cherry-pick works, instead of check +		# cherry-pick error. +		while ! git checkout "$branch"; do +			echo 'checkout error, fix and enter to continue' +			read a +		done  		git cherry-pick "$commit"  		git status  	done  done  cp "$XDG_DATA_HOME/mydata/cfgl_cherry_picked" "$XDG_DATA_HOME/mydata/cfgl_cherry_picked.bak" -git checkout master +while ! git checkout master; do +	echo 'checkout error, fix and enter to continue' +	read a +done  git rev-parse HEAD > "$XDG_DATA_HOME/mydata/cfgl_cherry_picked"  for branch in $all_branch_no_master; do | 
