2009-03-28 09:44:27 +03:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
hxtoh()
|
|
|
|
{
|
|
|
|
flag=1
|
2009-03-29 13:06:43 +04:00
|
|
|
while read -r str; do
|
2009-03-28 09:44:27 +03:00
|
|
|
case $str in
|
|
|
|
HXCOMM*)
|
|
|
|
;;
|
2020-03-06 20:17:45 +03:00
|
|
|
SRST*|ERST*) flag=$(($flag^1))
|
2009-03-28 09:44:27 +03:00
|
|
|
;;
|
|
|
|
*)
|
2009-03-29 14:50:43 +04:00
|
|
|
test $flag -eq 1 && printf "%s\n" "$str"
|
2009-03-28 09:44:27 +03:00
|
|
|
;;
|
|
|
|
esac
|
|
|
|
done
|
|
|
|
}
|
|
|
|
|
|
|
|
case "$1" in
|
|
|
|
"-h") hxtoh ;;
|
|
|
|
*) exit 1 ;;
|
2019-07-15 17:06:04 +03:00
|
|
|
esac < "$2"
|
2009-03-28 11:13:56 +03:00
|
|
|
|
|
|
|
exit 0
|