#!/bin/sh # # Do the common image selection bit from rootbg/menubg. # - Cameron Simpson # : ${BGPATH:=$HOME/im} cmd=`basename "$0"` usage="Usage: $cmd [-P strippfx] [imlist-search-args...]" strippfx= [ "x$1" = x-P ] && { strippfx=$2; shift; shift; } if [ -n "$strippfx" ] then ##set -vx "$0" ${1+"$@"} | sed "s;^$strippfx/;;" exit 0 fi exec imlist-search -p "$BGPATH" -s ${1+"$@"}