Browse Subversion Repository
Contents of /branches/ttcomtester/tests/decfi-bce.sh
Parent Directory
| Revision Log
Revision 10521 -
( show annotations)
( download)
( as text)
Fri Jan 20 16:03:38 2023 UTC
(13 months, 2 weeks ago)
by zmatsuo
File MIME type: text/x-sh
File size: 492 byte(s)
add communication test tool
| 1 |
#!/bin/sh |
| 2 |
|
| 3 |
trap "OSC 111; CSI m; exit" 0 2 |
| 4 |
|
| 5 |
ESC() { |
| 6 |
while [ $# -gt 0 ]; do |
| 7 |
printf "\033$1" |
| 8 |
shift |
| 9 |
done |
| 10 |
} |
| 11 |
|
| 12 |
CSI() { |
| 13 |
while [ $# -gt 0 ]; do |
| 14 |
ESC "[$1" |
| 15 |
shift |
| 16 |
done |
| 17 |
} |
| 18 |
|
| 19 |
OSC() { |
| 20 |
while [ $# -gt 0 ]; do |
| 21 |
ESC "]$1" '\' |
| 22 |
shift |
| 23 |
done |
| 24 |
} |
| 25 |
|
| 26 |
OSC "11;#440000" |
| 27 |
CSI "4;37;44m" H 2J |
| 28 |
|
| 29 |
echo "1234567890"; sleep 1 |
| 30 |
|
| 31 |
printf "shift to the right 5 columns"; sleep 1 |
| 32 |
CSI G |
| 33 |
ESC 6 6 6 6 6 |
| 34 |
echo "" |
| 35 |
|
| 36 |
sleep 2 |
| 37 |
|
| 38 |
CSI 6G |
| 39 |
printf "shift to the left 3 columns"; sleep 1 |
| 40 |
CSI 999G |
| 41 |
ESC 9 9 9 |
| 42 |
echo |
| 43 |
|
| 44 |
sleep 2 |
|