Skip to content

Commit 483b32c

Browse files
committed
ci: update workflow config.
1 parent 403ad38 commit 483b32c

File tree

2 files changed

+22
-16
lines changed

2 files changed

+22
-16
lines changed

.github/workflows/ci.yml

Lines changed: 21 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ env:
1010
jobs:
1111
build-deploy:
1212
runs-on: ubuntu-latest
13+
permissions:
14+
contents: write
15+
id-token: write
1316
steps:
1417
- uses: actions/checkout@v4
1518
- uses: actions/setup-node@v4
@@ -33,21 +36,6 @@ jobs:
3336
output: build/CONTRIBUTORS.svg
3437
avatarSize: 42
3538

36-
# - run: npm install @jsdevtools/npm-publish -g
37-
# - run: npm-publish --token="${{ secrets.NPM_TOKEN }}" ./package.json
38-
39-
- run: npm publish --access public --provenance
40-
name: 📦 @uiw/react-code-preview publish to NPM
41-
continue-on-error: true
42-
env:
43-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
44-
45-
# - name: 📦 📦 @uiw/react-code-preview 📦 📦
46-
# uses: JS-DevTools/npm-publish@v1
47-
# with:
48-
# token: ${{ secrets.NPM_TOKEN }}
49-
# package: package.json
50-
5139
- name: Create Tag
5240
id: create_tag
5341
uses: jaywcjlove/create-tag-action@main
@@ -94,3 +82,21 @@ jobs:
9482
```
9583
9684
${{ steps.changelog.outputs.changelog }}
85+
- name: package.json info
86+
uses: jaywcjlove/github-action-package@main
87+
with:
88+
unset: scripts,lint-staged,eslintConfig,browserslist
89+
# - run: npm install @jsdevtools/npm-publish -g
90+
# - run: npm-publish --token="${{ secrets.NPM_TOKEN }}" ./package.json
91+
92+
- run: npm publish --access public --provenance
93+
name: 📦 @uiw/react-code-preview publish to NPM
94+
continue-on-error: true
95+
env:
96+
NODE_AUTH_TOKEN: ${{ secrets.NPM_PUBLISH_TOKEN }}
97+
98+
# - name: 📦 📦 @uiw/react-code-preview 📦 📦
99+
# uses: JS-DevTools/npm-publish@v1
100+
# with:
101+
# token: ${{ secrets.NPM_PUBLISH_TOKEN }}
102+
# package: package.json

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"homepage": "https://uiwjs.github.io/react-code-preview",
2424
"repository": {
2525
"type": "git",
26-
"url": "https://github.com/uiwjs/react-code-preview"
26+
"url": "git+https://github.com/uiwjs/react-code-preview.git"
2727
},
2828
"files": [
2929
"src",

0 commit comments

Comments
 (0)