]> git.ipfire.org Git - thirdparty/bash.git/blob - tests/type.right
Bash-4.3 patch 7
[thirdparty/bash.git] / tests / type.right
1 ./type.tests: line 9: type: -r: invalid option
2 type: usage: type [-afptP] name [name ...]
3 ./type.tests: line 12: type: notthere: not found
4 function
5 keyword
6 builtin
7 file
8 file
9 file
10 func is a function
11 func ()
12 {
13 echo this is func
14 }
15 while is a shell keyword
16 while is a shell keyword
17 builtin is a shell builtin
18 /bin/sh is /bin/sh
19 func
20 func is a function
21 func ()
22 {
23 echo this is func
24 }
25 while
26 while is a shell keyword
27 ./type.tests: line 43: type: m: not found
28 alias m='more'
29 alias m='more'
30 m is aliased to `more'
31 alias
32 alias m='more'
33 alias m='more'
34 alias m='more'
35 m is aliased to `more'
36 builtin
37 builtin is a shell builtin
38 /bin/sh
39 /bin/sh is /bin/sh
40 ./type.tests: line 65: type: func: not found
41 ./type.tests: line 67: type: m: not found
42 /bin/sh
43 /tmp/bash
44 bash is hashed (/tmp/bash)
45 file
46 hits command
47 3 /tmp/bash
48 1 /bin/sh
49 f is a function
50 f ()
51 {
52 v='^A'
53 }
54 foo is a function
55 foo ()
56 {
57 echo $(<x1)
58 }
59 bar is a function
60 bar ()
61 {
62 echo $(<x1)
63 }
64 foo is a function
65 foo ()
66 {
67 echo;
68 cat <<END
69 bar
70 END
71
72 cat <<EOF
73 qux
74 EOF
75
76 }
77
78 bar
79 qux
80
81 bar
82 qux
83 foo is a function
84 foo ()
85 {
86 rm -f a b c;
87 for f in a b c;
88 do
89 cat >> ${f} <<-EOF
90 file
91 EOF
92
93 done
94 grep . a b c
95 }
96 a:file
97 b:file
98 c:file
99 bb is a function
100 bb ()
101 {
102 ( cat <<EOF
103 foo
104 bar
105 EOF
106 )
107 echo after subshell
108 }
109 mkcoprocs is a function
110 mkcoprocs ()
111 {
112 coproc a {
113 cat <<EOF1
114 producer 1
115 EOF1
116
117 }
118 coproc b {
119 cat <<EOF2
120 producer 2
121 EOF2
122
123 }
124 echo "coprocs created"
125 }
126 mkcoprocs is a function
127 mkcoprocs ()
128 {
129 coproc COPROC ( b cat <<EOF
130 heredoc
131 body
132 EOF
133 )
134 echo "coprocs created"
135 }