diff --git a/site/src/content/docs/guides/creating-agents.mdx b/site/src/content/docs/guides/creating-agents.mdx index eb884932..9c88f6da 100644 --- a/site/src/content/docs/guides/creating-agents.mdx +++ b/site/src/content/docs/guides/creating-agents.mdx @@ -228,24 +228,27 @@ That makes the agent run inside the `docs` repository. ## Add triggers -Configure triggers under `on:`. +Configure triggers under `on:`. ado-aw supports three trigger types: `pr:` (pull request), `pipeline:` (pipeline completion), and `schedule:`. -### Push +### Pull request ```yaml on: - push: + pr: branches: include: [main] ``` -### Pull request +### Pipeline completion + +Triggers when another ADO pipeline finishes: ```yaml on: - pull_request: + pipeline: + name: "Build Pipeline" branches: - include: [main] + - main ``` ### Schedule @@ -259,10 +262,7 @@ You can combine them: ```yaml on: - push: - branches: - include: [main] - pull_request: + pr: branches: include: [main] schedule: weekly on monday around 09:00 @@ -280,7 +280,7 @@ workspace: repo repos: - infra=my-org/infra-scripts on: - pull_request: + pr: branches: include: [main] schedule: weekly on monday around 09:00