| 1 | #!/bin/sh |
| 2 | # -*- eval: (bug-reference-mode 1) -*- |
| 3 | |
| 4 | setlock -n /tmp/getmail.lock && echo getmail isn\'t running |
| 5 | |
| 6 | # adsgsdg |
| 7 | |
| 8 | if foo; then |
| 9 | if bar; then |
| 10 | toto |
| 11 | fi |
| 12 | fi # bug#15613 |
| 13 | |
| 14 | case $X in |
| 15 | foo) |
| 16 | do_something |
| 17 | ;; |
| 18 | arg=*) # bug#12953 |
| 19 | do_something_else_based_on_arg |
| 20 | ;; |
| 21 | *) |
| 22 | default |
| 23 | ;; |
| 24 | esac |
| 25 | |
| 26 | { # bug#17621 |
| 27 | foo1 && |
| 28 | foo2 && |
| 29 | bar |
| 30 | |
| 31 | foo1 && \ |
| 32 | foo2 && \ |
| 33 | bar |
| 34 | } |
| 35 | |
| 36 | for foo in bar; do # bug#17721 |
| 37 | [ -e $foo ] && { |
| 38 | echo t |
| 39 | } && { |
| 40 | echo r |
| 41 | } |
| 42 | done |
| 43 | |
| 44 | echo -n $(( 5 << 2 )) |
| 45 | # This should not be treated as a heredoc (bug#12770). |
| 46 | 2 |
| 47 | |
| 48 | foo='bar<<' # bug#11263 |
| 49 | echo ${foo%<<aa} # bug#11263 |
| 50 | echo $((1<<8)) # bug#11263 |
| 51 | echo $[1<<8] # bug#11263 |
| 52 | |
| 53 | declare -a VERSION |
| 54 | for i in $(ls "$PREFIX/sbin") ; do |
| 55 | echo -e $N')' $i |
| 56 | VERSION[${#VERSION[*]}]=$i # bug#11946. |
| 57 | N=$(($N + 1)) |
| 58 | done |
| 59 | |
| 60 | foo () { |
| 61 | |
| 62 | bar () { |
| 63 | blilbi |
| 64 | } |
| 65 | |
| 66 | case toto |
| 67 | in a) hello # KNOWN INDENT BUG |
| 68 | ;; b) hi # KNOWN INDENT BUG |
| 69 | ;; c) hi # KNOWN INDENT BUG |
| 70 | esac |
| 71 | |
| 72 | case $toto in |
| 73 | a) echo 1;; b) echo 2;; |
| 74 | (c) |
| 75 | echo 3;; |
| 76 | d) |
| 77 | echo 3;; |
| 78 | esac |
| 79 | |
| 80 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
| 81 | *${as_nl}ac_space=\ *) |
| 82 | # `set' does not quote correctly, so add quotes: double-quote |
| 83 | # substitution turns \\\\ into \\, and sed turns \\ into \. |
| 84 | sed -n \ |
| 85 | "s/'/'\\\\''/g; |
| 86 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=/\\1=''/p" |
| 87 | ;; #( |
| 88 | *) |
| 89 | # `set' quotes correctly as required by POSIX, so do not add |
| 90 | # quotes. |
| 91 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
| 92 | ;; |
| 93 | esac | |
| 94 | grep '.' | # KNOWN INDENT BUG |
| 95 | sed 1d |
| 96 | |
| 97 | case toto in |
| 98 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ |
| 99 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* \ |
| 100 | | --exec=* | --exe=* | --ex=*) |
| 101 | exec_prefix=$ac_optarg ;; |
| 102 | 5) |
| 103 | hello ;; |
| 104 | 3) hello $(adfad) |
| 105 | echo esac ;; # KNOWN INDENT BUG |
| 106 | 5) hello ;; |
| 107 | 4) hello ;& |
| 108 | 4) hello ;;& |
| 109 | 5) hello ;; |
| 110 | 5) hello ;; |
| 111 | esac |
| 112 | |
| 113 | echo "'" wfgfe |
| 114 | |
| 115 | #!/bin/bash |
| 116 | cat << EOF \ |
| 117 | | cat sadfsafd \ |
| 118 | sadfsafd "KNOWN INDENT BUG" \ |
| 119 | | tee -a bug.txt |
| 120 | asdfsaf |
| 121 | This is a test case for a bug in bash shell mode text highlighting |
| 122 | EOF |
| 123 | |
| 124 | cat <<EOF1 <<EOF2 # KNOWN INDENT BUG |
| 125 | help1 |
| 126 | EOF1 |
| 127 | help2 |
| 128 | EOF2 |
| 129 | } |
| 130 | bar () { |
| 131 | if [ $# == 0 ]; then |
| 132 | while |
| 133 | f # KNOWN INDENT BUG |
| 134 | do |
| 135 | bla; |
| 136 | done |
| 137 | echo "Highlighting is screwed up now" |
| 138 | if [ 1 = 1 ]; then |
| 139 | # adsgsdg |
| 140 | echo "screwed up" |
| 141 | fi |
| 142 | |
| 143 | $@ $? $# |
| 144 | |
| 145 | for f in * |
| 146 | do |
| 147 | sdfg |
| 148 | done |
| 149 | |
| 150 | if swrgfef |
| 151 | then blas |
| 152 | else sdf |
| 153 | fi |
| 154 | |
| 155 | fi |
| 156 | } |