Update deploy.yml
This commit is contained in:
7
.github/workflows/deploy.yml
vendored
7
.github/workflows/deploy.yml
vendored
@@ -4,8 +4,6 @@ on:
|
|||||||
push:
|
push:
|
||||||
branches: [ main ]
|
branches: [ main ]
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
# 添加fork后的首次运行触发
|
|
||||||
fork:
|
|
||||||
|
|
||||||
# 设置GITHUB_TOKEN的权限
|
# 设置GITHUB_TOKEN的权限
|
||||||
permissions:
|
permissions:
|
||||||
@@ -20,6 +18,8 @@ concurrency:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
|
# 只在原仓库或fork的仓库中运行
|
||||||
|
if: github.repository == 'RZLNB/menav' || github.event.repository.fork == true
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout repository
|
- name: Checkout repository
|
||||||
@@ -49,7 +49,8 @@ jobs:
|
|||||||
path: '.'
|
path: '.'
|
||||||
|
|
||||||
- name: Create deployment guide issue
|
- name: Create deployment guide issue
|
||||||
if: github.event_name == 'fork'
|
# 只在fork的仓库中创建issue
|
||||||
|
if: github.event.repository.fork == true
|
||||||
uses: actions/github-script@v7
|
uses: actions/github-script@v7
|
||||||
with:
|
with:
|
||||||
script: |
|
script: |
|
||||||
|
|||||||
Reference in New Issue
Block a user