From 28bd0db94109bca3db29131d28d06ce5562d78c4 Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Sat, 27 Nov 2021 08:53:06 -0600 Subject: [PATCH 1/2] prep for jupyter releaser usage --- .github/workflows/check-release.yml | 29 +++++++++++++++++++++++++++++ .github/workflows/enforce-label.yml | 11 +++++++++++ CHANGELOG.md | 22 ++++++++++++++++++++++ jupyter_kernel_test/__init__.py | 2 +- pyproject.toml | 17 +++++++++++++++++ 5 files changed, 80 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/check-release.yml create mode 100644 .github/workflows/enforce-label.yml create mode 100644 CHANGELOG.md diff --git a/.github/workflows/check-release.yml b/.github/workflows/check-release.yml new file mode 100644 index 0000000..1aa7c97 --- /dev/null +++ b/.github/workflows/check-release.yml @@ -0,0 +1,29 @@ +name: Check Release +on: + push: + branches: ["master"] + pull_request: + branches: ["*"] + +jobs: + check_release: + runs-on: ubuntu-latest + strategy: + matrix: + group: [check_release, link_check] + steps: + - name: Checkout + uses: actions/checkout@v2 + - name: Base Setup + uses: jupyterlab/maintainer-tools/.github/actions/base-setup@v1 + - name: Install Dependencies + run: | + pip install -e . + - name: Check Release + if: ${{ matrix.group == 'check_release' }} + uses: jupyter-server/jupyter_releaser/.github/actions/check-release@v1 + with: + token: ${{ secrets.GITHUB_TOKEN }} + - name: Run Link Check + if: ${{ matrix.group == 'link_check' }} + uses: jupyter-server/jupyter_releaser/.github/actions/check-links@v1 diff --git a/.github/workflows/enforce-label.yml b/.github/workflows/enforce-label.yml new file mode 100644 index 0000000..354a046 --- /dev/null +++ b/.github/workflows/enforce-label.yml @@ -0,0 +1,11 @@ +name: Enforce PR label + +on: + pull_request: + types: [labeled, unlabeled, opened, edited, synchronize] +jobs: + enforce-label: + runs-on: ubuntu-latest + steps: + - name: enforce-triage-label + uses: jupyterlab/maintainer-tools/.github/actions/enforce-label@v1 diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000..d8381d4 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,22 @@ +# Changelog + + + +## 0.3 + +([Full Changelog](https://github.com/jupyter/jupyter_kernel_test/compare/7283c8c...309feed)) + +### Merged PRs + +- Add stop_on_error [#32](https://github.com/jupyter/jupyter_kernel_test/pull/32) ([@shzhng](https://github.com/shzhng)) +- Update README.rst [#29](https://github.com/jupyter/jupyter_kernel_test/pull/29) ([@maveme](https://github.com/maveme)) +- Made stdout/stderr tests less order dependent. [#28](https://github.com/jupyter/jupyter_kernel_test/pull/28) ([@mariusvniekerk](https://github.com/mariusvniekerk)) +- Convert readthedocs links for their .org -> .io migration for hosted projects [#26](https://github.com/jupyter/jupyter_kernel_test/pull/26) ([@adamchainz](https://github.com/adamchainz)) + +### Contributors to this release + +([GitHub contributors page for this release](https://github.com/jupyter/jupyter_kernel_test/graphs/contributors?from=2016-06-13&to=2017-04-28&type=c)) + +[@adamchainz](https://github.com/search?q=repo%3Ajupyter%2Fjupyter_kernel_test+involves%3Aadamchainz+updated%3A2016-06-13..2017-04-28&type=Issues) | [@mariusvniekerk](https://github.com/search?q=repo%3Ajupyter%2Fjupyter_kernel_test+involves%3Amariusvniekerk+updated%3A2016-06-13..2017-04-28&type=Issues) | [@maveme](https://github.com/search?q=repo%3Ajupyter%2Fjupyter_kernel_test+involves%3Amaveme+updated%3A2016-06-13..2017-04-28&type=Issues) | [@shzhng](https://github.com/search?q=repo%3Ajupyter%2Fjupyter_kernel_test+involves%3Ashzhng+updated%3A2016-06-13..2017-04-28&type=Issues) | [@takluyver](https://github.com/search?q=repo%3Ajupyter%2Fjupyter_kernel_test+involves%3Atakluyver+updated%3A2016-06-13..2017-04-28&type=Issues) + + diff --git a/jupyter_kernel_test/__init__.py b/jupyter_kernel_test/__init__.py index 3ac7114..6fc99fc 100644 --- a/jupyter_kernel_test/__init__.py +++ b/jupyter_kernel_test/__init__.py @@ -12,7 +12,7 @@ TIMEOUT = 15 -__version__ = '0.3' +__version__ = '0.3.0' class KernelTests(TestCase): kernel_name = "" diff --git a/pyproject.toml b/pyproject.toml index 41bb763..9a886f8 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,20 @@ [build-system] requires = ["setuptools", "jupyter_client", "jsonschema"] build-backend = "setuptools.build_meta" + +[tool.jupyter-releaser] +skip = ["check-links"] + +[tool.tbump.version] +current = "0.3.0" +regex = ''' + (?P\d+)\.(?P\d+)\.(?P\d+) + ((?Pa|b|rc|.dev)(?P\d+))? +''' + +[tool.tbump.git] +message_template = "Bump to {new_version}" +tag_template = "v{new_version}" + +[[tool.tbump.file]] +src = "jupyter_kernel_test/__init__.py" From 982109028cdf580f8a8171b98ba334908acbae5c Mon Sep 17 00:00:00 2001 From: Steven Silvester Date: Sat, 27 Nov 2021 08:57:07 -0600 Subject: [PATCH 2/2] add release instructions and fix manifest --- MANIFEST.in | 1 + RELEASE.md | 25 +++++++++++++++++++++++++ 2 files changed, 26 insertions(+) create mode 100644 RELEASE.md diff --git a/MANIFEST.in b/MANIFEST.in index 6c9e6b4..92b06ea 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1 +1,2 @@ include *.py +include *.md diff --git a/RELEASE.md b/RELEASE.md new file mode 100644 index 0000000..2f39545 --- /dev/null +++ b/RELEASE.md @@ -0,0 +1,25 @@ +# Release Guide + +## Using `jupyter_releaser` + +The recommended way to make a release is to use [`jupyter_releaser`](https://github.com/jupyter-server/jupyter_releaser#checklist-for-adoption). + +## Manual Release + +- Update `CHANGELOG` + +- Run the following: + +```bash +export VERSION= +pip install jupyter_releaser +tbump --only-patch $VERSION +git commit -a -m "Release $VERSION" +git tag $VERSION; true; +git push --all +git push --tags +rm -rf dist build +python -m build . +twine check dist/* +twine upload dist/* +```