summaryrefslogtreecommitdiff
path: root/tests/trap2.sub
blob: 73357df2a25dfd8c11adab8a78abadc2ac668ffd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
set +e
trap 'echo ERRTRAP' ERR

false
false
false

echo after falses

if ! false; then
	echo if negation ok
fi

! false
echo after negation 

while false; do
	echo while negation ok
done

echo after while

./trap2a.sub

echo $(false ; echo command substitution)