django-jenkins
Plug and play continuous integration with Django and Jenkins
Installation
From PyPI:
$ pip install django-jenkins
Or by downloading the source and running:
$ python setup.py install
Latest git version:
$ pip install -e git+git://github.com/kmmbvnr/django-jenkins.git#egg=django-jenkins $ pip install coverage
Installation for Python 3:
Works out of the box
Django compatibility
django-jenkins=0.XX.Y version suppose to work with django=X.X.Z version.
Probably same version of django-jenkins will works for nearest versions of django=>X.X-1.Z<X.X+1.Z But it’s not guarantied.
All older versions of django-jenkins below current are not supported.
Usage
Add 'django_jenkins' to your INSTALLED_APPS list. Configure Jenkins to run the following command:
$ ./manage.py jenkins --enable-coverage
This will create reports/ directory with junit xml, Coverage and Pylint reports.
For more details see the generic tutorial: https://sites.google.com/site/kmmbvnr/home/django-jenkins-tutorial
Settings
PROJECT_APPS
If present, it is supposed to be a list/tuple of django apps for Jenkins to run. Tests, reports, and coverage are generated only for the apps from this list.
JENKINS_TASKS
List of Jenkins reporters executed by ./manage.py jenkins command.
Default value:
JENKINS_TASKS = ()
JENKINS_TEST_RUNNER
The name of the class to use for starting the test suite for jenkins command. Class should be inherited from django_jenkins.runner.CITestSuiteRunner
Reporters
Here is the reporters prebuild with django-jenkins
django_jenkins.tasks.run_pylint
Runs Pylint over selected Django apps.
Task-specific settings: PYLINT_RCFILE
django_jenkins.tasks.run_csslint
Runs CSS lint tools over app/static/*/*.css files. Creates CSS Lint compatible report for Jenkins
You should have the csslint package installed
django_jenkins.tasks.run_scsslint
Runs SCSS lint tool over app/static/*/*.scss files. Creates CSS Lint compatible report for Jenkins
You should have the scss-lint and scss_lint_reporter_checkstyle tools installed
django_jenkins.tasks.run_pep8
Runs pep8 tool over selected Django apps. Creates Pylint compatible report for Jenkins
You should have pep8 python package (>=1.3) installed to run this task.
Task-specific settings: PEP8_RCFILE
django_jenkins.tasks.run_pyflakes
Runs Pyflakes tool over selected Django apps. Creates Pylint compatible report for Jenkins.
You should have Pyflakes python package installed to run this task.
django_jenkins.tasks.run_flake8
Runs flake8 tool over selected Django apps. Creates pep8 compatible report for Jenkins.
You should have flake8 python package installed to run this task.
django_jenkins.tasks.run_sloccount
Runs SLOCCount tool over selected Django apps. Creates sloccount plugin compatible report for Jenkins.
You should have the SLOCCount program installed to run this task.
Changelog
0.110.0 2016-09-15
Flake8 >= 3.0 support
scss-lint task added
Contribution guide
Set up local jenkins
Set up django-jenkins:
npm install jshint npm install csslint PATH=$PATH:$WORKSPACE/node_modules/.bin tox
Ensure that everything works
Modify the the only one thing
Ensure that everything works again
Fix pep8/pyflakes errors and minimize pylint’s warninigs
Pull request!
Metadata
Release files for django-jenkins 0.110.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| django-jenkins-0.110.0.tar.gz | 19.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| django_jenkins-0.110.0-py2.py3-none-any.whl | Python 2, Python 3 | none | any | Details |
Total release size: 40.8 kB
Release files / django-jenkins-0.110.0.tar.gz
| Download URL | django-jenkins-0.110.0.tar.gz |
|---|---|
| Size | 19.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a8a11487323c90dc77e781fce584341c8f40b50e93c846550167ea71e2b41956
|
|
BLAKE2b-256 checksum How to use checksums |
46086a24e7aeba7ce1654d7492839019fe228a6998c5d7c002406f125dd31c50
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / django_jenkins-0.110.0-py2.py3-none-any.whl
| Download URL | django_jenkins-0.110.0-py2.py3-none-any.whl |
|---|---|
| Size | 21.0 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
2dda72ffc85311612cadf400b90900be4972867e074daf1f1602c607a9899ba8
|
|
BLAKE2b-256 checksum How to use checksums |
1e76af94e532d6563cc577aefe41a8d54fb56a737518e4ca012acffd705c7d64
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |