Skip to content

Commit

Permalink
Merge branch 'release/1.0.16' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
guotingchao committed Apr 28, 2024
2 parents 86f905c + 7b45038 commit bc4b01d
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 11 deletions.
10 changes: 7 additions & 3 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ on:
- develop
- release/**
- hotfix/**
- support/**
- feature/**
defaults:
run:
shell: bash
Expand Down Expand Up @@ -55,16 +57,18 @@ jobs:
run: pnpm run test

- name: 📦 Build
if: startsWith(github.ref_name, 'release/') || startsWith(github.ref_name, 'hotfix/') || startsWith(github.ref_name, 'support/')
run: pnpm run build

- name: 🦋 Create Pull Request
if: startsWith(github.ref_name, 'release/') || startsWith(github.ref_name, 'hotfix/') || startsWith(github.ref_name, 'support/')
uses: peter-evans/create-pull-request@v6
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.ref }}
base: main
title: "Pull Request form Github Actions"
body: "This is a pull request created by Actions Robot 🤖"
commit-message: "Pull Request ${{ github.head_ref }} into main"
title: "🤖 Pull Request form ${{github.ref_name}}"
body: "created by Actions Robot 🤖"
commit-message: "Pull Request ${{ github.ref_name }} into main"
labels: "CI"
assignees: "guotingchao"
15 changes: 8 additions & 7 deletions .github/workflows/Release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,13 +57,8 @@ jobs:
id: build-the-library
run: |
pnpm build
- name: test echo
run: |
echo ${{github.head_ref}}
echo ${{github.event_name}}
echo ${{github.ref_name}}
- name: 📣 Create Release Pull Request or Publish to npm
if: github.head_ref == 'changeset-release/main' && github.event_name == 'push'
- name: 📣 Create Release Pull Request and Publish new version to Npm
if: startsWith(github.head_ref, 'release/') && github.event_name == 'pull_request'
id: changesets
uses: changesets/[email protected]
with:
Expand All @@ -74,3 +69,9 @@ jobs:
env:
GITHUB_TOKEN: ${{ env.GITHUB_TOKEN }}
NPM_TOKEN: ${{ env.NPM_TOKEN }}
- name: 🎺 Publish new version to Github Packages
if: startsWith(github.head_ref, 'changeset-release/main') && github.event_name == 'pull_request'
uses: JS-DevTools/npm-publish@v3
with:
token: ${{ secrets.GITHUB_TOKEN }}
registry: "https://npm.pkg.github.com"
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@
"access": "public",
"scope": "@cardbrother",
"tag": "latest",
"registry": "https://registry.npmjs.org/"
"registry": "https://registry.npmjs.org"
},
"bugs": {
"url": "https://github.com/guotingchao/nest-tencent-cloud-sdk/issues",
Expand Down

0 comments on commit bc4b01d

Please sign in to comment.