Giter VIP home page Giter VIP logo

python-appveyor-conda-example's Introduction

python-appveyor-conda-example

Travis Build Status Appveyor Build status Binstar Badge

Demo project for building and shipping Python conda packages with Appveyor CI and Travis CI.


AppVeyor and Travis are continuous integration platforms for Windows and Linux respectively. Both are free for Open Source projects and run in the cloud. This sample Python project has a simple C compiled extension. The build itself is configured by the setup.py file, and orchestrated by conda build.

Conda is a cross-platform, Python-agnostic binary package manager. It is open source (BSD), and is the package manager used by Anaconda scientific python distribution. It is particularly well suited for managing and distributing environments for the scientific python (NumPy, Scipy) stack, where complex system dependencies and build requirements -- e.g C and Fortran extensions -- are the norm. For more information about conda, see this blog post by Travis Oliphant, the original developer of Numpy and developer of conda.

On each commit to Github, both CI services perform automated builds and run the package's tests. The package is built as a conda binary and directly uploaded to binstar.org

As currently set up, 8 binary packages are built:

  • 32 bit Windows, Python 2.7
  • 32 bit Windows, Python 3.3
  • 64 bit Windows, Python 2.7
  • 64 bit Windows, Python 3.3
  • 64 bit Linux (Ubuntu 12.04), Python 2.6
  • 64 bit Linux (Ubuntu 12.04), Python 2.7
  • 64 bit Linux (Ubuntu 12.04), Python 3.3
  • 64 bit Linux (Ubuntu 12.04), Python 3.4

Users can then install these packages with conda install -c https://conda.binstar.org/rmcgibbo pyappveyordemo

Binstar

Binstar.org is a website for hosting public and private conda packages. To upload your conda binaries built on Appveyor to binstar, you'll first need to create a binstar token to authenticate the appveyor server with binstar.

This command will require entering your binstar credentials, and produce a token.

$ binstar auth -n name-of-your-token --max-age 22896000 -c --scopes api

The token grants its owner write permissions to your binstar account, so you won't want to put it into your (public) appveyor.yml file without first encrypting it. Copy and paste the token into this form on the appveyor appveyor website to encrypt the token. It will give you a snippet to add to your appveyor.yml file, e.g.

environment:
  BINSTAR_TOKEN:
    secure: Yfr/w3h22F5s/wGT8RYrSt6jRD2UHwUm8PPWjzaGh2B3bTBZAf4uXqCO/yUnCXYe

To encrypt the token for inclusion in the .travis.yml file, use the travis gem to generate the encrypted string

$ travis encrypt BINSTAR_TOKEN=your-binstar-token-from-above

Credits

This demo is a fork of Olivier Grisel's (@ogrisel) python-appveyor-demo, which builds Python wheel files using the same infrastructure.

He, @FeodorFitsner, and @tomconte solved all the difficult parts of properly configuring the Windows SDKs and MSVC environment.

python-appveyor-conda-example's People

Contributors

rmcgibbo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.