All pastes #430341 Raw Edit

Miscellany

public text v1 · immutable
·published 2007-04-08 22:33 UTC
rendered paste body
while test $# -gt 0; do
    DO_SHIFT=:
    case "$1" in
        "-files" )
            shift
            get_listargs "$@"
            for f in  ${!ARGS_ARRAY[@]}; do
                FILES[f]="$(abspath "${ARGS_ARRAY[f]}")"
            done
            ;;
        "-titleset" )
            shift
            unset x y ARGS_ARRAY
            # Hackish list-parsing
            while test $# -gt 0 && test "$1" != "-end-titleset"; do
                ARGS_ARRAY[x++]="$1"
                shift
            done
            # Do not skip past the next argument
            if test $# -gt 0 && test x"${1:0:1}" = x"-";then
                DO_SHIFT=false
            fi
            TITLESET_OPTS[y++]="${ARGS_ARRAY[@]}"
            DO_TITLESETS=:
            ;