@matheusbsbs / matheus-bagliano / commits / f89ad67fb0
Fork 0

Add [v]iew patch in git-am interactive.

Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Oct 25, 2005 at 23:43 UTC f89ad67fb054bead054bc92b4d0d4d007248b611
1 file changed +8 -5
git-am.sh
+8 -5
@@ -270,14 +270,17 @@ do
270 echo "--------------------------"
271 cat "$dotest/final-commit"
272 echo "--------------------------"
273 - echo -n "Apply? [y]es/[n]o/[e]dit/[a]ccept all "
273 + echo -n "Apply? [y]es/[n]o/[e]dit/[v]iew patch/[a]ccept all "
274 read reply
275 case "$reply" in
276 - y*|Y*) action=yes ;;
277 - a*|A*) action=yes interactive= ;;
278 - n*|N*) action=skip ;;
279 - e*|E*) "${VISUAL:-${EDITOR:-vi}}" "$dotest/final-commit"
276 + [yY]*) action=yes ;;
277 + [aA]*) action=yes interactive= ;;
278 + [nN]*) action=skip ;;
279 + [eE]*) "${VISUAL:-${EDITOR:-vi}}" "$dotest/final-commit"
280 action=again ;;
281 + [vV]*) action=again
282 + LESS=-S ${PAGER:-less} "$dotest/patch" ;;
283 + *) action=again ;;
284 esac
285 done
286 else