Updates #3207 - Generate po files in the release checkout

Refactor the Makefile somewhat.

- Rename `make release` to `make version`
- Add `make release-checkout` which checks out the release branch
This commit is contained in:
JC Brand 2023-06-29 09:48:30 +02:00
parent ae518aa2c3
commit bc7621c25d
3 changed files with 27 additions and 23 deletions

View File

@ -2,7 +2,9 @@
## 10.1.5 (Unreleased)
- #3209: Fix error when importing the `converse` global with bootstrap modal API.
- #3209: Fix error when importing the `converse` global with bootstrap modal API
- #3207: `.po` translation files weren't included in previous release
- Updated Galician and Portuguese translations
## 10.1.4 (2023-06-25)

View File

@ -65,9 +65,6 @@ certs:
########################################################################
## Translation machinery
dist/converse-no-dependencies.js: src webpack/webpack.common.js webpack/webpack.nodeps.js @converse/headless node_modules
npm run nodeps
GETTEXT = $(XGETTEXT) --from-code=UTF-8 --language=JavaScript --keyword=__ --keyword=___ --keyword=i18n_ --force-po --output=src/i18n/converse.pot --package-name=Converse.js --copyright-holder="Jan-Carel Brand" --package-version=10.1.4 dist/converse-no-dependencies.js -c
src/i18n/converse.pot: dist/converse-no-dependencies.js
@ -85,10 +82,8 @@ po:
########################################################################
## Release management
.PHONY: release
release:
rm -rf release && mkdir release
cd release
.PHONY: version
version:
$(SED) -i '/^export const VERSION_NAME =/s/=.*/= "v$(VERSION)";/' src/headless/shared/constants.js
$(SED) -i '/Version:/s/:.*/: $(VERSION)/' COPYRIGHT
$(SED) -i '/Project-Id-Version:/s/:.*/: Converse.js $(VERSION)\n"/' src/i18n/converse.pot
@ -105,14 +100,18 @@ release:
make po
make dist
release-checkout:
git clone git@github.com:conversejs/converse.js.git --depth 1 --branch $(BRANCH) release-$(BRANCH)
cd release-$(BRANCH) && make dist
.PHONY: publish
publish:
git clone git@github.com:conversejs/converse.js.git --depth 1 --branch $(BRANCH) release/
cd release && make dist && npm pack && npm publish
cd release/src/headless && npm pack && npm publish
find ./release/ -name "converse.js-*.tgz" -exec mv {} . \;
find ./release/src/headless -name "converse-headless-*.tgz" -exec mv {} . \;
rm -rf release
make release-checkout
cd release-$(BRANCH) && npm pack && npm publish
cd release-$(BRANCH)/src/headless && npm pack && npm publish
find ./release-$(BRANCH)/ -name "converse.js-*.tgz" -exec mv {} . \;
find ./release-$(BRANCH)/src/headless -name "converse-headless-*.tgz" -exec mv {} . \;
rm -rf release-$(BRANCH)
.PHONY: postrelease
postrelease:
@ -157,6 +156,9 @@ devserver: node_modules
########################################################################
## Builds
dist/converse-no-dependencies.js: src webpack/webpack.common.js webpack/webpack.nodeps.js @converse/headless node_modules
npm run nodeps
dist/converse.js:: node_modules
npm run build
@ -201,7 +203,7 @@ src/headless/dist/converse-headless.js: src webpack/webpack.common.js node_modul
src/headless/dist/converse-headless.min.js: src webpack/webpack.common.js node_modules @converse/headless
npm run headless
dist:: node_modules src/* | dist/website.css dist/website.min.css
dist:: node_modules src/* | dist/website.css dist/website.min.css dist/converse-no-dependencies.js
npm run headless
npm run build

View File

@ -1,18 +1,18 @@
# Release checklist
1. Check that weblate translations are all merged in
1. Merge weblate translations: https://hosted.weblate.org/projects/conversejs/translations/#repository
2. Run `make check` to check that all tests pass.
3. Run `make release VERSION=10.1.4`
3. Run `make version VERSION=10.1.5`
4. Do a `git diff` to check if things look sane.
5. Do a quick manual test with the `dist` files (via `index.html`)
6. `git commit -am "Release 10.1.4"`
7. `git tag -s v10.1.4 -m "Release 10.1.4"`
8. `git push && git push origin v10.1.4`
9. `make publish BRANCH=v10.1.4`
6. `git commit -am "Release 10.1.5"`
7. `git tag -s v10.1.5 -m "Release 10.1.4"`
8. `git push && git push origin v10.1.5`
9. `make publish BRANCH=v10.1.5`
10. Update release page on Github
* Upload tar files
11. Update https://conversejs.org
* `cd /home/conversejs/converse.js`
* `make deploy VERSION=10.1.4`
* `make deploy VERSION=10.1.5`
12. Update the repository on weblate
13. Decide on next release number and run `make postrelease VERSION=10.1.5`
13. Decide on next release number and run `make postrelease VERSION=10.1.6`