Skip to content

Commit

Permalink
Updated packaging/testing/documentation configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
agronholm committed Sep 30, 2017
1 parent 2dda280 commit 53a4dfc
Show file tree
Hide file tree
Showing 6 changed files with 118 additions and 87 deletions.
11 changes: 11 additions & 0 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
type: sphinx
python:
version: "3.5"
pip_install: true
extra_requirements:
- doc
- django
- jinja2
- mako
- tonnikala
- tornado
59 changes: 42 additions & 17 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,52 @@
language: python
sudo: false

language: python
jobs:
include:
- env: TOXENV=py35
python: "3.5"

- env: TOXENV=py36
python: "3.6"

- env: TOXENV=pypy3
python: pypy3
after_success: skip

python:
- "3.5"
- "3.6"
- env: TOXENV=flake8
python: "3.5"
after_success: skip

install: pip install tox-travis coveralls
- env: TOXENV=mypy
python: "3.5"
after_success: skip

- stage: deploy to PyPI
python: "3.5"
install: pip install -U setuptools
script: skip
after_success: true
deploy:
provider: pypi
user: agronholm
password:
secure: GKXgo5gQVNo5FQx/jvYjw0wQp/1hhZRAfozr+zWucRxdfbVBFGtdhAQZSAt9bVa9UcgriVtGd8vIFQMvPEh/8fKWJ8atTxdR8iLbI8ujl6lRqUB4y0q4Umkv90BuXcVMQPzddpwYTN26CK3Ajb8Q58fiRruDa3g+QL3JZOh/h0fMKwZ84pd/Gz5xfcHAsb1iykoWC+iECN5VWW7bZ+UN5zGToULrZ3N3pwhOope7cWLH99FGgc9JfcU+Ttk+wVOUdxmWGHY4JOuwRppsEgdA3pPhVRgFbFFxJlXNEtcUPNtHuJ3OQC/xdYfF/sVJ68UfX4Lqm83LImxrxkXKmCGoNA+c98Zi4KozvlFbGeFdJXHPECjhOu1IusZc80cIwtdBiqblJFw097R13AF1WZiDVBLWBEGdu17YFlmaHLCDn1YlQsEXJmrfj0+tabP0yb1Ibon8TP0MGMdOyJLeZrYYMLl4eP6TJDY46c8r67NUShhuDyn9VduVJwNaOt3GLihp+CO5fxLnn01rdwOQ1B5ORmXfWR5CyEehdm0qWOfhdAPtu8pro4Zl5WRg+RIQNi2VyF5o7oHN/ta0hwpnQ/d0uJx6140aH1EIx4OSzZaOeA223IJZWeySgBz1MEIMwQFSZPrXaTsKgDI0My4eaBGKkhEK2uFJcLt4vnKWWMRg760=
distributions: sdist bdist_wheel
on:
tags: true
repo: asphalt-framework/asphalt-templating
allow_failures:
- env: TOXENV=mypy

install:
- pip install -U setuptools
- pip install tox

script: tox

after_success: coveralls
after_success:
- pip install coveralls
- coveralls

notifications:
webhooks:
Expand All @@ -23,14 +59,3 @@ notifications:
on_failure: change
use_notice: true
skip_join: true

deploy:
provider: pypi
user: agronholm
password:
secure: GKXgo5gQVNo5FQx/jvYjw0wQp/1hhZRAfozr+zWucRxdfbVBFGtdhAQZSAt9bVa9UcgriVtGd8vIFQMvPEh/8fKWJ8atTxdR8iLbI8ujl6lRqUB4y0q4Umkv90BuXcVMQPzddpwYTN26CK3Ajb8Q58fiRruDa3g+QL3JZOh/h0fMKwZ84pd/Gz5xfcHAsb1iykoWC+iECN5VWW7bZ+UN5zGToULrZ3N3pwhOope7cWLH99FGgc9JfcU+Ttk+wVOUdxmWGHY4JOuwRppsEgdA3pPhVRgFbFFxJlXNEtcUPNtHuJ3OQC/xdYfF/sVJ68UfX4Lqm83LImxrxkXKmCGoNA+c98Zi4KozvlFbGeFdJXHPECjhOu1IusZc80cIwtdBiqblJFw097R13AF1WZiDVBLWBEGdu17YFlmaHLCDn1YlQsEXJmrfj0+tabP0yb1Ibon8TP0MGMdOyJLeZrYYMLl4eP6TJDY46c8r67NUShhuDyn9VduVJwNaOt3GLihp+CO5fxLnn01rdwOQ1B5ORmXfWR5CyEehdm0qWOfhdAPtu8pro4Zl5WRg+RIQNi2VyF5o7oHN/ta0hwpnQ/d0uJx6140aH1EIx4OSzZaOeA223IJZWeySgBz1MEIMwQFSZPrXaTsKgDI0My4eaBGKkhEK2uFJcLt4vnKWWMRg760=
distributions: sdist bdist_wheel
on:
tags: true
python: "3.5"
repo: asphalt-framework/asphalt-templating
11 changes: 2 additions & 9 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,2 @@
Sphinx >= 1.5
sphinx_rtd_theme
sphinx-autodoc-typehints >= 1.0.5
sphinxcontrib-asyncio >= 0.2.0
django
jinja2
mako
tonnikala
tornado
# This is for ReadTheDocs and can be removed once they upgrade to a newer setuptools release.
setuptools >= 36.2.7
53 changes: 53 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -1,3 +1,56 @@
[metadata]
name = asphalt-templating
description = Templating component for the Asphalt framework
long_description = file: README.rst
author = Alex Grönholm
author_email = alex.gronholm@nextday.fi
url = https://github.com/asphalt-framework/asphalt-templating
license = Apache License 2.0
license_file = LICENSE
classifiers =
Development Status :: 5 - Production/Stable
Intended Audience :: Developers
License :: OSI Approved :: Apache Software License
Topic :: Text Processing :: General
Programming Language :: Python
Programming Language :: Python :: 3
Programming Language :: Python :: 3.5
Programming Language :: Python :: 3.6

[options]
packages =
asphalt.templating
asphalt.templating.renderers
install_requires =
asphalt >= 3.0, < 5.0
typeguard ~= 2.0

[options.extras_require]
django = Django >= 1.9.0
mako = Mako >= 1.0.1
jinja2 = Jinja2 >= 2.7.3
tonnikala = tonnikala >= 1.0.0b1
tornado = tornado >= 4.3.0
test =
pytest
pytest-cov
pytest-asyncio >= 0.5.0
doc =
Sphinx >= 1.5
sphinx_rtd_theme
sphinx-autodoc-typehints >= 1.0.5
sphinxcontrib-asyncio >= 0.2.0

[options.entry_points]
asphalt.components =
templating = asphalt.templating.component:TemplatingComponent
asphalt.templating.renderers =
django = asphalt.templating.renderers.django:DjangoRenderer [django]
jinja2 = asphalt.templating.renderers.jinja2:Jinja2Renderer [jinja2]
mako = asphalt.templating.renderers.mako:MakoRenderer [mako]
tonnikala = asphalt.templating.renderers.mako:TonnikalaRenderer [tonnikala]
tornado = asphalt.templating.renderers.tornado:TornadoRenderer [tornado]

[build_sphinx]
source-dir = docs
build-dir = docs/_build
Expand Down
55 changes: 2 additions & 53 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,63 +1,12 @@
from pathlib import Path

from setuptools import setup

setup(
name='asphalt-templating',
use_scm_version={
'version_scheme': 'post-release',
'local_scheme': 'dirty-tag'
},
description='Templating component for the Asphalt framework',
long_description=Path(__file__).with_name('README.rst').read_text('utf-8'),
author='Alex Grönholm',
author_email='alex.gronholm@nextday.fi',
url='https://github.com/asphalt-framework/asphalt-templating',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License',
'Topic :: Text Processing :: General',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6'
],
license='Apache License 2.0',
zip_safe=False,
packages=[
'asphalt.templating',
'asphalt.templating.renderers'
],
setup_requires=[
'setuptools >= 36.2.7',
'setuptools_scm >= 1.7.0'
],
install_requires=[
'asphalt >= 3.0, < 5.0',
'typeguard ~= 2.0'
],
extras_require={
'django': 'Django >= 1.9.0',
'mako': 'Mako >= 1.0.1',
'jinja2': 'Jinja2 >= 2.7.3',
'tonnikala': 'tonnikala >= 1.0.0b1',
'tornado': 'tornado >= 4.3.0',
'testing': [
'pytest',
'pytest-cov',
'pytest-asyncio >= 0.5.0'
]
},
entry_points={
'asphalt.components': [
'templating = asphalt.templating.component:TemplatingComponent'
],
'asphalt.templating.renderers': [
'django = asphalt.templating.renderers.django:DjangoRenderer [django]',
'jinja2 = asphalt.templating.renderers.jinja2:Jinja2Renderer [jinja2]',
'mako = asphalt.templating.renderers.mako:MakoRenderer [mako]',
'tonnikala = asphalt.templating.renderers.mako:TonnikalaRenderer [tonnikala]',
'tornado = asphalt.templating.renderers.tornado:TornadoRenderer [tornado]'
]
}
]
)
16 changes: 8 additions & 8 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,13 +1,8 @@
[tox]
envlist = py35, py36, flake8

[travis]
python =
3.5: py35, flake8, docs
3.6: py36
envlist = py35, py36, pypy3, flake8

[testenv]
extras = testing
extras = test
django
mako
jinja2
Expand All @@ -16,11 +11,16 @@ extras = testing
commands = python -m pytest {posargs}

[testenv:docs]
deps = -rdocs/requirements.txt
extras = doc
commands = python setup.py build_sphinx {posargs}
usedevelop = true

[testenv:flake8]
deps = flake8
commands = flake8 asphalt tests
skip_install = true

[testenv:mypy]
deps = mypy
commands = mypy --ignore-missing-imports asphalt
skip_install = true

0 comments on commit 53a4dfc

Please sign in to comment.