Skip to content

Merge remote-tracking branch 'origin/master' #143

Merge remote-tracking branch 'origin/master'

Merge remote-tracking branch 'origin/master' #143

Workflow file for this run

# Install dependence and running `changesets publish`
name: Publish orca-pocket
on:
workflow_dispatch:
push:
branches:
- master
paths:
- 'packages/*/package.json'
- 'package.json'
- 'pnpm-lock.yaml'
- '.github/workflows/publish.yml'
- '.changeset/*'
jobs:
replace-package-json-and-publish:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: write
packages: write
pull-requests: write
issues: read
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-node@v4
with:
node-version: 20
registry-url: https://registry.npmjs.org/
- name: install dependencies
run: |
npm i pnpm@latest-8 -g
pnpm i --no-frozen-lockfile
git config --global user.email "[email protected]"
git config --global user.name "action-robot"
git diff --quiet || git commit -am 'commit lock file'
- name: publish
id: changesets
uses: changesets/action@v1
with:
title: Prepublish check
publish: npm run pub:only
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Format publish log
id: publish_log
run: node ./log.cjs
env:
CHANGESET_PUBLISHED_PACKAGES: ${{ steps.changesets.outputs.publishedPackages }}
CHANGESET_PUBLISHED: ${{ steps.changesets.outputs.published }}
CHANGESET_HAS_CHANGESETS: ${{ steps.changesets.outputs.hasChangesets }}
CHANGESET_PULL_REQUEST_NUMBER: ${{ steps.changesets.outputs.pullRequestNumber }}
- name: Dingtalk Notify
uses: zcong1993/actions-ding@master
if: always()
with:
dingToken: ${{ secrets.DING_TALK_ACCESS_TOKEN }}
body: |
{
"msgtype": "markdown",
"markdown": {
"title":"${{ steps.publish_log.outputs.title }}",
"text": "${{ steps.publish_log.outputs.content }}"
},
"at": {
"isAtAll": false
}
}