Blame |
Last modification |
View Log
| RSS feed
1
#!/bin/bash
echo
interactive=0
echo $\*=$*
for i in "$*"; do
opt=0
idx=1
while [ -n "`echo $i | cut -c $idx`" ] ; do
j=`echo $i | cut -c $idx`
let idx=$idx+1
if [ "$j" = "-" ]; then
opt=1
continue 1
else
if [ $opt -eq 1 ]; then
case "$j" in
"i") interactive=1 ;;
esac
lastopt=$j
else
phrase=$phrase" "$j
fi
fi
done
done
echo opt=$opt
echo idx=$idx
echo lastopt=$lastopt
echo phrase=$phrase
echo interactive=$interactive
echo