summaryrefslogtreecommitdiff
path: root/example/read1char
blob: 43a3df8119a3d47f1209b3ca7cf228f30d72ab3c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/sh
# -*- tcl -*-
# The next line is executed by /bin/sh, but not tcl \
exec tclsh "$0" ${1+"$@"}

package require Expect

# read a single character
# Author: Don Libes, NIST

stty raw
expect ?
send_user $expect_out(buffer)