From 436de9d65ea00eff37117ea0c3261781b82d346a Mon Sep 17 00:00:00 2001 From: Graham Ullrich Date: Thu, 18 Jan 2018 15:53:52 -0700 Subject: [PATCH] Update django>=1.11 in requirements Remove pytest from CI Add PyPi-compatible docs in setup.py Revise trove classifiers Improve .gitignore Update CI configuration --- .circleci/config.yml | 3 +- .gitignore | 50 +++++++++++--- README.md | 142 +++++++++++++++++++++++++++++--------- pinax/templates/models.py | 0 setup.cfg | 4 -- setup.py | 99 +++++++++++++++++++++----- tox.ini | 24 +++---- 7 files changed, 242 insertions(+), 80 deletions(-) delete mode 100644 pinax/templates/models.py diff --git a/.circleci/config.yml b/.circleci/config.yml index 3361f43..62f45aa 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -7,7 +7,6 @@ common: &common - restore_cache: keys: - v2-deps-{{ .Environment.CIRCLE_JOB }}-{{ checksum "setup.py" }}-{{ checksum "tox.ini" }} - - v2-deps- - run: name: install dependencies command: pip install --user tox @@ -34,7 +33,7 @@ jobs: lint: <<: *common docker: - - image: circleci/python:3.6.1 + - image: circleci/python:3.6 environment: TOXENV=checkqa py27dj18: diff --git a/.gitignore b/.gitignore index b7baf4d..c6037eb 100644 --- a/.gitignore +++ b/.gitignore @@ -1,11 +1,45 @@ -build -dist -.coverage -.tox -.idea MANIFEST -*.pyc -*.egg-info -*.egg +.DS_Store + +# Byte-compiled / optimized / DLL files +__pycache__/ +*.py[cod] + + +# Distribution / packaging +.Python +env/ +build/ +develop-eggs/ +dist/ docs/_build/ +eggs/ +lib/ +lib64/ +parts/ +sdist/ +var/ +*.egg-info/ +.installed.cfg +*.egg +*.eggs +.python-version + +# Pipfile +Pipfile +Pipfile.lock + +# Installer logs +pip-log.txt +pip-delete-this-directory.txt + +# Unit test / coverage reports htmlcov/ +.tox/ +.coverage +.cache +nosetests.xml +coverage.xml + +# IDEs +.idea/ \ No newline at end of file diff --git a/README.md b/README.md index b955792..7ca0715 100644 --- a/README.md +++ b/README.md @@ -3,25 +3,98 @@ # Pinax Templates [![](https://img.shields.io/pypi/v/pinax-templates.svg)](https://pypi.python.org/pypi/pinax-templates/) -[![](https://img.shields.io/badge/license-MIT-blue.svg)](https://pypi.python.org/pypi/pinax-templates/) +[![CircleCi](https://img.shields.io/circleci/project/github/pinax/pinax-templates.svg)](https://circleci.com/gh/pinax/pinax-templates) [![Codecov](https://img.shields.io/codecov/c/github/pinax/pinax-templates.svg)](https://codecov.io/gh/pinax/pinax-templates) -[![CircleCI](https://circleci.com/gh/pinax/pinax-templates.svg?style=svg)](https://circleci.com/gh/pinax/pinax-templates) -![](https://img.shields.io/github/contributors/pinax/pinax-templates.svg) -![](https://img.shields.io/github/issues-pr/pinax/pinax-templates.svg) -![](https://img.shields.io/github/issues-pr-closed/pinax/pinax-templates.svg) +[![](https://img.shields.io/github/contributors/pinax/pinax-templates.svg)](https://github.com/pinax/pinax-templates/graphs/contributors) +[![](https://img.shields.io/github/issues-pr/pinax/pinax-templates.svg)](https://github.com/pinax/pinax-templates/pulls) +[![](https://img.shields.io/github/issues-pr-closed/pinax/pinax-templates.svg)](https://github.com/pinax/pinax-templates/pulls?q=is%3Apr+is%3Aclosed) [![](http://slack.pinaxproject.com/badge.svg)](http://slack.pinaxproject.com/) +[![](https://img.shields.io/badge/license-MIT-blue.svg)](https://opensource.org/licenses/MIT) +## Table of Contents + +* [About Pinax](#about-pinax) +* [Overview](#overview) + * [Features](#features) + * [Supported Pinax Apps](supported-pinax-apps) + * [Supported Django and Python versions](#supported-django-and-python-versions) +* [Documentation](#documentation) + * [Installation](#installation) + * [Usage](#usage) +* [Template Browser](#template-browser) +* [FAQ](#faq) +* [Change Log](#change-log) +* [Contribute](#contribute) +* [Code of Conduct](#code-of-conduct) +* [Connect with Pinax](#connect-with-pinax) +* [License](#license) + +## About Pinax + +Pinax is an open-source platform built on the Django Web Framework. It is an ecosystem of reusable +Django apps, themes, and starter project templates. This collection can be found at http://pinaxproject.com. + +## pinax-templates + +### Overview + +`pinax-templates` provides semantically-correct templates for Pinax apps. + +#### Supported Pinax Apps + +* [django-user-accounts](https://github.com/pinax/django-user-accounts) +* [pinax-announcements](https://github.com/pinax/pinax-announcements) +* [pinax-blog](https://github.com/pinax/pinax-blog) +* [pinax-cohorts](https://github.com/pinax/pinax-cohorts) +* [pinax-documents](https://github.com/pinax/pinax-documents) +* [pinax-invitations](https://github.com/pinax/pinax-invitations) +* [pinax-likes](https://github.com/pinax/pinax-likes) +* [pinax-notifications](https://github.com/pinax/pinax-notifications) +* [pinax-stripe](https://github.com/pinax/pinax-stripe) + +#### Supported Django and Python versions + +Django \ Python | 2.7 | 3.4 | 3.5 | 3.6 +--------------- | --- | --- | --- | --- +1.11 | * | * | * | * +2.0 | | * | * | * + + +## Documentation + +### Installation + +To install pinax-templates: + +```shell +$ pip install pinax-templates +``` + +Add `pinax.templates` to your `INSTALLED_APPS` setting: + +```python +INSTALLED_APPS = [ + # other apps + "pinax.templates", +] +``` + + +### Usage + +With pinax-templates installed, all default templates for supported apps are ready for use. ## Template Browser -These templates have been dressed up with Bootstrap 4 styling at http://templates.pinaxproject.com. +This project provides a template browser at http://templates.pinaxproject.com. +Browse there to see each Pinax application template collection, dressed up with Bootstrap 4 styling. On this site, you can browse all the templates in various different states. In addition there is a source toggle where you can view the template, see what blocks are defined, and easily copy and paste into your project if you want to override -or customize. +or customize the template code. ## FAQs @@ -36,48 +109,49 @@ or customize. ### How do I change the titles on my pages? ---- - -Pinax ------- +## Change Log -Pinax is an open-source platform built on the Django Web Framework. It is an ecosystem of reusable Django apps, themes, and starter project templates. +### 1.0.1 -This collection can be found at http://pinaxproject.com. +* Update django>=1.11 in requirements +* Remove pytest from CI +* Add PyPi-compatible docs in setup.py +* Revise trove classifiers +* Improve .gitignore +* Update CI configuration +### 1.0.0 -Running the Tests -------------------- - -``` -$ pip install detox -$ detox -``` +* Initial release -Documentation ---------------- +## Contribute -The `pinax-templates` documentation is currently under construction. If you would like to help us write documentation, please join our Pinax Project Slack team and let us know! The Pinax documentation is available at http://pinaxproject.com/pinax/. +For an overview on how contributing to Pinax works read this [blog post](http://blog.pinaxproject.com/2016/02/26/recap-february-pinax-hangout/) +and watch the included video, or read our [How to Contribute](http://pinaxproject.com/pinax/how_to_contribute/) section. +For concrete contribution ideas, please see our +[Ways to Contribute/What We Need Help With](http://pinaxproject.com/pinax/ways_to_contribute/) section. +In case of any questions we recommend you join our [Pinax Slack team](http://slack.pinaxproject.com) +and ping us there instead of creating an issue on GitHub. Creating issues on GitHub is of course +also valid but we are usually able to help you faster if you ping us in Slack. -Contribute ----------------- +We also highly recommend reading our blog post on [Open Source and Self-Care](http://blog.pinaxproject.com/2016/01/19/open-source-and-self-care/). -See this blog post http://blog.pinaxproject.com/2016/02/26/recap-february-pinax-hangout/ including a video, or our How to Contribute (http://pinaxproject.com/pinax/how_to_contribute/) section for an overview on how contributing to Pinax works. For concrete contribution ideas, please see our Ways to Contribute/What We Need Help With (http://pinaxproject.com/pinax/ways_to_contribute/) section. -In case of any questions we recommend you join our Pinax Slack team (http://slack.pinaxproject.com) and ping us there instead of creating an issue on GitHub. Creating issues on GitHub is of course also valid but we are usually able to help you faster if you ping us in Slack. +## Code of Conduct -We also highly recommend reading our Open Source and Self-Care blog post (http://blog.pinaxproject.com/2016/01/19/open-source-and-self-care/). +In order to foster a kind, inclusive, and harassment-free community, the Pinax Project +has a [code of conduct](http://pinaxproject.com/pinax/code_of_conduct/). +We ask you to treat everyone as a smart human programmer that shares an interest in Python, Django, and Pinax with you. -Code of Conduct ----------------- +## Connect with Pinax -In order to foster a kind, inclusive, and harassment-free community, the Pinax Project has a code of conduct, which can be found here http://pinaxproject.com/pinax/code_of_conduct/. We ask you to treat everyone as a smart human programmer that shares an interest in Python, Django, and Pinax with you. +For updates and news regarding the Pinax Project, please follow us on Twitter [@pinaxproject](https://twitter.com/pinaxproject) +and check out our [Pinax Project blog](http://blog.pinaxproject.com). -Pinax Project Blog and Twitter --------------------------------- +## License -For updates and news regarding the Pinax Project, please follow us on Twitter at @pinaxproject and check out our blog http://blog.pinaxproject.com. +Copyright (c) 2012-2018 James Tauber and contributors under the [MIT license](https://opensource.org/licenses/MIT). diff --git a/pinax/templates/models.py b/pinax/templates/models.py deleted file mode 100644 index e69de29..0000000 diff --git a/setup.cfg b/setup.cfg index a722feb..8445cbc 100644 --- a/setup.cfg +++ b/setup.cfg @@ -3,7 +3,3 @@ long_description = file: README.md [bdist_wheel] universal = 1 - -[tool:pytest] -testpaths = pinax/templates/tests -DJANGO_SETTINGS_MODULE = pinax.templates.tests.settings diff --git a/setup.py b/setup.py index 4e93d50..4dca62c 100644 --- a/setup.py +++ b/setup.py @@ -1,38 +1,103 @@ from setuptools import find_packages, setup +VERSION = "1.0.1" +LONG_DESCRIPTION = """ +.. image:: http://pinaxproject.com/pinax-design/patches/pinax-templates.svg + :target: https://pypi.python.org/pypi/pinax-templates/ + +=================== +Pinax Notifications +=================== + +.. image:: https://img.shields.io/pypi/v/pinax-templates.svg + :target: https://pypi.python.org/pypi/pinax-templates/ + +\ + +.. image:: https://img.shields.io/circleci/project/github/pinax/pinax-templates.svg + :target: https://circleci.com/gh/pinax/pinax-templates +.. image:: https://img.shields.io/codecov/c/github/pinax/pinax-templates.svg + :target: https://codecov.io/gh/pinax/pinax-templates +.. image:: https://img.shields.io/github/contributors/pinax/pinax-templates.svg + :target: https://github.com/pinax/pinax-templates/graphs/contributors +.. image:: https://img.shields.io/github/issues-pr/pinax/pinax-templates.svg + :target: https://github.com/pinax/pinax-templates/pulls +.. image:: https://img.shields.io/github/issues-pr-closed/pinax/pinax-templates.svg + :target: https://github.com/pinax/pinax-templates/pulls?q=is%3Apr+is%3Aclosed + +\ + +.. image:: http://slack.pinaxproject.com/badge.svg + :target: http://slack.pinaxproject.com/ +.. image:: https://img.shields.io/badge/license-MIT-blue.svg + :target: https://pypi.python.org/pypi/pinax-templates/ + +\ + +``pinax-templates`` provides semantically-correct templates for use with Pinax apps. + + +Supported Pinax Apps +-------------------- + +* django-user-accounts +* pinax-announcements +* pinax-blog +* pinax-cohorts +* pinax-documents +* pinax-invitations +* pinax-likes +* pinax-notifications +* pinax-strip + + +Supported Django and Python Versions +------------------------------------ + ++-----------------+-----+-----+-----+-----+ +| Django / Python | 2.7 | 3.4 | 3.5 | 3.6 | ++=================+=====+=====+=====+=====+ +| 1.11 | * | * | * | * | ++-----------------+-----+-----+-----+-----+ +| 2.0 | | * | * | * | ++-----------------+-----+-----+-----+-----+ +""" setup( - author="Pinax Developers", - author_email="", + author="Pinax Team", + author_email="team@pinaxprojects.com", description="semantic templates for pinax apps", name="pinax-templates", - version="1.0.0", + long_description=LONG_DESCRIPTION, + version=VERSION, url="http://github.com/pinax/pinax-templates/", license="MIT", - long_description_content_type="text/markdown", packages=find_packages(), include_package_data=True, - test_suite="runtests.runtests", - install_requires=[ - "Django>=1.8", - "django-bootstrap-form>=3.0.0" - ], - tests_require=[ - ], - extras_require={ - "pytest": ["pytest", "pytest-django"] - }, classifiers=[ - "Development Status :: 4 - Beta", + "Development Status :: 5 - Production/Stable", "Environment :: Web Environment", "Framework :: Django", + 'Framework :: Django :: 1.11', + 'Framework :: Django :: 2.0', "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python", - "Programming Language :: Python :: 2", - "Programming Language :: Python :: 3", + 'Programming Language :: Python :: 2', + 'Programming Language :: Python :: 2.7', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.4', + 'Programming Language :: Python :: 3.5', + 'Programming Language :: Python :: 3.6', "Topic :: Software Development :: Libraries :: Python Modules", ], + install_requires=[ + "django>=1.11", + "django-bootstrap-form>=3.0.0" + ], + tests_require=[ + ], + test_suite="runtests.runtests", zip_safe=False ) diff --git a/tox.ini b/tox.ini index 095a4c7..9a56561 100644 --- a/tox.ini +++ b/tox.ini @@ -27,30 +27,24 @@ show_missing = True [tox] envlist = - checkqa - py27-dj{18,110,111}{,-pytest} - py34-dj{18,110,111,20}{,-pytest} - py35-dj{18,110,111,20}{,-pytest} - py36-dj{111,20}{,-pytest} + checkqa, + py27-dj{111} + py34-dj{111,20} + py35-dj{111,20} + py36-dj{111,20} [testenv] passenv = CI CIRCLECI CIRCLE_* deps = coverage codecov - dj18: Django>=1.8,<1.9 - dj110: Django>=1.10,<1.11 - dj111: Django>=1.11a1,<2.0 + dj111: Django>=1.11,<1.12 dj20: Django<2.1 master: https://github.com/django/django/tarball/master -extras = - pytest: pytest + usedevelop = True -setenv = - DJANGO_SETTINGS_MODULE=pinax.templates.tests.settings - pytest: _PINAX_TEST_RUNNER=-m pytest commands = - coverage run {env:_PINAX_TEST_RUNNER:setup.py test} {posargs} + coverage run setup.py test coverage report -m --skip-covered [testenv:checkqa] @@ -60,4 +54,4 @@ commands = deps = flake8 == 3.4.1 flake8-quotes == 0.11.0 - isort == 4.2.15 + isort == 4.2.15 \ No newline at end of file