Skip to content

Commit 776c61d

Browse files
authored
Update framework, document pr-fix, separate extra github tools read/pr (#41)
* update framework * update framework
1 parent da6250c commit 776c61d

20 files changed

Lines changed: 292 additions & 150 deletions

README.md

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,27 @@
33
A sample family of reusable [GitHub Agentic Workflows](https://github.com/githubnext/gh-aw?tab=readme-ov-file).
44

55
> [!WARNING]
6-
> GitHub Agentic Workflows are a research demonstrator, and these workflows are samples only.
6+
> GitHub Agentic Workflows are a research demonstrator, and these workflows are demonstrator samples only. They are not intended for production use. Use at your own risk.
77
88
## 📂 Available Workflows
99

10-
### Research & Planning Workflows
10+
### Research, Status & Planning Workflows
1111
- [📚 Weekly Research](docs/weekly-research.md) - Collect research updates and industry trends
1212
- [👥 Daily Team Status](docs/daily-team-status.md) - Assess repository activity and create status reports
1313
- [📋 Daily Plan](docs/daily-plan.md) - Update planning issues for team coordination
14+
15+
### Depth Triage & Analysis Workflows
1416
- [🏷️ Issue Triage](docs/issue-triage.md) - Triage issues and pull requests
17+
- [🏥 CI Doctor](docs/ci-doctor.md) - Monitor CI workflows and investigate failures automatically
18+
- [🔍 Daily Accessibility Review](docs/daily-accessibility-review.md) - Review application accessibility by automatically running and using the application
1519

1620
### Coding & Development Workflows
17-
- [🏥 CI Doctor](docs/ci-doctor.md) - Monitor CI workflows and investigate failures automatically
1821
- [📦 Daily Dependency Updater](docs/daily-dependency-updates.md) - Update dependencies and create pull requests
1922
- [📖 Regular Documentation Update](docs/update-docs.md) - Update documentation automatically
20-
- [🔍 Daily Adhoc QA](docs/daily-qa.md) - Perform "soft", explorative quality assurance tasks
23+
- [🏥 PR Fix](docs/pr-fix.md) - Analyze failing CI checks and implement fixes for pull requests
24+
- [🔎 Daily Adhoc QA](docs/daily-qa.md) - Perform adhoc explorative quality assurance tasks
2125
- [🧪 Daily Test Coverage Improver](docs/daily-test-improver.md) - Improve test coverage by adding meaningful tests to under-tested areas
2226
- [⚡ Daily Performance Improver](docs/daily-perf-improver.md) - Analyze and improve code performance through benchmarking and optimization
23-
- [🔍 Daily Accessibility Review](docs/daily-accessibility-review.md) - Review application accessibility by automatically running and using the application
2427

2528
## 💻 Coding Tasks Warning
2629

docs/daily-dependency-updates.md

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,19 +16,25 @@ This creates a pull request to add the workflow to your repository. After mergin
1616
gh aw run daily-dependency-updates
1717
```
1818

19+
❗IMPORTANT: GitHub Actions runs will **not** trigger on commits pushed by this workflow and will **not** tell you that CI has not been run unless you have enabled a specific custom check for this condition. **You must open/close the PR or hit "Update branch" if offered to trigger CI.Yes it's painful and yes it's just something you need to be aware of.
20+
1921
**Checklist**
2022

21-
* [ ] See notes on coding tasks in the [main README](../README.md).
23+
* [ ] I have read the notes on coding tasks in the [main README](../README.md) and understand the implications.
24+
25+
* [ ] I am a repository admin or have sufficient permissions, and am happy for this workflow to push new branches to the repository.
26+
27+
* [ ] I have enabled "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
2228

23-
* [ ] Enable "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
29+
* [ ] I have considered enabling "Always suggest updating pull request branches" in the repository settings
2430

25-
* [ ] Recommend enabling "Always suggest updating pull request branches" in the repository settings
31+
* [ ] If in a fork, I have enabled "GitHub Actions" and "GitHub Issues" in the fork repository settings
2632

27-
* [ ] If in a fork, enable "GitHub Actions" and "GitHub Issues" in the fork project settings
33+
* [ ] I will review all pull requests very carefully, and carefully monitor the repository.
2834

29-
* [ ] When a pull request is created, you must review the changes carefully.
35+
* [ ] I will operate this demonstrator for a time-limited period only (the default is 48h).
3036

31-
* [ ] Understand that your GitHub Actions runs will **not** trigger on pull requests created by this workflow, or indeed any Actions-created PRs. You must open/close the PR or push a new commit to trigger CI checks. This is not indicated in the GitHub UI. It's just something you need to be aware of.
37+
* [ ] I understand that GitHub Actions runs will **not** trigger on pull requests created by this workflow, see above.
3238

3339
## Configuration
3440

docs/daily-perf-improver.md

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,19 +22,25 @@ To run continuously (at most one instance running at a time and sending a trigge
2222
gh aw run daily-perf-improver --repeat 180
2323
```
2424

25+
❗IMPORTANT: GitHub Actions runs will **not** trigger on commits pushed by this workflow and will **not** tell you that CI has not been run unless you have enabled a specific custom check for this condition. **You must open/close the PR or hit "Update branch" if offered to trigger CI.Yes it's painful and yes it's just something you need to be aware of.
26+
2527
**Checklist**
2628

27-
* [ ] See notes on coding tasks in the [main README](../README.md).
29+
* [ ] I have read the notes on coding tasks in the [main README](../README.md) and understand the implications.
30+
31+
* [ ] I am a repository admin or have sufficient permissions, and am happy for this workflow to push new branches to the repository.
32+
33+
* [ ] I have enabled "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
2834

29-
* [ ] Enable "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
35+
* [ ] I have considered enabling "Always suggest updating pull request branches" in the repository settings
3036

31-
* [ ] Recommend enabling "Always suggest updating pull request branches" in the repository settings
37+
* [ ] If in a fork, I have enabled "GitHub Actions" and "GitHub Issues" in the fork repository settings
3238

33-
* [ ] If in a fork, enable "GitHub Actions" and "GitHub Issues" in the fork project settings
39+
* [ ] I will review all pull requests very carefully, and carefully monitor the repository.
3440

35-
* [ ] When a pull request is created, you must review the changes carefully.
41+
* [ ] I will operate this demonstrator for a time-limited period only (the default is 48h).
3642

37-
* [ ] Understand that your GitHub Actions runs will **not** trigger on pull requests created by this workflow, or indeed any Actions-created PRs. You must open/close the PR or push a new commit to trigger CI checks. This is not indicated in the GitHub UI. It's just something you need to be aware of.
43+
* [ ] I understand that GitHub Actions runs will **not** trigger on pull requests created by this workflow, see above.
3844

3945
## Configuration
4046

docs/daily-test-improver.md

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,19 +16,25 @@ This creates a pull request to add the workflow to your repository. After mergin
1616
gh aw run daily-test-improver
1717
```
1818

19+
❗IMPORTANT: GitHub Actions runs will **not** trigger on commits pushed by this workflow and will **not** tell you that CI has not been run unless you have enabled a specific custom check for this condition. **You must open/close the PR or hit "Update branch" if offered to trigger CI.Yes it's painful and yes it's just something you need to be aware of.
20+
1921
**Checklist**
2022

21-
* [ ] See notes on coding tasks in the [main README](../README.md).
23+
* [ ] I have read the notes on coding tasks in the [main README](../README.md) and understand the implications.
24+
25+
* [ ] I am a repository admin or have sufficient permissions, and am happy for this workflow to push new branches to the repository.
26+
27+
* [ ] I have enabled "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
2228

23-
* [ ] Enable "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
29+
* [ ] I have considered enabling "Always suggest updating pull request branches" in the repository settings
2430

25-
* [ ] Recommend enabling "Always suggest updating pull request branches" in the repository settings
31+
* [ ] If in a fork, I have enabled "GitHub Actions" and "GitHub Issues" in the fork repository settings
2632

27-
* [ ] If in a fork, enable "GitHub Actions" and "GitHub Issues" in the fork project settings
33+
* [ ] I will review all pull requests very carefully, and carefully monitor the repository.
2834

29-
* [ ] When a pull request is created, you must review the changes carefully.
35+
* [ ] I will operate this demonstrator for a time-limited period only (the default is 48h).
3036

31-
* [ ] Understand that your GitHub Actions runs will **not** trigger on pull requests created by this workflow, or indeed any Actions-created PRs. You must open/close the PR or push a new commit to trigger CI checks. This is not indicated in the GitHub UI. It's just something you need to be aware of.
37+
* [ ] I understand that GitHub Actions runs will **not** trigger on pull requests created by this workflow, see above.
3238

3339
## Configuration
3440

docs/pr-fix.md

Lines changed: 97 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,97 @@
1+
# 🔧 PR Fix
2+
3+
> For an overview of all available workflows, see the [main README](../README.md).
4+
5+
The ["@pr-fix" workflow](../workflows/pr-fix.md?plain=1) is an alias workflow "@pr-fix" that will help you fix and complete pull requests. By default it will analyze failing CI checks in pull requests, identify root causes, and implement fixes to resolve issues and get PRs back to a passing state.
6+
7+
You can trigger the workflow in default mode by adding a comment to a pull request with the alias:
8+
9+
```
10+
@pr-fix
11+
```
12+
13+
or by writing a comment:
14+
15+
```
16+
@pr-fix Please add more tests.
17+
```
18+
19+
## Installation
20+
21+
```bash
22+
gh aw add pr-fix -r githubnext/agentics --pr
23+
```
24+
25+
This creates a pull request to add the workflow to your repository. You can't start a run of this workflow directly as it is triggered in the context of a pull request with failing checks.
26+
27+
To trigger the workflow on a specific pull request, add a comment with the alias:
28+
29+
```
30+
@pr-fix
31+
```
32+
33+
IMPORTANT: GitHub Actions runs will **not** trigger on commits pushed by this workflow and will **not** tell you that CI has not been run unless you have enabled a specific custom check for this condition. **You must open/close the PR or hit "Update branch" if offered to trigger CI.Yes it's painful and yes it's just something you need to be aware of.
34+
35+
**Checklist**
36+
37+
* [ ] I have read the notes on coding tasks in the [main README](../README.md) and understand the implications.
38+
39+
* [ ] I am a repository admin or have sufficient permissions, and am happy for this workflow to push new branches to the repository.
40+
41+
* [ ] I have enabled "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
42+
43+
* [ ] I have considered enabling "Always suggest updating pull request branches" in the repository settings
44+
45+
* [ ] If in a fork, I have enabled "GitHub Actions" and "GitHub Issues" in the fork repository settings
46+
47+
* [ ] I will review all pull requests very carefully, and carefully monitor the repository.
48+
49+
* [ ] I will operate this demonstrator for a time-limited period only (the default is 48h).
50+
51+
* [ ] I understand that GitHub Actions runs will **not** trigger on pull requests created by this workflow, see above.
52+
53+
## Configuration
54+
55+
This workflow requires no configuration and works out of the box. However, you can customize it as follows:
56+
57+
1. Use local configuration to specify custom build commands, testing procedures, linting rules, and code formatting standards. Local configuration can be done in `.github/workflows/agentics/pr-fix.config.md`.
58+
59+
2. Build tool configuration for build tools shared across all workflows installed from this pack can be done in `.github/workflows/agentics/build-tools.md`.
60+
61+
After editing run `gh aw compile` to update the workflow and commit all changes to the default branch.
62+
63+
## What it reads from GitHub
64+
65+
- Pull request details, files, and metadata
66+
- Workflow run logs and job outputs
67+
- Check run results and status information
68+
- Commit information and diff context
69+
- Repository contents and file structure
70+
- Existing issues related to CI failures
71+
72+
## What it creates
73+
74+
- Pushes fixes directly to the pull request branch
75+
- Adds comments to pull requests explaining the changes made
76+
- May create issues for complex problems requiring human intervention
77+
- Requires `contents: write` and `pull-requests: write` permissions
78+
79+
## What web searches it performs
80+
81+
- Searches for error message documentation and solutions
82+
- Looks up best practices for specific technologies and frameworks
83+
- Researches common fixes for build and test failures
84+
85+
## Human in the loop
86+
87+
- Review all changes pushed by the workflow before merging the PR
88+
- Validate that fixes actually resolve the intended issues
89+
- Monitor for any unintended side effects or regressions
90+
- Provide additional context or instructions via PR comments when needed
91+
- Override or revert changes if the automated fix is incorrect
92+
93+
## Activity duration
94+
95+
- By default this workflow will run for up to 48 hours after being triggered
96+
- The workflow stops automatically after this period to prevent indefinite runs
97+
- You can re-trigger the workflow by commenting with the alias again if needed

docs/update-docs.md

Lines changed: 11 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,20 +16,25 @@ This creates a pull request to add the workflow to your repository. After mergin
1616
gh aw run update-docs
1717
```
1818

19+
❗IMPORTANT: GitHub Actions runs will **not** trigger on commits pushed by this workflow and will **not** tell you that CI has not been run unless you have enabled a specific custom check for this condition. **You must open/close the PR or hit "Update branch" if offered to trigger CI.Yes it's painful and yes it's just something you need to be aware of.
20+
1921
**Checklist**
2022

21-
* [ ] See notes on coding tasks in the [main README](../README.md).
23+
* [ ] I have read the notes on coding tasks in the [main README](../README.md) and understand the implications.
24+
25+
* [ ] I am a repository admin or have sufficient permissions, and am happy for this workflow to push new branches to the repository.
2226

23-
* [ ] Enable "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
27+
* [ ] I have enabled "Allow GitHub Actions to create and approve pull requests" in the repository settings under "Actions > General"
2428

25-
* [ ] Recommend enabling "Always suggest updating pull request branches" in the repository settings
29+
* [ ] I have considered enabling "Always suggest updating pull request branches" in the repository settings
2630

27-
* [ ] If in a fork, enable "GitHub Actions" and "GitHub Issues" in the fork project settings
31+
* [ ] If in a fork, I have enabled "GitHub Actions" and "GitHub Issues" in the fork repository settings
2832

29-
* [ ] When a pull request is created, you must review the changes carefully.
33+
* [ ] I will review all pull requests very carefully, and carefully monitor the repository.
3034

31-
* [ ] Understand that your GitHub Actions runs will **not** trigger on pull requests created by this workflow, or indeed any Actions-created PRs. You must open/close the PR or push a new commit to trigger CI checks. This is not indicated in the GitHub UI. It's just something you need to be aware of.
35+
* [ ] I will operate this demonstrator for a time-limited period only (the default is 48h).
3236

37+
* [ ] I understand that GitHub Actions runs will **not** trigger on pull requests created by this workflow, see above.
3338

3439
## Configuration
3540

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
---
2+
tools:
3+
claude:
4+
allowed:
5+
Bash:
6+
- "git checkout:*"
7+
- "git branch:*"
8+
- "git add:*"
9+
- "git commit:*"
10+
- "git push:*"
11+
- "gh pr create:*"
12+
---
13+
14+
## Creating and Updating Pull Requests
15+
16+
To create a branch, add changes to your branch and push code to GitHub, use Bash `git branch...` `git add ...`, `git commit ...`, `git push ...` etc.
17+
18+
When using `git commit`, ensure you set the author name and email appropriately. Do this by using a `--author` flag with `git commit`, for example `git commit --author "${{ github.workflow }} <github-actions[bot]@users.noreply.github.com>" ...`.
19+
20+
To create a pull request with the changes, use Bash `gh pr create --repo ${{ github.repository }} ...`
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
---
2+
tools:
3+
claude:
4+
allowed:
5+
Bash:
6+
- "gh label list:*"
7+
- "gh label view:*"
8+
- "gh repo view:*"
9+
- "gh issue list:*"
10+
- "gh issue view:*"
11+
- "gh pr list:*"
12+
- "gh pr view:*"
13+
---
14+
15+
## GitHub Tools
16+
17+
You can use the GitHub MCP tools to perform various tasks in the repository. You can also use the following `gh` command line invocations:
18+
19+
- List labels: `gh label list ...`
20+
- View label: `gh label view <label-name> ...`
21+
- View repository: `gh repo view ${{ github.repository }} ...`
22+
- List issues: `gh issue list --label <label-name> ...`
23+
- View issue: `gh issue view <issue-number> ...`
24+
- List pull requests: `gh pr list --label <label-name> ...`
25+
- View pull request: `gh pr view <pr-number> ...`
26+

workflows/agentics/shared/gh-extra-tools.md

Lines changed: 0 additions & 20 deletions
This file was deleted.

workflows/daily-dependency-updates.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,10 @@ tools:
3737
Write:
3838
WebFetch:
3939
WebSearch:
40-
Bash: ["gh pr create:*", "git commit:*", "git push:*", "git checkout:*", "git branch:*", "git add:*", "gh auth status", "gh repo view","gh issue comment:*"]
40+
# Configure bash build commands here, or in .github/workflows/agentics/daily-dependency-updates.config.md or .github/workflows/agentics/build-tools.md
41+
Bash:
42+
# For YOLO mode, uncomment the following line
43+
#- ":*
4144
---
4245

4346
# Agentic Dependency Updater
@@ -51,9 +54,6 @@ Your name is "${{ github.workflow }}". Your job is to act as an agentic coder fo
5154

5255
2. Check for an existing PR starting with title "Daily Dependency Updates". Add your additional updates to that PR if it exists, otherwise create a new PR. Try to bundle as many dependency updates as possible into one PR. Test the changes to ensure they work correctly, if the tests don't pass then divide and conquer and create separate PRs for each dependency update.
5356

54-
- Use Bash `gh pr create --repo ${{ github.repository }} ...` to create a pull request with the changes.
55-
- Use the `update_pull_request` tool to update pull requests with any additional changes.
56-
5757
> NOTE: If you didn't make progress on a particular dependency update, add a comment saying what you've tried, ask for clarification if necessary, and add a link to a new branch containing any investigations you tried.
5858
5959
> NOTE: You can use the tools to list, get and add issue comments to add comments to pull reqests too.
@@ -68,7 +68,7 @@ Your name is "${{ github.workflow }}". Your job is to act as an agentic coder fo
6868

6969
@include agentics/shared/xpia.md
7070

71-
@include agentics/shared/gh-extra-tools.md
71+
@include agentics/shared/gh-extra-read-tools.md
7272

7373
<!-- You can whitelist tools in .github/workflows/build-tools.md file -->
7474
@include? agentics/build-tools.md

0 commit comments

Comments
 (0)