Wednesday, January 19, 2011

Play framework with cygwin

For whatever reason the people doing the play framework force people on Windows to use cmd instead of cygwin. If you have the Python installed under Windows (not cygwin - "the windows and the cygwin python are completely different" - http://cygwin.com/ml/cygwin/2004-02/msg01120.html) you can use the following script. I name it play.sh and put it in the play directory:


#!/bin/bash

play=`which play`
python `cygpath -wp $play $1 $2 $3 $4 $5 $6 $7 $8 $9`


Play attention to the quotes... (the script is based on the idea put forth here: http://www.inonit.com/cygwin/faq/)

Note: You still need to have the play directory in your path otherwise which won't work.

0 Comments:

Post a Comment

<< Home