Skip to content

Commit 5d55937

Browse files
Publishing on github
use - Travic-CI.org for CI - SonarCloud.io for code validation - codecov.io for coverage - pypi.python.org for package publishing
1 parent b6a12ab commit 5d55937

File tree

6 files changed

+53
-116
lines changed

6 files changed

+53
-116
lines changed

.travis.yml

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
dist: bionic
2+
language: python
3+
matrix:
4+
include:
5+
- os: linux
6+
python: 3.6
7+
sudo: true
8+
env: BUILD=PYPI
9+
- os: linux
10+
python: 3.7
11+
sudo: true
12+
- os: linux
13+
python: 3.8
14+
sudo: true
15+
install:
16+
- pip install -r requirements/dev.txt
17+
- pip install -r requirements/test.txt
18+
- pip install pytest-cov
19+
script:
20+
- flake8
21+
- python setup.py test
22+
- sonar-scanner
23+
after_success:
24+
- bash <(curl -s https://codecov.io/bash)
25+
addons:
26+
sonarcloud:
27+
organization: cloudbluesonarcube
28+
token:
29+
secure: SFqO8p9smZgff0tG2OnNzGQ7A0GCPVrkUhtss2+XE268wrikfwKoH85iobVPuI9u/qYM0ZTVujFhLXcBxaQhO+d1WHBkh1t9+z9UfLC3Ke+JJaNm1vnnI4L8u82s7xYcpZzu42zY6f9vdfe8M4P9xyDWKDaBY0uUkFv7EW21hFa0OKJ9Wb26L313dFNqawy/mEOLCiakBDUzmAK96M+i+C/m8bhGq1rQ/pst4uc53UNjJhGRz/OvdV1edceGW5qEpP+W6DeqxG5Ht4Y8TlZFUFS8xSbXU2J+ApfgZ8pqTNBYiSKy+QT1Z1dXEmB1tzuBJRVC0rdSZ5wCHvOrQN+gf8TU3ifUdoh2KztNuwRiRwoJY9K8XAVtGdewYHUBdUR+GWR0Q41kv6kAXaO1hnqcrwS3UqhiGqeqA6K9kvqgHOjDY6gpCEDpucypaQMijcUE3F0bHiiElnm6tLfQvnB6Is8ppYH2sQPQ1YePDTovUo1mcfKqvRUY362FvFaPQrgyJziSkqmcGmNTuQlC6foWX6qQaZUDvSTyWX2/C0Gc4QFyHq/xjRR3NrUnF3DvEjr439z29baQYX0OmQIZkU2WysE4ko94qmwOgV/Bxq7NNcrsyFgZEPbpeR1+8pLCw/d/Mespm9YTseZuBhX+lFKIMqzZIRDDiHJ9RzsjlH+2804=
30+
deploy:
31+
skip_cleanup: true
32+
skip_existing: true
33+
provider: pypi
34+
user: "__token__"
35+
password:
36+
secure: qW4MPrXOg19JlL+zhU43r8ZtNiFfNxACFSlcv5puCffiBpJOWoKES9ytTCCWLcxo0gepo8Y8tORVgyAGC0gnPrw5vzge0QjFYv+kWHOGAns7qW1xJ0npGiTf7lyTgKUOJLuH3E3X6JEdDJfKXUjeLbozaqz1bTl3yivMAZpTwOG9crlMkNM6vCaIKxuPI6cfcWd7M0P4ylKYHeDVGUSNaY2ckXBLJP0HfwR7CYvn2RsxNQDtiISULZPz8THOiG//kv/RYwOYad+9S7F4fMv9jFjMZtWMUiKOxp/t5eG9U8GOfpEr84sCSR+MtiQWA7PbvuBG12GXqe0xqpbvYQx0bLEO6up9MA3uTwVwKpKf8eYNVs9A+vzyxfX8oYs6eXgRS6ESqWB+03yo8dbtt8E7oGyzknI5oEqJOgRmxSLrkI7VklzPyj98y/d53ein6ExmWt1noJpEcoJ1FkWRlDiTBFQSU42kgTCXl2Lm2mUg9YAtF42dHDoKQ86Y9qcom+B7xQhoCC701RBweE1CPGo/lW8k7YKQ6vi4KFK4qWwn6dWfAe322t2V08z+tWnrHKtMJKLvQHw/QdH1jtyZ+4U9cA98aHxhtW1XITi/A2Bi2Wlh81k5aCsIpZqvrSVEt6PNf3//BVZdVePSxabFv9wZDNIGyBvSndA+glwT5wql80g=
37+
on:
38+
tags: true
39+
all_branches: true
40+
distributions: sdist
41+
condition: "$BUILD = PYPI"

Jenkinsfile

Lines changed: 0 additions & 107 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
Django CQRS
22
===========
3+
![pyversions](https://img.shields.io/pypi/pyversions/django-cqrs.svg) [![PyPi Status](https://img.shields.io/pypi/v/django-cqrs.svg)](https://pypi.org/project/django-cqrs/) [![codecov](https://codecov.io/gh/cloudblue/django-cqrs/branch/master/graph/badge.svg)](https://codecov.io/gh/cloudblue/django-cqrs) [![Build Status](https://travis-ci.org/cloudblue/django-cqrs.svg?branch=master)](https://travis-ci.org/cloudblue/django-cqrs) [![PyPI status](https://img.shields.io/pypi/status/django-cqrs.svg)](https://pypi.python.org/pypi/django-cqrs/) [![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=django-cqrs&metric=alert_status)](https://sonarcloud.io/dashboard?id=django-cqrs)
34

45
`django-cqrs` is an Django application, that implements CQRS data synchronisation between several Django microservices.
56

setup.py

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,10 @@ def read_file(name):
1515
url='https://connect.cloud.im',
1616
description='Django CQRS data synchronisation',
1717
long_description=read_file('README.md'),
18-
license=read_file('LICENSE'),
18+
long_description_content_type='text/markdown',
19+
license='Apache License, Version 2.0',
1920

20-
python_requires='>=3.5',
21+
python_requires='>=3.6',
2122
zip_safe=True,
2223
packages=find_packages(),
2324
include_package_data=True,
@@ -28,12 +29,14 @@ def read_file(name):
2829

2930
keywords='django cqrs sql mixin amqp',
3031
classifiers=[
31-
'Development Status :: 2',
32+
'Development Status :: 5 - Production/Stable',
3233
'Framework :: Django :: 1.11',
3334
'Intended Audience :: Developers',
3435
'License :: OSI Approved :: Apache Software License',
3536
'Operating System :: Unix',
36-
'Programming Language :: Python :: 3',
37+
'Programming Language :: Python :: 3.6',
38+
'Programming Language :: Python :: 3.7',
39+
'Programming Language :: Python :: 3.8',
3740
'Topic :: Communications',
3841
'Topic :: Database',
3942
]

sonar-project.properties

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
sonar.host.url=http://sonar.rnd.host
2-
3-
sonar.projectKey=connect:library:django-cqrs
4-
sonar.projectName=Connect Django CQRS
1+
sonar.projectKey=django-cqrs
2+
sonar.projectName=Django CQRS
3+
sonar.organization=cloudbluesonarcube
54

65
sonar.language=py
76

tests/test_commands/test_bulk_dump.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ def tests_dumps_several_rows(capsys):
6464
assert len(lines) == 3
6565
assert lines[0].strip() == 'author'
6666

67-
line_with_publisher = next(l for l in lines[1:] if '"name":"publisher"' in l)
67+
line_with_publisher = next(ln for ln in lines[1:] if '"name":"publisher"' in ln)
6868
assert author.to_cqrs_dict() == ujson.loads(line_with_publisher)
6969

7070
captured = capsys.readouterr()

0 commit comments

Comments
 (0)