Developer environment

Dependencies

A C/C++ compilation environment

On a Debian based system install the build-essential package. On OS X, install XCode and MacPorts.

Git

On a Debian based system install the git-core package. On OS X, get the latest version from http://code.google.com/p/git-osx-installer/.

Python 2.7

On a Debian based system install the python2.7-dev package. On OS X (and others) use the buildout.python to prepare a clean Python installation.

Build

First, you need to clone the git repository on GitHub to download the code to your local machine:

$ git clone git@github.com:niteoweb/spinnerchief.git

What follows is initializing the buildout environment:

$ cd spinnerchief
$ python2.7 bootstrap.py

And now you can run the buildout. This will fetch and configure tools and libs needed for developing spinnerchief:

$ bin/buildout

Verify

Your environment should now be ready. Test that by using the py Python interpreter inside the bin directory, which has spinnerchief installed in it’s path:

$ bin/py

>>> from spinnerchief import SpinnerChief
>>> sc = SpinnerChief('api_key', 'username', 'password')
>>> sc.unique_variation('Some random text.')
u"Some random lines."

The code for spinnerchief lives in src/. Make a change and re-run bin/py to see it resembled!

Moreover, you should have the following tools in the bin/ directory, ready for use:

vvv

A sintax validation tool.

sphinbuilder

A tool for testing HTML render of spinnerchief‘s documentation.

longtest

A tool for testing the HTML render of the package description (part of zest.releaser).

mkrelease

A tool we use for releasing a new version (part of jarn.mkrelease).