Giter VIP home page Giter VIP logo

python-cython-ci-example's Introduction

https://travis-ci.org/theochem/python-cython-ci-example.svg?branch=master https://ci.appveyor.com/api/projects/status/ora4yr7kot2ffr8x/branch/master?svg=true

Demo project for building and deploying a Python+Cython packages with AppVeyor CI and Travis CI.

This is based on a similar demo: https://github.com/theochem/python-appveyor-conda-example Additional features:

  • Less auxiliary scripts, making more use of recent Travis and AppVeyor built-in features. This should be easier to understand and adapt.
  • Conda packages for win-32, win-64, linux-64, osx-64.
  • Python 2.7, 3.5, 3.6.
  • Upload to alpha, beta and main channels on Anaconda cloud.
  • Github stable and prerelease source release.
  • PyPI source release. Stable releases only stable only, because others are not safe to upload to PyPI.
  • Documentation deployment to gh-pages (Travis).
  • CI Testing after installation on Travis or AppVeyor instance.
  • Code coverage with codecov.io.

The CI machinery in this project is "easily" used in other projects. The following files/parts need to be copied over (and modified):

  • The version stuff from setup.py and pycydemo/__init__.py. This extracts the version from the latest git tag. Ideally, no other places in your project should define (another) version. Also mind the following in setup.py:
    • zip_safe=False (for nosetests and conda packaging) See nose-devs/nose#1057
    • Order of importing setuptools and Cython matters.
  • Copy tools/conda.recipe/meta.yaml and change the package name and dependencies.
  • Copy .travis.yml and update the env block, including new encrypted tokens and passwords.
  • For windows testing: copy .appveyor.yml and update the env block, including new encrypted tokens and passwords.

Making tokens:

Encrypting tokens (Github, Anaconda) and passwords (PyPI) on Travis-CI:

  • Basic documentation: https://docs.travis-ci.com/user/encryption-keys/
  • Best usage is to just run travis encrypt without arguments. Then enter a variable and content in the form VAR=pass. Press enter. Press Ctrl-d.
  • Copy the encrypted stuff to the env section of .travis.yml

Encrypting tokens (Anaconda) and passwords on AppVeyor:

  • Use https://ci.appveyor.com/tools/encrypt
  • Only enter the password or token itself, so only the pass part of VAR=pass. The VAR is still visible in .appveyor.tml``.
  • Copy to .appveyor.yml.

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.