Skip to content

Commit e8e53c8

Browse files
committedApr 9, 2023
chore: update workflows config.
1 parent a89485d commit e8e53c8

File tree

1 file changed

+61
-58
lines changed

1 file changed

+61
-58
lines changed
 

‎.github/workflows/ci.yml

+61-58
Original file line numberDiff line numberDiff line change
@@ -6,73 +6,76 @@ on:
66

77
jobs:
88
build-deploy:
9-
runs-on: ubuntu-18.04
9+
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@v2
12-
- uses: actions/setup-node@v2
13-
with:
14-
node-version: 14
11+
- uses: actions/checkout@v3
12+
- uses: actions/setup-node@v3
13+
with:
14+
node-version: 16
15+
registry-url: 'https://registry.npmjs.org'
1516

16-
- run: npm install
17-
- run: npm run build
18-
- run: npm run doc
17+
- run: npm install
18+
- run: npm run build
19+
- run: npm run doc
1920

20-
- name: Generate Contributors Images
21-
uses: jaywcjlove/github-action-contributors@main
22-
with:
23-
filter-author: (renovate\[bot\]|renovate-bot|dependabot\[bot\])
24-
output: build/CONTRIBUTORS.svg
25-
avatarSize: 42
21+
- name: Generate Contributors Images
22+
uses: jaywcjlove/github-action-contributors@main
23+
with:
24+
filter-author: (renovate\[bot\]|renovate-bot|dependabot\[bot\])
25+
output: build/CONTRIBUTORS.svg
26+
avatarSize: 42
2627

27-
- name: Create Tag
28-
id: create_tag
29-
uses: jaywcjlove/create-tag-action@v1.3.6
30-
with:
31-
package-path: ./package.json
28+
- name: Create Tag
29+
id: create_tag
30+
uses: jaywcjlove/create-tag-action@main
31+
with:
32+
package-path: ./package.json
3233

33-
- name: get tag version
34-
id: tag_version
35-
uses: jaywcjlove/changelog-generator@v1.5.3
34+
- name: get tag version
35+
id: tag_version
36+
uses: jaywcjlove/changelog-generator@main
3637

37-
- name: Deploy
38-
uses: peaceiris/actions-gh-pages@v3
39-
with:
40-
user_name: 'github-actions[bot]'
41-
user_email: 'github-actions[bot]@users.noreply.github.com'
42-
commit_message: ${{steps.tag_version.outputs.tag}} ${{ github.event.head_commit.message }}
43-
github_token: ${{ secrets.GITHUB_TOKEN }}
44-
publish_dir: ./build
38+
- name: Deploy
39+
uses: peaceiris/actions-gh-pages@v3
40+
with:
41+
user_name: 'github-actions[bot]'
42+
user_email: 'github-actions[bot]@users.noreply.github.com'
43+
commit_message: ${{steps.tag_version.outputs.tag}} ${{ github.event.head_commit.message }}
44+
github_token: ${{ secrets.GITHUB_TOKEN }}
45+
publish_dir: ./build
4546

46-
- name: Generate Changelog
47-
id: changelog
48-
uses: jaywcjlove/changelog-generator@v1.5.3
49-
with:
50-
head-ref: ${{steps.create_tag.outputs.version}}
51-
filter-author: (小弟调调™|Renovate Bot)
52-
filter: '[R|r]elease[d]\s+[v|V]\d(\.\d+){0,2}'
47+
- name: Generate Changelog
48+
id: changelog
49+
uses: jaywcjlove/changelog-generator@main
50+
with:
51+
head-ref: ${{steps.create_tag.outputs.version}}
52+
filter-author: (小弟调调™|Renovate Bot)
53+
filter: '[R|r]elease[d]\s+[v|V]\d(\.\d+){0,2}'
5354

54-
- name: Create Release
55-
uses: ncipollo/release-action@v1
56-
if: steps.create_tag.outputs.successful
57-
with:
58-
token: ${{ secrets.GITHUB_TOKEN }}
59-
name: ${{ steps.create_tag.outputs.version }}
60-
tag: ${{ steps.create_tag.outputs.version }}
61-
body: |
62-
[![](https://img.shields.io/badge/Open%20in-unpkg-blue)](https://uiwjs.github.io/npm-unpkg/#/pkg/@uiw/react-shields@${{ steps.create_tag.outputs.versionNumber }}/file/README.md)
55+
- name: Create Release
56+
uses: ncipollo/release-action@v1
57+
if: steps.create_tag.outputs.successful
58+
with:
59+
token: ${{ secrets.GITHUB_TOKEN }}
60+
name: ${{ steps.create_tag.outputs.version }}
61+
tag: ${{ steps.create_tag.outputs.version }}
62+
body: |
63+
[![](https://img.shields.io/badge/Open%20in-unpkg-blue)](https://uiwjs.github.io/npm-unpkg/#/pkg/@uiw/react-shields@${{ steps.create_tag.outputs.versionNumber }}/file/README.md)
6364
64-
Documentation ${{ steps.changelog.outputs.tag }}: https://raw.githack.com/uiwjs/react-shields/${{ steps.changelog.outputs.gh-pages-short-hash }}/index.html
65-
Comparing Changes: ${{ steps.changelog.outputs.compareurl }}
65+
Documentation ${{ steps.changelog.outputs.tag }}: https://raw.githack.com/uiwjs/react-shields/${{ steps.changelog.outputs.gh-pages-short-hash }}/index.html
66+
Comparing Changes: ${{ steps.changelog.outputs.compareurl }}
6667
67-
```bash
68-
npm i @uiw/react-shields@${{ steps.create_tag.outputs.versionNumber }}
69-
```
68+
```bash
69+
npm i @uiw/react-shields@${{ steps.create_tag.outputs.versionNumber }}
70+
```
7071
71-
${{ steps.changelog.outputs.compareurl }}
72-
73-
${{ steps.changelog.outputs.changelog }}
72+
${{ steps.changelog.outputs.compareurl }}
73+
74+
${{ steps.changelog.outputs.changelog }}
75+
76+
- run: npm publish --access public
77+
name: 📦 @uiw/react-shields publish to NPM
78+
continue-on-error: true
79+
env:
80+
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
7481

75-
- uses: JS-DevTools/npm-publish@v1
76-
with:
77-
token: ${{ secrets.NPM_TOKEN }}
78-
package: ./package.json

0 commit comments

Comments
 (0)
Please sign in to comment.