Skip to content

Commit

Permalink
Add pyproject.toml file and AutoPub support
Browse files Browse the repository at this point in the history
Contributors will henceforth be asked to include a `RELEASE.md` file
containing the release type (major, minor, patch) and a summary of the
changes in the pull request. This information will be used by the
continuous integration (CI) system to automatically publish a new
release to PyPI when the pull request is merged.

For more details, see: https://github.com/autopub/autopub
  • Loading branch information
justinmayer committed Jul 28, 2019
1 parent faee0ba commit 652d340
Show file tree
Hide file tree
Showing 6 changed files with 52 additions and 6 deletions.
22 changes: 22 additions & 0 deletions .travis.yml
Expand Up @@ -17,6 +17,28 @@ script:
coverage run --source=autoslug run_tests.py
after_success:
coveralls
before_deploy:
- 'if [ "$TRAVIS_PULL_REQUEST" != "false" ]; then travis_terminate 0; fi'
- pip install githubrelease
- pip install --pre autopub
- autopub check || travis_terminate 0
- pip install poetry
- pip install twine
- git checkout ${TRAVIS_BRANCH}
- git remote set-url origin https://$GITHUB_TOKEN@github.com/$TRAVIS_REPO_SLUG
deploy:
provider: script
script: autopub deploy
skip_cleanup: true
on:
branch: master
notifications:
email:
- entrop+travis@gmail.com
env:
global:
- PYPI_USERNAME=autopub
- secure: "h/uaj7XZfr9jiAqtSHNuX9Zt9YaSLD2Z0t6dxzdeKRiTe+AHdFORfO1zhqr10g8qAXhwZcD5G/tl8X2qJ+GI4eG3mLUoVL0JuNkV/EW+y5nclfDSFg9naT/soHk7AZ63EG8125B+XIQdiUT4ZY0DeMVujZjV9c/eztIwU8J/jiaLjmELcuJkV8xjcFMH5qzvX4mWeNehUuNdGj2KPCE1Pm19HeXQPavEv3oWWUk2Lx69OJJTllevhnlpg3C0kMrOCvoMNGJk/CVoumBv7HkRAegtjXg0an09B47nAnmDaoyqB5FGPSvI5b+C6OhI+z2wMFFP7FEqKVNhwojFkX4WKU7pak7P5xMkFhH7sm5ggX1gYOthZGrBwKnQV3rCLVq2JZnWeAMmzAKGcOEHc1OU5ArzdmhlXfjAgJEiGmKMKnGGTyHE4rZPgTT0UreevB+0cpfsWj223bCU8xxvM+ckIXeWJ/q7WmuOB+Je6cpIuHSDOgD9F7PVH+fD+l/26Fn35OAg+0TE/dF6fm8M6N18YxdQHgQuiCHpn9Czm49Lqh5YuaXEvOUT3ZFaD3U6YFeDlqofPoP4VjuANL1NC0tJPzguwFM8lXskqezC3snR8sdKsOJVSAeOaEFjWMPN8YQVYWoM9seV/tQavupXCzUQLCeUnsrxRR4yTtcTPsD9sPQ="
- secure: "NEDBJi/MUb4z4hCyVGEVtgPmilOap+ym6Md1HHxpAE+iaQpO6DpugSjh9XC2t3JT2MqTLiAU66mbcvgVjExC6HLA0W/eigRpHr4q4Md1aEenelNP+G+JJdw1xlGY930GX3U058v9+gujJNKtwADnejkrPc5SAPLcNgcOQD8BM8A+XGQaby2QHr4TCq9KakZaR5wBIdQlVoqvkcz7SteVD3eGy/PEk8ZwXI+caRgeDZQ+d1IZGuDwId6PllDUbnzb3hKgN42IvwBr/bAQq8itzUZl/sR7ZnDGsE4xUXqu6Pk1IYpnsdiK+B65jpZ7CLozc2vdZKdu5mq2Br7iFCjUsP5xGLd3f+K2sLT2Mnrd0j6Lbf1+3iFHf6fPg5k0HRzntFqxZs/TesxALy7RvmK70EFyhpLhc8rYytZgMln32+2YAnauPQliUElLQ1vtfTta6Tr2k1gNTEpGRPPrALNJwgXRCYfal18LpXN26PGzBVHVM1IEoHnOHxEB440486im+h8BSnydMYZ56T3F6rFPWE5qBV9V/aKOSJnTCIjkvBQeI3O03deSGLTWnhHMyOh6T4T+3INLliW6if3//QQ/20JGK9TDzIrpVnUBmveIMFmNu0HXV1Yg0REQwZKVGZ2D95S0Zhj2mijKkSG4Dru2kzVHVkyoHaFCvPUoPPNh+is="
- TWINE_USERNAME=$PYPI_USERNAME
- TWINE_PASSWORD=$PYPI_PASSWORD
3 changes: 0 additions & 3 deletions CHANGELOG.rst
@@ -1,9 +1,6 @@
Changelog
~~~~~~~~~

Next release
-------------

Version 1.9.4
-------------

Expand Down
10 changes: 9 additions & 1 deletion CONTRIBUTING.rst
Expand Up @@ -22,4 +22,12 @@ your contribution is reviewed and accepted ASAP.

4. Add documentation (comments, docstrings, hints for users).

5. Submit a pull request. Reference the original issue there.
5. Add a ``RELEASE.md`` file in the root of the project that contains the
release type (major, minor, patch) and a summary of the changes that will be
used as the release changelog entry. For example::

Release type: patch

Add pyproject.toml to MANIFEST.in

6. Submit a pull request. Reference the original issue there.
2 changes: 1 addition & 1 deletion MANIFEST.in
@@ -1,5 +1,5 @@
include *.rst
include setup.py _version_helper.py
include pyproject.toml setup.py _version_helper.py
recursive-include autoslug *.py
recursive-include docs *
recursive-exclude docs *.pyc
Expand Down
2 changes: 1 addition & 1 deletion autoslug/__init__.py
Expand Up @@ -12,5 +12,5 @@
from autoslug.fields import AutoSlugField


__version__ = '1.9.5.dev0'
__version__ = '1.9.4'
__all__ = ['AutoSlugField']
19 changes: 19 additions & 0 deletions pyproject.toml
@@ -0,0 +1,19 @@
[tool.poetry]
name = "django-autoslug"
version = "1.9.4"
description = "AutoSlugField for Django"
authors = ["Justin Mayer <entroP@gmail.com>"]
readme = "README.rst"
license = "LGPL-3.0"
keywords = ["django", "model"]

[tool.autopub]
project-name = "django-autoslug"
git-username = "botpub"
git-email = "botpub@autopub.rocks"
changelog-file = "CHANGELOG.rst"
changelog-header = "~~~~~~~~~"
version-strings = ["autoslug/__init__.py"]

[build-system]
requires = ["setuptools >= 40.6.0", "wheel"]

0 comments on commit 652d340

Please sign in to comment.