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
31 changes: 18 additions & 13 deletions .github/workflows/opencode.yml
Original file line number Diff line number Diff line change
@@ -1,30 +1,34 @@
name: opencode

# Supported events (per opencode docs + runtime allowlist):
# issue_comment — /oc in PR/issue conversation thread
# pull_request_review_comment — /oc on a specific code line (Files tab)
# issues — auto on issue open/edit (needs prompt input)
# pull_request — auto on PR open/sync (needs prompt input)
# schedule — cron (needs prompt input)
# workflow_dispatch — manual (needs prompt input)
#
# Note: pull_request_review (review body on Submit) is NOT supported by the
# opencode action. /oc in review bodies will be ignored. Use conversation
# comments or line comments instead.
on:
issue_comment:
types: [created]
pull_request_review_comment:
types: [created]
Comment thread
RussellSB marked this conversation as resolved.
Comment thread
RussellSB marked this conversation as resolved.
pull_request_review:
types: [submitted]

jobs:
opencode:
concurrency:
group: opencode-${{ github.event.issue.number || github.event.pull_request.number }}
cancel-in-progress: false
Comment thread
RussellSB marked this conversation as resolved.
if: |
(
github.event.comment.author_association == 'COLLABORATOR' ||
github.event.comment.author_association == 'OWNER' ||
github.event.review.author_association == 'COLLABORATOR' ||
github.event.review.author_association == 'OWNER'
github.event.comment.author_association == 'OWNER'
) && (
contains(github.event.comment.body, ' /oc') ||
startsWith(github.event.comment.body, '/oc') ||
contains(github.event.comment.body, ' /opencode') ||
startsWith(github.event.comment.body, '/opencode') ||
contains(github.event.review.body, ' /oc') ||
startsWith(github.event.review.body, '/oc') ||
contains(github.event.review.body, ' /opencode') ||
startsWith(github.event.review.body, '/opencode')
contains(github.event.comment.body, '/oc') ||
contains(github.event.comment.body, '/opencode')
)
Comment thread
RussellSB marked this conversation as resolved.
runs-on: ubuntu-latest
timeout-minutes: 15
Expand Down Expand Up @@ -83,5 +87,6 @@ jobs:
PYTRENDY_CI: "true"
PONYTAIL_DEFAULT_MODE: "ultra"
CONTEXT7_API_KEY: ${{ secrets.CONTEXT7_API_KEY }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
model: opencode-go/mimo-v2.5
5 changes: 4 additions & 1 deletion AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ Other skills (`test`, `cicd`, `debug`, `pr-plots`) load on demand for specific t
## Critical rules (summary — details in skills)

- PRs target `develop`, not `main`
- Commits: Conventional Commits enforced by `lint-pr-title.yml`
- **Commits must use Conventional Commits**: `fix:`, `feat:`, `chore:`, `ci:`, `docs:`, `refactor:`, `perf:`, `test:`, `build:`, `revert:`
- Lowercase, imperative, <72 chars, no trailing period
- This applies to all commit messages you generate, including auto-generated summaries
- `lint-pr-title.yml` enforces the `type: description` prefix and allowed types on PR titles (regex: `^(feat|fix|docs|style|refactor|perf|test|build|ci|chore|revert)(\(.+\))?!?: .+`)
Comment thread
RussellSB marked this conversation as resolved.
- Deprecating a public param = `feat:` (minor), NOT `refactor:`
- Never hand-edit `pyproject.toml` version or `CHANGELOG.md`
Loading