Skip to content

Instantly share code, notes, and snippets.

@commenthol
Created June 24, 2018 11:26
Show Gist options
  • Save commenthol/c1ebdb61825dae0389bd33d03c2dccd5 to your computer and use it in GitHub Desktop.
Save commenthol/c1ebdb61825dae0389bd33d03c2dccd5 to your computer and use it in GitHub Desktop.
start exe files from cygwin
#!/bin/bash
exe=$(cygpath -u "C:\Program Files (x86)\Geany\bin\geany.exe")
args=""
while (( "$#" )); do
arg=$1
if [[ $arg == /* ]] ; then
arg=\"$(cygpath -a -w "$arg")\"
fi
args+="$arg "
shift
done
# echo $exe $args
cygstart "$exe" $args
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment