Skip to content

Commit 6be2dc9

Browse files
committed
Simplify RELEASE.md with npm version
Using npm version is a little simpler and more natural for a javascript project than bump2version.
1 parent b85eeb1 commit 6be2dc9

File tree

4 files changed

+19
-44
lines changed

4 files changed

+19
-44
lines changed

.bumpversion.cfg

-18
This file was deleted.

.npmrc

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
tag-version-prefix=

RELEASE.md

+17-25
Original file line numberDiff line numberDiff line change
@@ -13,69 +13,61 @@ meet the prerequisites:
1313

1414
- To have push rights to the [configurable-http-proxy GitHub
1515
repository](https://github.com/jupyterhub/configurable-http-proxy).
16-
- To have [`bump2version`](https://github.com/c4urself/bump2version) installed
17-
(`pip install bump2version`).
16+
- To have [Node.js](https://nodejs.org) installed.
1817

1918
## Steps to make a release
2019

2120
1. Update [CHANGELOG.md](CHANGELOG.md) if it is not up to date, and verify
2221
[README.md](README.md) has an updated output of running `--help`. Make a PR
2322
to review the CHANGELOG notes.
2423

25-
1. Once the changelog is up to date, checkout main and make sure it is up to
24+
1. Once the changelog is up to date, checkout the main branch and make sure it is up to
2625
date and clean.
2726

2827
```bash
2928
ORIGIN=${ORIGIN:-origin} # set to the canonical remote, e.g. 'upstream' if 'origin' is not the official repo
3029
git checkout main
31-
git fetch $ORIGIN main
32-
git reset --hard $ORIGIN/main
33-
# WARNING! This next command deletes any untracked files in the repo
34-
git clean -xfd
30+
git branch --set-upstream-to=$ORIGIN/main main
31+
git pull
3532
```
3633

37-
1. Update the version with `bump2version` to not include the -dev suffix and let
38-
it make a git commit and tag as well for us.
34+
1. Update the version with [`npm version`](https://docs.npmjs.com/cli/v6/commands/npm-version)
35+
and let it make a git commit and tag as well for us.
3936

4037
```bash
41-
# optionally first bump a minor or major version, but
42-
# don't bump the patch version, that's already done.
43-
# bump2version --no-commit minor
44-
# bump2version --no-commit major
45-
bump2version --tag release
38+
# specify the new version here,
39+
# which should already have been chosen when updating the changelog.
40+
npm version 1.2.3
4641

4742
# verify changes
4843
git diff HEAD~1
4944
```
5045

51-
1. Reset the version to the next development version with `bump2version`.
46+
1. Reset the version to the next development version with `npm version`,
47+
without creating a tag:
5248

5349
```bash
54-
bump2version --no-tag patch
50+
npm version --no-git-tag-version prerelease --preid=dev
5551

5652
# verify changes
5753
git diff HEAD~1
5854
```
5955

60-
1. Push your release related commits to main along with the annotated tags
61-
referencing commits on the main branch.
56+
1. Push your new tag and commits to GitHub.
6257

63-
```
58+
```bash
6459
git push --follow-tags $ORIGIN main
6560
```
6661

67-
1. Visit [GitHub: create new
68-
release](https://github.com/jupyterhub/configurable-http-proxy/releases/new)
69-
and reference your tag.
70-
71-
This will trigger a workflow to publish the NPM package.
72-
7362
1. Verify [the automated
7463
workflow](https://github.com/jupyterhub/configurable-http-proxy/actions?query=workflow%3A%22Publish+to+npm%22)
7564
succeeded.
7665

7766
## Manual release to npm
7867

68+
A manual release should not generally be required,
69+
but might be needed in the event of a problem in the automated publishing workflow.
70+
7971
1. Verify you are a collaborator of the [npmjs
8072
project](https://www.npmjs.com/package/configurable-http-proxy).
8173

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "4.3.2-dev",
2+
"version": "4.2.4-dev",
33
"name": "configurable-http-proxy",
44
"description": "A configurable-on-the-fly HTTP Proxy",
55
"author": "Jupyter Developers",

0 commit comments

Comments
 (0)