From 8aa6c38a093839ef091af5205c0bac40152eaec6 Mon Sep 17 00:00:00 2001 From: Mike Bender Date: Mon, 13 Jan 2025 16:17:34 -0500 Subject: [PATCH] build: Update the changelogPreset to use conventionalcommits, allow release branches to bump versions (#1081) - Allow release branches to bump versions - we need this for hotfix branches, and already have it on the ui-v0.15 branch: 2803feae22dce73a6fe38fdb85a8a07b4f35cc79 - Need to update template to the correct format. Already did this on the `release/ui-v0.15` branch: #570 - Take note there are still some issues to beware of when bumping a release branch: https://github.com/deephaven/deephaven-plugins/issues/557 --- cog.toml | 2 +- lerna.json | 7 ++++++- package-lock.json | 22 ++++++++++++++++++++++ package.json | 1 + 4 files changed, 30 insertions(+), 2 deletions(-) diff --git a/cog.toml b/cog.toml index 7975d8797..8d51064d4 100644 --- a/cog.toml +++ b/cog.toml @@ -4,7 +4,7 @@ disable_changelog = false # we never tag any code outside the plugins/ directory. Everything else is build glue. generate_mono_repository_global_tag = false # limit which branches to perform bumps from -branch_whitelist = [ "main" ] +branch_whitelist = [ "main", "release/*" ] # we don't really use [skip ci] action filtering, but leaving here in case we decide to someday skip_ci = "[skip ci]" skip_untracked = false diff --git a/lerna.json b/lerna.json index 00e1ac584..50caeec0c 100644 --- a/lerna.json +++ b/lerna.json @@ -3,5 +3,10 @@ "useWorkspaces": true, "useNx": false, "version": "independent", - "packages": ["plugins/*/src/js/"] + "packages": ["plugins/*/src/js/"], + "command": { + "version": { + "changelogPreset": "conventionalcommits" + } + } } diff --git a/package-lock.json b/package-lock.json index d2252d2cd..8a8e36991 100644 --- a/package-lock.json +++ b/package-lock.json @@ -24,6 +24,7 @@ "@types/node": "^20.11.17", "@types/prop-types": "^15.7.10", "@vitejs/plugin-react-swc": "^3.7.0", + "conventional-changelog-conventionalcommits": "^7.0.0", "eslint": "^8.37.0", "identity-obj-proxy": "^3.0.0", "jest": "^29.6.2", @@ -13483,6 +13484,18 @@ "node": ">=10" } }, + "node_modules/conventional-changelog-conventionalcommits": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/conventional-changelog-conventionalcommits/-/conventional-changelog-conventionalcommits-7.0.2.tgz", + "integrity": "sha512-NKXYmMR/Hr1DevQegFB4MwfM5Vv0m4UIxKZTTYuD98lpTknaZlSRrDOG4X7wIXpGkfsYxZTghUN+Qq+T0YQI7w==", + "dev": true, + "dependencies": { + "compare-func": "^2.0.0" + }, + "engines": { + "node": ">=16" + } + }, "node_modules/conventional-changelog-core": { "version": "4.2.4", "dev": true, @@ -163184,6 +163197,15 @@ "q": "^1.5.1" } }, + "conventional-changelog-conventionalcommits": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/conventional-changelog-conventionalcommits/-/conventional-changelog-conventionalcommits-7.0.2.tgz", + "integrity": "sha512-NKXYmMR/Hr1DevQegFB4MwfM5Vv0m4UIxKZTTYuD98lpTknaZlSRrDOG4X7wIXpGkfsYxZTghUN+Qq+T0YQI7w==", + "dev": true, + "requires": { + "compare-func": "^2.0.0" + } + }, "conventional-changelog-core": { "version": "4.2.4", "dev": true, diff --git a/package.json b/package.json index 68cbeb778..df3c2a606 100644 --- a/package.json +++ b/package.json @@ -39,6 +39,7 @@ "@types/node": "^20.11.17", "@types/prop-types": "^15.7.10", "@vitejs/plugin-react-swc": "^3.7.0", + "conventional-changelog-conventionalcommits": "^7.0.0", "eslint": "^8.37.0", "identity-obj-proxy": "^3.0.0", "jest": "^29.6.2",