File: debug-chewing-shell.sh

package info (click to toggle)
libchewing 0.3.2-2
  • links: PTS, VCS
  • area: main
  • in suites: squeeze
  • size: 7,588 kB
  • ctags: 878
  • sloc: sh: 9,738; ansic: 7,644; makefile: 234; python: 49
file content (15 lines) | stat: -rwxr-xr-x 465 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
#!/bin/sh

PREFERABLE_XTERM=urxvt
MESSAGES="Please type 'run' inside gdb session to invoke genkeystroke.

After execution, close this X terminal."

$PREFERABLE_XTERM -e sh \
  -c "tty > /tmp/name_of_xterm_ptty && 
      echo -e \"$MESSAGES\" && sleep 100000" &
sleep 1
echo "tty `cat /tmp/name_of_xterm_ptty`" > .chewing-gdb-macro
echo "set args test.txt" >> .chewing-gdb-macro
libtool --mode=execute gdb -x .chewing-gdb-macro genkeystroke
rm -f .chewing-gdb-macro