Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PR: Add ciocheck and circle ci linux integration #56

Merged
merged 4 commits into from
Oct 28, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
107 changes: 107 additions & 0 deletions .ciocheck
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
# -----------------------------------------------------------------------------
# ciocheck
# https://github.com/ContinuumIO/ciocheck
# -----------------------------------------------------------------------------
[ciocheck]
branch = origin/master
diff_mode = commited
file_mode = lines
check = pep8,pydocstyle,flake8,pylint
enforce = pep8,pydocstyle,flake8

# Python (pyformat)
add_copyright = true
add_header = true
add_init = true

# -----------------------------------------------------------------------------
# pep8
# http://pep8.readthedocs.io/en/latest/intro.html#configuration
# -----------------------------------------------------------------------------
[pep8]
exclude = */tests/*
ignore = E126,
max-line-length = 79

# -----------------------------------------------------------------------------
# pydocstyle
# http://www.pydocstyle.org/en/latest/usage.html#example
# -----------------------------------------------------------------------------
[pydocstyle]
add-ignore = D203
inherit = false

# -----------------------------------------------------------------------------
# Flake 8
# http://flake8.readthedocs.io/en/latest/config.html
# -----------------------------------------------------------------------------
[flake8]
exclude = */tests/*
ignore = E126,
max-line-length = 79
max-complexity = 64

# -----------------------------------------------------------------------------
# pylint
# https://pylint.readthedocs.io/en/latest/
# -----------------------------------------------------------------------------
#[pylint:messages]

# -----------------------------------------------------------------------------
# isort
# https://github.com/timothycrosley/isort/wiki/isort-Settings
# -----------------------------------------------------------------------------
[isort]
from_first = true
import_heading_stdlib = Standard library imports
import_heading_thirdparty = Third party imports
import_heading_firstparty = Local imports
indent = ' '
known_first_party = qtawesome
known_third_party =
line_length = 79
sections = FUTURE,STDLIB,THIRDPARTY,FIRSTPARTY,LOCALFOLDER

# -----------------------------------------------------------------------------
# yapf
# https://github.com/google/yapf#formatting-style
# -----------------------------------------------------------------------------
[yapf:style]
based_on_style = pep8
column_limit = 79
spaces_before_comment = 2

# -----------------------------------------------------------------------------
# autopep8
# http://pep8.readthedocs.io/en/latest/intro.html#configuration
# -----------------------------------------------------------------------------
[autopep8]
exclude = */tests/*
ignore = E126,
max-line-length = 79

# -----------------------------------------------------------------------------
# Coverage
# http://coverage.readthedocs.io/en/latest/config.html
# -----------------------------------------------------------------------------
[coverage:run]
omit =
*/tests/*
*/build/*

[coverage:report]
fail_under = 0
show_missing = true
skip_covered = true
exclude_lines =
pragma: no cover
def test():
if __name__ == .__main__.:

# -----------------------------------------------------------------------------
# pytest
# http://doc.pytest.org/en/latest/usage.html
# -----------------------------------------------------------------------------
[pytest]
addopts = -rfew --durations=10
python_functions = test_*
7 changes: 7 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,13 @@
# QtAwesome


## Build status
[![Build Status](https://travis-ci.org/spyder-ide/qtawesome.svg?branch=master)](https://travis-ci.org/spyder-ide/qtawesome)
[![CircleCI](https://circleci.com/gh/spyder-ide/qtawesome/tree/master.svg?style=shield)](https://circleci.com/gh/spyder-ide/qtawesome/tree/master)
[![Code Issues](https://www.quantifiedcode.com/api/v1/project/5b42f6edb1ac4465b0e891a4b0144bd8/badge.svg)](https://www.quantifiedcode.com/app/project/5b42f6edb1ac4465b0e891a4b0144bd8)
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/spyder-ide/qtawesome/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/spyder-ide/qtawesome/?branch=master)

## Project information
[![Documentation Status](https://readthedocs.org/projects/qtawesome/badge/?version=latest)](http://qtawesome.readthedocs.org/en/latest/?badge=latest)

## Description
Expand Down
35 changes: 35 additions & 0 deletions circle.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# https://circleci.com/gh/spyder-ide/qtawesome
machine:
environment:
# Used by qthelpers to close widgets after a defined time
TEST_CI: "True"
# Python versions to tests (Maximum of 4 different versions)
PY_VERSIONS: "2.7 3.4 3.5 3.5"
QT_VERSIONS: "5.* 5.* 4.* 5.*"
# Environment variables used by astropy helpers
TRAVIS_OS_NAME: "linux"
CONDA_DEPENDENCIES: "qtpy"
PIP_DEPENDENCIES: "coveralls"

dependencies:
override:
# First convert PY_VERSIONS to an array and then select the python version based on the CIRCLE_NODE_INDEX
- export PY_VERSIONS=($PY_VERSIONS) &&
export QT_VERSIONS=($QT_VERSIONS) &&
export TRAVIS_PYTHON_VERSION=${PY_VERSIONS[$CIRCLE_NODE_INDEX]} &&
QT_VERSION=${QT_VERSIONS[$CIRCLE_NODE_INDEX]} &&
CONDA_DEPENDENCIES="$CONDA_DEPENDENCIES qt=$QT_VERSION pyqt=$QT_VERSION" &&
echo -e "PYTHON = $TRAVIS_PYTHON_VERSION \n============" &&
git clone git://github.com/astropy/ci-helpers.git &&
source ci-helpers/travis/setup_conda_$TRAVIS_OS_NAME.sh &&
export PATH="$HOME/miniconda/bin:$PATH" &&
source activate test &&
conda install ciocheck -c conda-forge -c continuumcrew &&
python setup.py develop;

test:
override:
- export PATH="$HOME/miniconda/bin:$PATH" && source activate test && ciocheck qtawesome: # note the colon
parallel: true
- export PATH="$HOME/miniconda/bin:$PATH" && source activate test && python example.py: # note the colon
parallel: true