Skip to content

Commit

Permalink
chore(*): use nx-semantic-release package
Browse files Browse the repository at this point in the history
  • Loading branch information
polymath-eric committed Oct 9, 2024
1 parent e9e3556 commit 24c491e
Show file tree
Hide file tree
Showing 11 changed files with 2,450 additions and 456 deletions.
9 changes: 1 addition & 8 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,7 @@ jobs:
run: yarn --frozen-lockfile
- name: build and release
run: |
PRE_RELEASE_OPTION=""
if [ "${{ github.ref }}" == "refs/heads/alpha" ]; then
PRE_RELEASE_OPTION="--preRelease preid=alpha"
elif [ "${{ github.ref }}" == "refs/heads/beta" ]; then
PRE_RELEASE_OPTION="--preRelease preid=beta"
fi
yarn nx run-many --all --target=release --parallel=1 $PRE_RELEASE_OPTION
yarn nx run-many --all --target=semantic-release --parallel=false
env:
CI: true
GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }}
Expand Down
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
"@commitlint/cli": "^19.5.0",
"@commitlint/config-conventional": "^19.5.0",
"@golevelup/ts-jest": "^0.5.6",
"@jscutlery/semver": "^5.3.1",
"@nx/devkit": "20.0.0",
"@nx/eslint": "20.0.0",
"@nx/eslint-plugin": "20.0.0",
Expand All @@ -47,6 +46,7 @@
"@swc-node/register": "~1.9.1",
"@swc/core": "~1.5.7",
"@swc/helpers": "~0.5.11",
"@theunderscorer/nx-semantic-release": "^2.12.0",
"@types/jest": "29.5.13",
"@types/jest-when": "^3.5.2",
"@types/node": "18.19.9",
Expand All @@ -66,7 +66,6 @@
"jest": "29.7.0",
"jest-when": "^3.6.0",
"lint-staged": "^12.3.4",
"ngx-deploy-npm": "^8.2.0",
"node-polyfill-webpack-plugin": "^1.1.4",
"prettier": "^2.5.1",
"require-from-string": "^2.0.2",
Expand All @@ -84,6 +83,9 @@
"workspaces": [
"packages/**"
],
"nxrelease": {
"repositoryUrl": "https://github.com/PolymeshAssociation/signing-managers"
},
"config": {
"commitizen": {
"path": "commitiquette"
Expand Down
32 changes: 12 additions & 20 deletions packages/approval-signing-manager/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,20 @@
"port": 9000
}
},
"release": {
"executor": "@jscutlery/semver:version",
"semantic-release": {
"executor": "@theunderscorer/nx-semantic-release:semantic-release",
"options": {
"preset": "conventionalcommits",
"tagPrefix": "{projectName}@",
"postTargets": ["build", "npm", "github"]
"github": true,
"changelog": true,
"npm": true,
"tagFormat": "@polymeshassociation/approval-signing-manager@(VERSION}",
"branches": [
{ "name": "main" },
{ "name": "beta", "prerelease": true },
{ "name": "alpha", "prerelease": true }
],
"buildTarget": "build"
}
},
"github": {
"executor": "@jscutlery/semver:github",
"options": {
"tag": "{tag}",
"notes": "{notes}"
}
},
"npm": {
"executor": "ngx-deploy-npm:deploy",
"options": {
"access": "public",
"distFolderPath": "dist/packages/approval-signing-manager"
},
"dependsOn": ["build"]
}
}
}
32 changes: 12 additions & 20 deletions packages/azure-signing-manager/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,20 @@
"port": 9000
}
},
"release": {
"executor": "@jscutlery/semver:version",
"semantic-release": {
"executor": "@theunderscorer/nx-semantic-release:semantic-release",
"options": {
"preset": "conventionalcommits",
"tagPrefix": "{projectName}@",
"postTargets": ["build", "npm", "github"]
"github": true,
"changelog": true,
"npm": true,
"tagFormat": "@polymeshassociation/azure-signing-manager@(VERSION}",
"branches": [
{ "name": "main" },
{ "name": "beta", "prerelease": true },
{ "name": "alpha", "prerelease": true }
],
"buildTarget": "build"
}
},
"github": {
"executor": "@jscutlery/semver:github",
"options": {
"tag": "{tag}",
"notes": "{notes}"
}
},
"npm": {
"executor": "ngx-deploy-npm:deploy",
"options": {
"access": "public",
"distFolderPath": "dist/packages/azure-signing-manager"
},
"dependsOn": ["build"]
}
}
}
32 changes: 12 additions & 20 deletions packages/browser-extension-signing-manager/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,20 @@
"port": 9000
}
},
"release": {
"executor": "@jscutlery/semver:version",
"semantic-release": {
"executor": "@theunderscorer/nx-semantic-release:semantic-release",
"options": {
"preset": "conventionalcommits",
"tagPrefix": "{projectName}@",
"postTargets": ["build", "npm", "github"]
"github": true,
"changelog": true,
"npm": true,
"tagFormat": "@polymeshassociation/browser-signing-manager@(VERSION}",
"branches": [
{ "name": "main" },
{ "name": "beta", "prerelease": true },
{ "name": "alpha", "prerelease": true }
],
"buildTarget": "build"
}
},
"github": {
"executor": "@jscutlery/semver:github",
"options": {
"tag": "{tag}",
"notes": "{notes}"
}
},
"npm": {
"executor": "ngx-deploy-npm:deploy",
"options": {
"access": "public",
"distFolderPath": "dist/packages/browser-extension-signing-manager"
},
"dependsOn": ["build"]
}
}
}
32 changes: 12 additions & 20 deletions packages/fireblocks-signing-manager/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,20 @@
"port": 9000
}
},
"release": {
"executor": "@jscutlery/semver:version",
"semantic-release": {
"executor": "@theunderscorer/nx-semantic-release:semantic-release",
"options": {
"preset": "conventionalcommits",
"tagPrefix": "{projectName}@",
"postTargets": ["build", "npm", "github"]
"github": true,
"changelog": true,
"npm": true,
"tagFormat": "@polymeshassociation/fireblocks-signing-manager@(VERSION}",
"branches": [
{ "name": "main" },
{ "name": "beta", "prerelease": true },
{ "name": "alpha", "prerelease": true }
],
"buildTarget": "build"
}
},
"github": {
"executor": "@jscutlery/semver:github",
"options": {
"tag": "{tag}",
"notes": "{notes}"
}
},
"npm": {
"executor": "ngx-deploy-npm:deploy",
"options": {
"access": "public",
"distFolderPath": "dist/packages/fireblocks-signing-manager"
},
"dependsOn": ["build"]
}
}
}
32 changes: 12 additions & 20 deletions packages/hashicorp-vault-signing-manager/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,20 @@
"port": 9000
}
},
"release": {
"executor": "@jscutlery/semver:version",
"semantic-release": {
"executor": "@theunderscorer/nx-semantic-release:semantic-release",
"options": {
"preset": "conventionalcommits",
"tagPrefix": "{projectName}@",
"postTargets": ["build", "npm", "github"]
"github": true,
"changelog": true,
"npm": true,
"tagFormat": "@polymeshassociation/hashicorp-signing-manager@(VERSION}",
"branches": [
{ "name": "main" },
{ "name": "beta", "prerelease": true },
{ "name": "alpha", "prerelease": true }
],
"buildTarget": "build"
}
},
"github": {
"executor": "@jscutlery/semver:github",
"options": {
"tag": "{tag}",
"notes": "{notes}"
}
},
"npm": {
"executor": "ngx-deploy-npm:deploy",
"options": {
"access": "public",
"distFolderPath": "dist/packages/hashicorp-vault-signing-manager"
},
"dependsOn": ["build"]
}
}
}
32 changes: 12 additions & 20 deletions packages/local-signing-manager/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,28 +39,20 @@
"port": 9000
}
},
"release": {
"executor": "@jscutlery/semver:version",
"semantic-release": {
"executor": "@theunderscorer/nx-semantic-release:semantic-release",
"options": {
"preset": "conventionalcommits",
"tagPrefix": "{projectName}@",
"postTargets": ["build", "npm", "github"]
"github": true,
"changelog": true,
"npm": true,
"tagFormat": "@polymeshassociation/local-signing-manager@(VERSION}",
"branches": [
{ "name": "main" },
{ "name": "beta", "prerelease": true },
{ "name": "alpha", "prerelease": true }
],
"buildTarget": "build"
}
},
"github": {
"executor": "@jscutlery/semver:github",
"options": {
"tag": "{tag}",
"notes": "{notes}"
}
},
"npm": {
"executor": "ngx-deploy-npm:deploy",
"options": {
"access": "public",
"distFolderPath": "dist/packages/local-signing-manager"
},
"dependsOn": ["build"]
}
}
}
32 changes: 12 additions & 20 deletions packages/types/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,20 @@
"port": 9000
}
},
"release": {
"executor": "@jscutlery/semver:version",
"semantic-release": {
"executor": "@theunderscorer/nx-semantic-release:semantic-release",
"options": {
"preset": "conventionalcommits",
"tagPrefix": "{projectName}@",
"postTargets": ["build", "npm", "github"]
"github": true,
"changelog": true,
"npm": true,
"tagFormat": "@polymeshassociation/signing-manager-types@(VERSION}",
"branches": [
{ "name": "main" },
{ "name": "beta", "prerelease": true },
{ "name": "alpha", "prerelease": true }
],
"buildTarget": "build"
}
},
"github": {
"executor": "@jscutlery/semver:github",
"options": {
"tag": "{tag}",
"notes": "{notes}"
}
},
"npm": {
"executor": "ngx-deploy-npm:deploy",
"options": {
"access": "public",
"distFolderPath": "dist/packages/types"
},
"dependsOn": ["build"]
}
}
}
32 changes: 12 additions & 20 deletions packages/walletconnect-signing-manager/project.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,28 +40,20 @@
"port": 9000
}
},
"release": {
"executor": "@jscutlery/semver:version",
"semantic-release": {
"executor": "@theunderscorer/nx-semantic-release:semantic-release",
"options": {
"preset": "conventionalcommits",
"tagPrefix": "{projectName}@",
"postTargets": ["build", "npm", "github"]
"github": true,
"changelog": true,
"npm": true,
"tagFormat": "@polymeshassociation/walletconnect-signing-manager@(VERSION}",
"branches": [
{ "name": "main" },
{ "name": "beta", "prerelease": true },
{ "name": "alpha", "prerelease": true }
],
"buildTarget": "build"
}
},
"github": {
"executor": "@jscutlery/semver:github",
"options": {
"tag": "{tag}",
"notes": "{notes}"
}
},
"npm": {
"executor": "ngx-deploy-npm:deploy",
"options": {
"access": "public",
"distFolderPath": "dist/packages/walletconnect-signing-manager"
},
"dependsOn": ["build"]
}
}
}
Loading

0 comments on commit 24c491e

Please sign in to comment.