Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
on:
alias:
name: test-claude-alias
command:
name: test-claude-command
reaction: eyes

engine:
Expand All @@ -11,5 +11,5 @@ safe-outputs:
add-issue-comment:
---

Add a reply comment to issue #${{ github.event.issue.number }} answering the question "${{ needs.task.outputs.text }}" given the context of the repo, starting with saying you're Claude. If there is no alias write out a haiku about the repo.
Add a reply comment to issue #${{ github.event.issue.number }} answering the question "${{ needs.task.outputs.text }}" given the context of the repo, starting with saying you're Claude. If there is no command write out a haiku about the repo.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
on:
alias:
name: test-codex-alias
command:
name: test-codex-command
reaction: eyes

engine:
Expand All @@ -11,5 +11,5 @@ safe-outputs:
add-issue-comment:
---

Add a reply comment to issue #${{ github.event.issue.number }} answering the question "${{ needs.task.outputs.text }}" given the context of the repo, starting with saying you're Codex. If there is no alias write out a haiku about the repo.
Add a reply comment to issue #${{ github.event.issue.number }} answering the question "${{ needs.task.outputs.text }}" given the context of the repo, starting with saying you're Codex. If there is no command write out a haiku about the repo.

30 changes: 15 additions & 15 deletions docs/alias-triggers.md → docs/command-triggers.md
Original file line number Diff line number Diff line change
@@ -1,43 +1,43 @@
# 🏷️ Alias Triggers
# 🏷️ Command Triggers

This guide covers alias triggers and context text functionality for agentic workflows.
This guide covers command triggers and context text functionality for agentic workflows.

## Special `alias:` Trigger
## Special `command:` Trigger

GitHub Agentic Workflows add the convenience `alias:` trigger to create workflows that respond to `@mentions` in issues and comments.
GitHub Agentic Workflows add the convenience `command:` trigger to create workflows that respond to `/mentions` in issues and comments.

```yaml
on:
alias:
command:
name: my-bot # Optional: defaults to filename without .md extension
```

This automatically creates:
- Issue and PR triggers (`opened`, `edited`, `reopened`)
- Comment triggers (`created`, `edited`)
- Conditional execution matching `@alias-name` mentions
- Conditional execution matching `/command-name` mentions

You can combine `alias:` with other events like `workflow_dispatch` or `schedule`:
You can combine `command:` with other events like `workflow_dispatch` or `schedule`:

```yaml
on:
alias:
command:
name: my-bot
workflow_dispatch:
schedule:
- cron: "0 9 * * 1"
```

**Note**: You cannot combine `alias` with `issues`, `issue_comment`, or `pull_request` as they would conflict.
**Note**: You cannot combine `command` with `issues`, `issue_comment`, or `pull_request` as they would conflict.

**Note**: Using this feature results in the addition of `.github/actions/check-team-member/action.yml` file to the repository when the workflow is compiled. This file is used to check if the user triggering the workflow has appropriate permissions to operate in the repository.

### Example alias workflow
### Example command workflow

```markdown
---
on:
alias:
command:
name: summarize-issue
permissions:
issues: write
Expand All @@ -48,7 +48,7 @@ tools:

# Issue Summarizer

When someone mentions @summarize-issue in an issue or comment,
When someone mentions /summarize-issue in an issue or comment,
analyze and provide a helpful summary.

The current context text is: "${{ needs.task.outputs.text }}"
Expand All @@ -74,16 +74,16 @@ All workflows have access to a special computed `needs.task.outputs.text` value

## Visual Feedback with Reactions

Alias workflows can provide immediate visual feedback by adding reactions to triggering comments and automatically editing them with workflow run links:
Command workflows can provide immediate visual feedback by adding reactions to triggering comments and automatically editing them with workflow run links:

```yaml
on:
alias:
command:
name: my-bot
reaction: "eyes"
```

When someone mentions `@my-bot` in a comment, the workflow will:
When someone mentions `/my-bot` in a comment, the workflow will:
1. Add the specified emoji reaction (👀) to the comment
2. Automatically edit the comment to include a link to the workflow run

Expand Down
4 changes: 2 additions & 2 deletions docs/frontmatter.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ on:
- `rocket` (🚀)
- `eyes` (👀)

**Enhanced functionality**: When using the `reaction:` feature with alias workflows, the system will also automatically edit the triggering comment to include a link to the workflow run. This provides users with immediate feedback and easy access to view the workflow execution. For non-alias workflows, only the reaction is added without comment editing.
**Enhanced functionality**: When using the `reaction:` feature with command workflows, the system will also automatically edit the triggering comment to include a link to the workflow run. This provides users with immediate feedback and easy access to view the workflow execution. For non-command workflows, only the reaction is added without comment editing.

**Note**: This feature uses inline JavaScript code with `actions/github-script@v7` to add reactions and edit comments, so no additional action files are created in the repository.

Expand All @@ -110,7 +110,7 @@ on:
workflow_dispatch:
```

An additional kind of trigger called `alias:` is supported, see [Alias Triggers](alias-triggers.md) for special `@mention` triggers and context text functionality.
An additional kind of trigger called `command:` is supported, see [Command Triggers](command-triggers.md) for special `/mention` triggers and context text functionality.

## Permissions (`permissions:`)

Expand Down
Loading