diff --git a/.github/workflows/deploy-github-pages.yml b/.github/workflows/deploy-github-pages.yml index 87bf0bf..131bf6f 100644 --- a/.github/workflows/deploy-github-pages.yml +++ b/.github/workflows/deploy-github-pages.yml @@ -1,14 +1,8 @@ name: Deploy GitHub Pages on: - # 仅手动触发 - workflow_dispatch: - inputs: - deploy_message: - description: 'Deployment message' - required: false - default: 'Manual deployment' - type: string + watch: + types: [started] # Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages permissions: @@ -26,13 +20,11 @@ jobs: # Build job build: runs-on: ubuntu-latest + if: github.event.repository.owner.id == github.event.sender.id steps: - name: Checkout uses: actions/checkout@v4 - - name: Show deployment message - run: echo "Deployment message: ${{ github.event.inputs.deploy_message || 'Automated deployment' }}" - - name: Setup Node.js uses: actions/setup-node@v4 with: