Killer Web Development

by Marco Laspe

2.5 BONUS: Using web2py with Cygwin

Web development seems to be a bit cumber stone on Windows - at least to me. If you want to have unix-like development powers on Windows you can use Cygwin as an alternative.

Cygwin is a Linux-API for Windows that enables you to use the famous Linux command line tools like Curl on Windows. Cygwin will make it much easier for you to follow this book, because you can put in the code as it is printed out - no need to change slashes / to backslashes \ or to use alternative applications like TortoiseHg for version control. On the other hand web2py and Python both come from a Linux background and therefore fit much better in that context than in a standard Windows environment. With Cygwin you can bypass these shortcomings on Windows.

Install Cygwin

Download Cygwin's setup.exe and start it; mark Install from Internet

Install Cygwin - Choosing the connection type

and the Choose A Download Source page mark Install from Internet, entry your prefered installation directories, select your connection type and choose a donwload site near you.

Install Cygwin - Server

In the software selection page entry mercurial in the searchbox and then mark the Mercurial package for installation; then do the same with curl and unzip.

Install Cygwin - Install Linux Programms on Windows

Start the installation, ignore possible warnings - they just inform you, that some dependencies (like Python) will be installed.

Install Cygwin - Dependencies

If you now start the Cygwin Terminal from the Start Menu, you should see a Unix terminal.

Install web2py on Cygwin

Now we need to download web2py, we will do this from the command line:

$ curl -O
$ unzip
$ cd web2py
$ ./
choose a password: [pass]

got to http://localhost:8000 and you should see the web2py welcome page. You can also start gedit from the Cygwin Terminal, be sure that the PATH variable is set.

Books often read by web2py and Python experts:


Leave a Reply

Required fields are marked *.