Skip to content

Commit 7a3e948

Browse files
Copilotmnkiefer
andcommitted
Initial plan for Copilot CLI installer checksum verification
Co-authored-by: mnkiefer <8320933+mnkiefer@users.noreply.github.com>
1 parent 91604a5 commit 7a3e948

File tree

2 files changed

+35
-35
lines changed

2 files changed

+35
-35
lines changed

.github/aw/github-agentic-workflows.md

Lines changed: 5 additions & 30 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/cli/templates/github-agentic-workflows.md

Lines changed: 30 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ The YAML frontmatter supports these fields:
7777
- **`on:`** - Workflow triggers (required)
7878
- String: `"push"`, `"issues"`, etc.
7979
- Object: Complex trigger configuration
80-
- Special: `command:` for /mention triggers
80+
- Special: `slash_command:` for /mention triggers (or deprecated `command:`)
8181
- **`forks:`** - Fork allowlist for `pull_request` triggers (array or string). By default, workflows block all forks and only allow same-repo PRs. Use `["*"]` to allow all forks, or specify patterns like `["org/*", "user/repo"]`
8282
- **`stop-after:`** - Can be included in the `on:` object to set a deadline for workflow execution. Supports absolute timestamps ("YYYY-MM-DD HH:MM:SS") or relative time deltas (+25h, +3d, +1d12h). The minimum unit for relative deltas is hours (h). Uses precise date calculations that account for varying month lengths.
8383
- **`reaction:`** - Add emoji reactions to triggering items
@@ -108,6 +108,10 @@ The YAML frontmatter supports these fields:
108108
- **`roles:`** - Repository access roles that can trigger workflow (array or "all")
109109
- Default: `[admin, maintainer, write]`
110110
- Available roles: `admin`, `maintainer`, `write`, `read`, `all`
111+
- **`bots:`** - Allow list of bot identifiers that can trigger workflow (array)
112+
- Bots in this list can trigger workflows even without required role permissions
113+
- Bot must be installed/active on repository to trigger workflow
114+
- Examples: `["dependabot[bot]", "renovate[bot]", "github-actions[bot]"]`
111115
- **`strict:`** - Enable enhanced validation for production workflows (boolean, defaults to `true`)
112116
- When omitted, workflows enforce strict mode security constraints
113117
- Set to `false` to explicitly disable strict mode for development/testing
@@ -333,9 +337,13 @@ The YAML frontmatter supports these fields:
333337
max: 3 # Optional: maximum number of comments (default: 1)
334338
target: "*" # Optional: target for comments (default: "triggering")
335339
discussion: true # Optional: target discussions
340+
hide-older-comments: true # Optional: hide previous comments from this workflow (default: false)
341+
allowed-reasons: [outdated, resolved] # Optional: allowed hide reasons (default: all)
336342
target-repo: "owner/repo" # Optional: cross-repository
337343
```
338344
When using `safe-outputs.add-comment`, the main job does **not** need `issues: write` or `pull-requests: write` permissions since comment creation is handled by a separate job with appropriate permissions.
345+
346+
The `hide-older-comments` field minimizes previous comments from the same workflow (identified by tracker-id) before adding the new comment. The `allowed-reasons` field restricts which hide reasons are permitted: `spam`, `abuse`, `off_topic`, `outdated`, `resolved`.
339347
- `create-pull-request:` - Safe pull request creation with git patches
340348
```yaml
341349
safe-outputs:
@@ -508,8 +516,23 @@ The YAML frontmatter supports these fields:
508516
github-token: ${{ secrets.CUSTOM_PAT }} # Use custom PAT instead of GITHUB_TOKEN
509517
```
510518
Useful when you need additional permissions or want to perform actions across repositories.
519+
- `mentions:` - Control @mention filtering in AI-generated content (boolean or object)
520+
```yaml
521+
safe-outputs:
522+
mentions: false # Escape all mentions (default)
523+
524+
# Advanced configuration
525+
mentions:
526+
allow-team-members: true # Allow team member mentions (default: true)
527+
allow-context: true # Allow author/assignee mentions (default: true)
528+
allowed: [username, botname] # Explicit allow list
529+
max: 50 # Max mentions per message (default: 50)
530+
```
531+
Controls whether @mentions in AI-generated content are allowed or escaped. By default, mentions are escaped for security. Use `allow-team-members` to permit repository collaborators, `allow-context` for event-related users (authors, assignees), or `allowed` for explicit usernames. Setting `mentions: true` is an error in strict mode.
511532

512-
- **`command:`** - Command trigger configuration for /mention workflows
533+
- **`slash_command:`** - Slash command trigger configuration for /mention workflows
534+
- Also accepts deprecated `command:` field (emits compilation warning)
535+
- Use `slash_command:` for new workflows
513536
- **`cache:`** - Cache configuration for workflow dependencies (object or array)
514537
- **`cache-memory:`** - Memory MCP server with persistent cache storage (boolean or object)
515538

@@ -685,17 +708,19 @@ on:
685708
### Command Triggers (/mentions)
686709
```yaml
687710
on:
688-
command:
711+
slash_command:
689712
name: my-bot # Responds to /my-bot in issues/comments
690713
```
691714

692715
This automatically creates conditions to match `/my-bot` mentions in issue bodies and comments.
693716

717+
**Note**: The `command:` field is deprecated. Use `slash_command:` for new workflows. Existing workflows using `command:` will continue to work but emit a compilation warning.
718+
694719
You can restrict where commands are active using the `events:` field:
695720

696721
```yaml
697722
on:
698-
command:
723+
slash_command:
699724
name: my-bot
700725
events: [issues, issue_comment] # Only in issue bodies and issue comments
701726
```
@@ -1162,7 +1187,7 @@ Research latest developments in ${{ github.repository }}:
11621187
```markdown
11631188
---
11641189
on:
1165-
command:
1190+
slash_command:
11661191
name: helper-bot
11671192
permissions:
11681193
contents: read

0 commit comments

Comments
 (0)