how to identify the input is backspace
see the following code
stty cbreak -echo
input==`dd if=/dev/tty bs=1 count=1 2>/dev/null`
stty -cbreak echo
if [ "$input" = "a" ];then
echo "the input is a"
fi
how I can ensure the input is backspace. In other words,what is the symbol
of backspace.
No comments:
Post a Comment