mirror of
https://github.com/github/awesome-copilot.git
synced 2026-03-13 12:45:13 +00:00
refactor: publish.yml dispatches deploy-website instead of workflow_run
Co-authored-by: aaronpowell <434140+aaronpowell@users.noreply.github.com>
This commit is contained in:
11
.github/workflows/deploy-website.yml
vendored
11
.github/workflows/deploy-website.yml
vendored
@@ -4,15 +4,7 @@
|
|||||||
name: Deploy Website to GitHub Pages
|
name: Deploy Website to GitHub Pages
|
||||||
|
|
||||||
on:
|
on:
|
||||||
# Runs after the Publish to main workflow completes successfully.
|
# Triggered manually from the Actions tab, or dispatched by the Publish to main workflow.
|
||||||
# Note: pushes made by GITHUB_TOKEN do not trigger push-based workflows,
|
|
||||||
# so workflow_run is required to chain off the publish workflow.
|
|
||||||
workflow_run:
|
|
||||||
workflows: ["Publish to main"]
|
|
||||||
types:
|
|
||||||
- completed
|
|
||||||
|
|
||||||
# Allows you to run this workflow manually from the Actions tab
|
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
|
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
|
||||||
@@ -30,7 +22,6 @@ concurrency:
|
|||||||
jobs:
|
jobs:
|
||||||
# Build job
|
# Build job
|
||||||
build:
|
build:
|
||||||
if: ${{ github.event_name == 'workflow_dispatch' || github.event.workflow_run.conclusion == 'success' }}
|
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
|
|||||||
6
.github/workflows/publish.yml
vendored
6
.github/workflows/publish.yml
vendored
@@ -10,6 +10,7 @@ concurrency:
|
|||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
|
actions: write
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
publish:
|
publish:
|
||||||
@@ -52,3 +53,8 @@ jobs:
|
|||||||
git add -f plugins/*/agents/ plugins/*/skills/
|
git add -f plugins/*/agents/ plugins/*/skills/
|
||||||
git commit -m "chore: publish from staged" --allow-empty
|
git commit -m "chore: publish from staged" --allow-empty
|
||||||
git push origin HEAD:main --force
|
git push origin HEAD:main --force
|
||||||
|
|
||||||
|
- name: Dispatch website deployment
|
||||||
|
run: gh workflow run deploy-website.yml --ref main
|
||||||
|
env:
|
||||||
|
GH_TOKEN: ${{ github.token }}
|
||||||
|
|||||||
Reference in New Issue
Block a user