The build and test processes are implemented in CSB itself. Use csb.build
to build, test and package the entire project:
$ python csb/build.py -o <output directory>
This will produce a standard installable release package. If Epydoc is installed, our HTML API docs will be compiled and included as well.
Under a Continuous Integration model (CI), CSB should be built and tested after each
commit). CI builds can be configured using a simple
Travis CI job which runs the csb/build.py
program at regular intervals
using arbitrary Python interpreter versions (Python 2.7 and 3.6 by default). To
automate this task, we provide a Travis CI job configuration, which performs the following:
csb/build.py
with the desired Python interpreter and collect all build
artifacts and API docsNote: When testing a release package, make sure it does not interfere with other releases that might be installed on the same machine. This is achieved by installing the package in a virtual environment. Here is an example with anaconda:
$ conda create -n test python=2.7
$ pip install csb-x.y.z
$ csb-test
Follow these steps to build and deploy a new release:
Bump the version number stored in csb.__version__
if necessary and push all final
changes:
$ git commit -a -m "bump version: x.y.z"
$ git push
Add a new repository tag matching the new version: R-x.y.z
$ git tag R-x.y.z
$ git push --tags
Push the new release to PyPi:
$ pip install twine
$ twine upload csb-*.*