git-svn-id: svn+ssh://svn.dolda2000.com/srv/svn/repos/src/utils@1119
959494ce-11ee-0310-bf91-
de5d638817bd
origargs=("$0" "$@")
cmdline=(mplayer -fs -ass)
-unset pretend
+unset pretend printfile
while [ "${1:0:1}" = - ]; do
a="$1"
shift
case "$a" in
-h)
- echo "usage: planime [-htC] [-s PAR VAL] [NAME-QUAL] [EP|.] [TYPE-QUAL]" >&2
+ echo "usage: planime [-htCf] [-A PLAYER-ARGS... ;] [-s PAR VAL] [NAME-QUAL] [EP|.] [TYPE-QUAL]" >&2
exit 0
;;
-t)
saveval="$1"
shift
;;
+ -f)
+ printfile=y
+ ;;
esac
done
if [ -n "$pretend" ]; then
echo "${cmdline[@]}" "$file"
+elif [ -n "$printfile" ]; then
+ echo "$file"
else
if [ "$chwp" = y ]; then (sleep 2; randomwp) & fi
"${cmdline[@]}" "$file"