loopize
上传用户:rrhhcc
上传日期:2015-12-11
资源大小:54129k
文件大小:1k
- #!/bin/sh
- #
- # convert bulkey CMU scripts
- # into something more compact
- #
- T=/tmp/$$
- #T=t
- cat >$T.raw
- grep set-dist <$T.raw >$T.set-dist
- grep -v set-dist <$T.raw
- cat $T.set-dist |
- grep ^.god_ |
- perl -ane 'BEGIN { print "foreach {a b c} {n"; }
- { print "t$F[2] $F[3] $F[4]n" }
- END { print "} {nt$god_ set-dist $a $b $cn}n"; }'
- cat $T.set-dist |
- grep -v ^.god_ |
- perl -ane 'BEGIN { print "foreach {t a b c} {n"; }
- { $F[7] =~ s/"//g; print "t$F[2] $F[5] $F[6] $F[7]n" }
- END { print "} {nt$ns_ at $t "god_ set-dist $a $b $c"n}n"; }'