Skip to content

Commit d4307d2

Browse files
authored
chore: migrate to changeset publish and add publishConfig access public (#24)
* fix: disable persist-credentials in checkout to avoid auth conflicts * chore: migrate to changeset publish and add publishConfig access public
1 parent 78bee77 commit d4307d2

4 files changed

Lines changed: 535 additions & 8 deletions

File tree

.changeset/config.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/config@1.0.1/schema.json",
3+
"changelog": "@changesets/cli/changelog",
4+
"commit": false,
5+
"access": "public",
6+
"baseBranch": "main"
7+
}

.github/workflows/release.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ jobs:
1414
steps:
1515
- name: Checkout code
1616
uses: actions/checkout@v6
17+
with:
18+
persist-credentials: false
1719

1820
- name: Setup Node.js
1921
uses: actions/setup-node@v6
@@ -37,6 +39,6 @@ jobs:
3739
output-modes: npm
3840

3941
- name: Publish to Artifactory npm-public
40-
run: npm publish
42+
run: yarn release
4143
env:
4244
NPM_CONFIG_USERCONFIG: ${{ github.workspace }}/.npmrc-public

package.json

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,11 @@
4040
"!dist/__test__/**"
4141
],
4242
"publishConfig": {
43-
"registry": "https://packages.atlassian.com/api/npm/npm-public/"
43+
"registry": "https://packages.atlassian.com/api/npm/npm-public/",
44+
"access": "public"
4445
},
4546
"scripts": {
47+
"release": "yarn build && changeset publish",
4648
"test": "jest --config jest.config.json",
4749
"build": "tsc --project tsconfig.json",
4850
"lint": "eslint ./src --config eslint.config.mts --ext .ts"
@@ -52,13 +54,14 @@
5254
"node": ">=20.0.0"
5355
},
5456
"devDependencies": {
57+
"@changesets/cli": "^2.30.0",
5558
"@eslint/js": "^10.0.0",
5659
"@types/jest": "^30.0.0",
5760
"eslint": "^10.0.0",
58-
"globals": "^17.0.0",
5961
"eslint-config-prettier": "^10.1.8",
6062
"eslint-plugin-prettier": "^5.5.4",
6163
"eslint-plugin-simple-import-sort": "^13.0.0",
64+
"globals": "^17.0.0",
6265
"jest": "^30.0.5",
6366
"jest-matcher-specific-error": "^1.0.0",
6467
"jiti": "^2.5.1",

0 commit comments

Comments
 (0)