Skip to content

Commit

Permalink
Add RELEASING.md closes #18
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewbalvanz-wf committed May 31, 2017
1 parent 3f61c91 commit 66cf151
Show file tree
Hide file tree
Showing 5 changed files with 59 additions and 23 deletions.
28 changes: 28 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
### v0.4.0
* 8bec271 - Setup Travis CI to publish to PyPi (Matthew Balvanz, Wed May 24 16:51:05 2017 -0500)
* d67a015 - Merge pull request #14 from pact-foundation/verify-pacts (Matthew Balvanz, Wed May 24 16:46:49 2017 -0500)
* 78bd029 - Add CONTRIBUTING.md file resolves #4 (Matthew Balvanz, Mon May 22 20:41:09 2017 -0500)
* d7c32c4 - Repository badges (Matthew Balvanz, Mon May 22 20:22:14 2017 -0500)
* 97122f1 - Merge pull request #13 from pact-foundation/update-developer-documentation (Matthew Balvanz, Sat May 20 20:55:06 2017 -0500)
* ea015eb - Increment project to v0.4.0 (Matthew Balvanz, Fri May 19 23:46:00 2017 -0500)
* 51eb338 - Command line application for verifying pacts (Matthew Balvanz, Fri May 19 22:24:06 2017 -0500)
* 4b0bbd7 - Update the developer instructions (Matthew Balvanz, Fri May 19 22:05:54 2017 -0500)

### v0.3.0
* 3130f9a - Merge pull request #11 from pact-foundation/update-mock-service (Matthew Balvanz, Sun May 14 09:03:43 2017 -0500)
* 9b20d36 - Updated Versions of Pact Ruby applications (Matthew Balvanz, Sat May 13 09:43:44 2017 -0500)

### v0.2.0
* 140f583 - Merge pull request #8 from pact-foundation/manage-mock-service (Matthew Balvanz, Sat May 13 09:18:40 2017 -0500)
* 5994c3a - pact-python manages the mock service for the user (Matthew Balvanz, Tue May 9 21:58:08 2017 -0500)
* 4bf7b8b - pact-python manages the mock service for the user (Matthew Balvanz, Mon May 1 20:12:53 2017 -0500)
* 0a278af - pact-python manages the mock service for the user (Matthew Balvanz, Tue Apr 18 21:23:18 2017 -0500)
* fd68b41 - Merge pull request #2 from pact-foundation/package-ruby-apps (Matthew Balvanz, Sat Apr 22 10:55:48 2017 -0500)
* 75a96dc - Package the Ruby Mock Service and Verifier (Matthew Balvanz, Tue Apr 4 23:14:11 2017 -0500)

### v0.1.0
* 189c647 - Merge pull request #3 from pact-foundation/travis-ci (Jose Salvatierra, Fri Apr 7 21:40:02 2017 +0100)
* 559efb8 - Add Travis CI build (Matthew Balvanz, Fri Apr 7 11:12:01 2017 -0500)
* 8f074a0 - Merge pull request #1 from pact-foundation/initial-framework (Matthew Balvanz, Fri Apr 7 09:55:34 2017 -0500)
* f5caf9c - Initial pact-python implementation (Matthew Balvanz, Mon Apr 3 09:16:59 2017 -0500)
* bfb8380 - Initial pact-python implementation (Matthew Balvanz, Thu Mar 30 20:41:05 2017 -0500)
4 changes: 0 additions & 4 deletions CHANGES.txt

This file was deleted.

11 changes: 0 additions & 11 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,5 @@
DOCS_DIR := ./docs

define VERSION_CHECK
import setup
import pact
msg = 'pact.__version__ must match the last version in CHANGES.txt'
assert setup.get_version() == pact.__version__, msg
endef


help:
@echo ""
Expand Down Expand Up @@ -71,12 +64,8 @@ pact/bin:
scripts/build.sh


export VERSION_CHECK
.PHONY: test
test: deps pact/bin
@echo "Checking version consistency..."
python -c "$$VERSION_CHECK"

flake8
pydocstyle pact
coverage erase
Expand Down
28 changes: 28 additions & 0 deletions RELEASING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Releasing

1. Increment the version according to semantic versioning rules in `pact/__init__.py`

2. To upgrade the the versions of `pact-mock_service` and `pact-provider-verifier`, change the
appropriate `GEM_VESRION` variable in `scripts/build.sh` to the new version.

3. Update the `CHANGELOG.md` using:

$ git log --pretty=format:' * %h - %s (%an, %ad)' vX.Y.Z..HEAD

4. Add files to git

$ git add CHANGELOG.md pact/__init__.py

5. Commit

$ git commit -m "Releasing version X.Y.Z"

6. Tag

$ git tag -a vX.Y.Z -m "Releasing version X.Y.Z" && git push origin --tags

7. Wait until travis has run and the new tag is available at https://github.com/pact-foundation/pact-python/releases/tag/vX.Y.Z

8. Set the title to `pact-python-X.Y.Z`

9. Save
11 changes: 3 additions & 8 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
from setuptools import setup
from setuptools.command.install import install

import pact


class PactPythonInstallCommand(install):
"""
Expand Down Expand Up @@ -67,13 +69,6 @@ def verifier(self, bin_path):
f.extractall(os.path.join(bin_path, 'verifier'))


def get_version():
"""Return latest version noted in CHANGES.txt."""
lastline = [line for line in read('CHANGES.txt').split('\n') if line][-1]
version = lastline.split(',')[0]
return version[1:]


def read(filename):
"""Read file contents."""
path = os.path.realpath(os.path.join(os.path.dirname(__file__), filename))
Expand All @@ -89,7 +84,7 @@ def read(filename):
setup_args = dict(
cmdclass={'install': PactPythonInstallCommand},
name='pact-python',
version=get_version(),
version=pact.__version__,
description=('Tools for creating and verifying consumer driven contracts'
' using the Pact framework.'),
long_description=read('README.md'),
Expand Down

0 comments on commit 66cf151

Please sign in to comment.