diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 0000000..7af7362 --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,28 @@ +name: deploy + +on: + push: + tags: + - "v*" + +jobs: + + deploy: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v3 + + - name: Build and Check Package + uses: hynek/build-and-inspect-python-package@v1.5 + + - name: Download Package + uses: actions/download-artifact@v3 + with: + name: Packages + path: dist + + - name: Publish package to PyPI + uses: pypa/gh-action-pypi-publish@master + with: + password: ${{ secrets.pypi_token }} diff --git a/CHANGELOG.rst b/CHANGELOG.rst new file mode 100644 index 0000000..5637b28 --- /dev/null +++ b/CHANGELOG.rst @@ -0,0 +1,2 @@ +Next Release +============ diff --git a/README.rst b/README.rst index ce9d560..727a6d3 100644 --- a/README.rst +++ b/README.rst @@ -421,16 +421,19 @@ delta, and their paths are 0, (2, 2, 1, 0) and (2, 2, 1, 2, 2) respectively (whe 1 item, there is no need to use a tuple). +Releasing +--------- + +See `RELEASING.rst `__. + Maintenance ----------- - Clone or fork the git repo, create a branch - Install `pytest` and `nose` on your system: `python -m pip install pytest nose` -- Modify `nose2pytest/script.py` and `tests/test_script.py` - In root folder, run `pytest` - Once all tests pass, install tox on your system: on Ubuntu, `python -m pip install tox` - Run tox: `tox` -- Increase the package version in setup.cfg and setup.py - Add a python version if latest python is not in `tox.ini` Notes for Ubuntu: diff --git a/RELEASING.rst b/RELEASING.rst new file mode 100644 index 0000000..1b53600 --- /dev/null +++ b/RELEASING.rst @@ -0,0 +1,17 @@ +Here are the steps on how to make a new release. + +1. Create a ``release-VERSION`` branch from ``upstream/master``. +2. Install ``bumpversion`` and execute: + + :: + + bumpversion minor --new-version 1.0.11 + + Changing ``minor`` and ``--new-version`` above accordingly. + +3. Push a branch with the changes. +4. Once all builds pass and at least another maintainer approves, push a tag to ``upstream`` in the format ``v1.0.11`. + This will deploy to PyPI. +5. Merge the PR (do not squash, to keep the tag). +6. Create a new release on GitHub, posting the contents of the current CHANGELOG. +7. Open a new PR clearing the ``CHANGELOG.md`` file. diff --git a/nose2pytest/script.py b/nose2pytest/script.py index a26a1f7..fa6576e 100644 --- a/nose2pytest/script.py +++ b/nose2pytest/script.py @@ -25,7 +25,7 @@ from lib2to3.fixer_util import parenthesize -__version__ = "1.0.9" +__version__ = "1.0.10" log = logging.getLogger('nose2pytest') diff --git a/setup.cfg b/setup.cfg index 62d00a7..770e0ad 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,4 +1,3 @@ [bumpversion] -current_version = 1.0.10 -files = setup.py README.rst nose2pytest/script.py +files = setup.py nose2pytest/script.py