#!/bin/sh OPTIONS= while [ $# != 0 ] do case $1 in --*) OPTIONS="$OPTIONS $1 $2" shift; shift; ;; *) break esac done exec $1 $OPTIONS