test: Add a test for the model's 'tags' attribute
[git-cola.git] / win32 / cola
blobd1ff3908319e5bac58ee261b47fe52b36942d9fd
1 #!/bin/sh
2 # This should work with either Python2.5 or Python2.6.
4 # Windows doesn't have the 'dirname' command, so fake it
5 dirname() {
6 dir=$(echo "$@" | perl -pe 's,(.*)/[^/]+,\1,')
7 test "$dir" = "$1" && dir=.
8 echo "$dir"
10 mydir="$(dirname $0)"
11 parentdir="$(dirname $mydir)"
13 # Windows uses 'git-cola.pyw' instead of 'git-cola'
14 COLA="$parentdir"/bin/git-cola
15 if test -f "$COLA".pyw; then
16 COLA="$COLA".pyw
19 # Find a suitable Python and use it to run cola
20 for python in /c/Python26 /c/Python25; do
21 if test -d "$python"; then
22 PATH="$PATH":$python
23 exec $python/python.exe "$COLA" "$@"
25 done
26 exit 1