1#!/bin/bash
2#
3#   we [command] [args...]
4#
5#     - execute win32 command with posix pathname
6#
7for i in "$@"
8do
9	case "$i" in \
10	/* )
11		PARAM=`cygpath -m "$i"`
12		;;
13
14	-?/* )
15		PARAM=${i:0:2}`cygpath -m "${i:2}"`
16		;;
17
18	-*=/* )
19		PARAM=${i%%/*}`cygpath -m "${i#-*=}"`
20		;;
21
22	*)
23		PARAM="$i"
24		;;
25	esac
26	CMD="${CMD} ${PARAM// /\ }"
27done
28bash -c "${CMD}"
29