3 # DP: Use sensible-editor instead of vi as fallback editor
5 # Taken from gcc-4.1-source. Chokes bash -n (due to the patch) despite being
6 # a valid dpatch, so don't warn about it if it's in /usr/src.
9 if [ $# -eq 3 -a "$2" = '-d' ]; then
12 elif [ $# -ne 1 ]; then
13 echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
18 patch $pdir -f --no-backup-if-mismatch -p0 < $0
21 patch $pdir -f --no-backup-if-mismatch -R -p0 < $0
24 echo >&2 "`basename $0`: script expects -patch|-unpatch as argument"
29 --- gcc/gccbug.in~ 2003-03-01 00:51:42.000000000 +0100
30 +++ gcc/gccbug.in 2003-03-02 12:08:36.000000000 +0100
32 # If they don't have a preferred editor set, then use
33 if [ -z "$VISUAL" ]; then
34 if [ -z "$EDITOR" ]; then
36 + EDIT=/usr/bin/sensible-editor