From 5087916a0324eb016c17a3496324a46ab9604fa1 Mon Sep 17 00:00:00 2001 From: Benjamin Bach Date: Fri, 19 Aug 2022 17:46:30 +0200 Subject: Do not bump the version in auto-maintained file package-lock.json --- docs/contributing.rst | 6 ++++-- setup.cfg | 4 ---- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/docs/contributing.rst b/docs/contributing.rst index 9eedb03..f4ed282 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -184,8 +184,10 @@ To release a new version of the theme, core team will take the following steps: #. Update the changelog (``docs/changelog.rst``) with the version information. #. Run ``python setup.py update_translations`` to compile new translation files and update Transifex. -#. Run ``python setup.py build_assets`` to rebuild all the theme assets and the Python - package. +#. Run ``npm run build`` to rebuild all the theme assets and the Python + package, notice that ``package-lock.json`` will be updated with a new package + version. But take care that it isn't also bumping versions of dependencies + in ways that are risky to the release. #. Commit these changes. #. Tag the release in git: ``git tag $NEW_VERSION``. #. Push the tag to GitHub: ``git push --tags origin``. diff --git a/setup.cfg b/setup.cfg index d105f7c..cd69fbe 100644 --- a/setup.cfg +++ b/setup.cfg @@ -49,10 +49,6 @@ first_value = 1 search = "version": "{current_version}", replace = "version": "{new_version}", -[bumpversion:file:package-lock.json] -search = "version": "{current_version}", -replace = "version": "{new_version}", - [bumpversion:file:docs/changelog.rst] search = .. |development_version| replace:: {current_version} replace = .. |development_version| replace:: {new_version} -- cgit v1.2.3 From 8e65b61666f0502121a49588502c722a5e2929c2 Mon Sep 17 00:00:00 2001 From: Benjamin Bach Date: Fri, 19 Aug 2022 22:23:32 +0200 Subject: Adds wheel and a command to package bdist_wheel + sdist --- docs/contributing.rst | 2 +- setup.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/contributing.rst b/docs/contributing.rst index f4ed282..17d9945 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -184,7 +184,7 @@ To release a new version of the theme, core team will take the following steps: #. Update the changelog (``docs/changelog.rst``) with the version information. #. Run ``python setup.py update_translations`` to compile new translation files and update Transifex. -#. Run ``npm run build`` to rebuild all the theme assets and the Python +#. Run ``npm run build && python setup.py bdist_wheel sdist`` to rebuild all the theme assets and the Python package, notice that ``package-lock.json`` will be updated with a new package version. But take care that it isn't also bumping versions of dependencies in ways that are risky to the release. diff --git a/setup.py b/setup.py index 15d371d..40fd95c 100644 --- a/setup.py +++ b/setup.py @@ -130,6 +130,7 @@ setup( 'transifex-client', 'sphinxcontrib-httpdomain', 'bump2version', + 'wheel', ], }, classifiers=[ -- cgit v1.2.3 From e8440401010d146cbd32ade6184d19dc2d6241ba Mon Sep 17 00:00:00 2001 From: Benjamin Bach Date: Fri, 19 Aug 2022 22:38:22 +0200 Subject: Build everything one step at a time --- docs/contributing.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/contributing.rst b/docs/contributing.rst index 17d9945..e95c771 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -184,7 +184,7 @@ To release a new version of the theme, core team will take the following steps: #. Update the changelog (``docs/changelog.rst``) with the version information. #. Run ``python setup.py update_translations`` to compile new translation files and update Transifex. -#. Run ``npm run build && python setup.py bdist_wheel sdist`` to rebuild all the theme assets and the Python +#. Run ``npm install && npm run build && python setup.py bdist_wheel sdist`` to rebuild all the theme assets and the Python package, notice that ``package-lock.json`` will be updated with a new package version. But take care that it isn't also bumping versions of dependencies in ways that are risky to the release. -- cgit v1.2.3 From 8e737d4c84f43849ae0b9701dc5a8f735ed2f4bd Mon Sep 17 00:00:00 2001 From: Benjamin Bach Date: Fri, 19 Aug 2022 22:45:19 +0200 Subject: Make note about releasing `package-lock.json` --- docs/contributing.rst | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/contributing.rst b/docs/contributing.rst index e95c771..f94bc46 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -187,7 +187,8 @@ To release a new version of the theme, core team will take the following steps: #. Run ``npm install && npm run build && python setup.py bdist_wheel sdist`` to rebuild all the theme assets and the Python package, notice that ``package-lock.json`` will be updated with a new package version. But take care that it isn't also bumping versions of dependencies - in ways that are risky to the release. + in ways that are risky to the release. *If* ``package-lock.json`` changes, you + need to commit it to git and tag it together with your release. #. Commit these changes. #. Tag the release in git: ``git tag $NEW_VERSION``. #. Push the tag to GitHub: ``git push --tags origin``. -- cgit v1.2.3 From 7c43f45c9bb24611a60747e443985db791d4e85d Mon Sep 17 00:00:00 2001 From: Benjamin Bach Date: Fri, 19 Aug 2022 22:50:49 +0200 Subject: Do not build the python package in this step --- docs/contributing.rst | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/contributing.rst b/docs/contributing.rst index f94bc46..e3366bf 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -184,8 +184,8 @@ To release a new version of the theme, core team will take the following steps: #. Update the changelog (``docs/changelog.rst``) with the version information. #. Run ``python setup.py update_translations`` to compile new translation files and update Transifex. -#. Run ``npm install && npm run build && python setup.py bdist_wheel sdist`` to rebuild all the theme assets and the Python - package, notice that ``package-lock.json`` will be updated with a new package +#. Run ``npm install && npm run build`` to rebuild all the theme assets, + notice that ``package-lock.json`` will be updated with a new package version. But take care that it isn't also bumping versions of dependencies in ways that are risky to the release. *If* ``package-lock.json`` changes, you need to commit it to git and tag it together with your release. -- cgit v1.2.3