]> git.ipfire.org Git - thirdparty/bash.git/blame - tests/redir9.sub
Bash-4.3 patch 7
[thirdparty/bash.git] / tests / redir9.sub
CommitLineData
3185942a
JA
1: ${TMPDIR:=/tmp}
2
3func()
4{
5 echo "to stdout"
6 echo "to stderr" >&2
7}
8
9TMPFN=$TMPDIR/foo-$$
10
11rm -f $TMPFN
12
13echo hey > $TMPFN
14func &>> $TMPFN
15
16cat $TMPFN
17
18echo
19func &> $TMPFN
20
21cat $TMPFN
22
23echo
24func >$TMPFN
25cat $TMPFN
26
27echo
28echo hey > $TMPFN
29func >> $TMPFN
30cat $TMPFN
31
32rm -f $TMPFN
33
34logfunc()
35{
36 echo "$@" &>> $TMPDIR/log
37}
38
39type logfunc
40
41echo foo 2>&1
42
43bix()
44{
45echo foo |& cat
46}
47
48type bix
49
50bix