Files
certd/.github/workflows/publish-github.yaml
2026-03-18 09:22:09 +08:00

42 lines
1.0 KiB
YAML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
name: publish-github
on:
push:
branches: ['v2-dev']
paths:
- "trigger/publish.trigger"
workflow_run:
workflows: [ "build-image-for-release" ]
types:
- completed
workflow_dispatch: # 添加手动触发
# schedule:
# - # 国际时间 19:17 执行北京时间3:17 ↙↙↙ 改成你想要每天自动执行的时间
# - cron: '17 19 * * *'
permissions:
contents: read
packages: write
jobs:
publish-github:
runs-on: ubuntu-latest
if: |
github.event_name == 'workflow_dispatch' ||
(github.event.workflow_run.conclusion == 'success')
steps:
- name: Checkout Code
uses: actions/checkout@v4
with:
fetch-depth: 0
lfs: true
ref: 'v2-dev'
- name: publish_to_github
id: publish_to_github
run: |
export GITHUB_TOKEN=${{ secrets.GH_TOKEN }}
rm -rf ./pnpm*.yaml
npm install -g pnpm
pnpm install
npm run publish_to_github
working-directory: ./