QEMU main repository: Please see https://www.qemu.org/docs/master/devel/submitting-a-patch.html for how to submit changes to QEMU. Pull Requests are ignored. Please only use release tarballs from the QEMU website. http://www.qemu.org
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
716 B
44 lines
716 B
#!/bin/sh
|
|
|
|
hxtoh()
|
|
{
|
|
flag=1
|
|
while read -r str; do
|
|
case $str in
|
|
HXCOMM*)
|
|
;;
|
|
STEXI*|ETEXI*) flag=$(($flag^1))
|
|
;;
|
|
*)
|
|
test $flag -eq 1 && printf "%s\n" "$str"
|
|
;;
|
|
esac
|
|
done
|
|
}
|
|
|
|
hxtotexi()
|
|
{
|
|
flag=0
|
|
while read -r str; do
|
|
case "$str" in
|
|
HXCOMM*)
|
|
;;
|
|
STEXI*|ETEXI*) flag=$(($flag^1))
|
|
;;
|
|
DEFHEADING*)
|
|
echo $(expr "$str" : "DEFHEADING(\(.*\))")
|
|
;;
|
|
*)
|
|
test $flag -eq 1 && echo $str
|
|
;;
|
|
esac
|
|
done
|
|
}
|
|
|
|
case "$1" in
|
|
"-h") hxtoh ;;
|
|
"-t") hxtotexi ;;
|
|
*) exit 1 ;;
|
|
esac
|
|
|
|
exit 0
|
|
|