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
1 change: 1 addition & 0 deletions .claude/CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ Ready to Review is an elegant modern Slack bot written in Go that integrates wit
### 1. Channel Thread Management
- Start threads in Slack channels when new PRs are created
- Update message prefix emoji based on PR state:
- `:new:` - newly published (appears for ~15 seconds before state changes)
- `:test_tube:` - tests running/pending
- `:cockroach:` - tests broken (blocked on author)
- `:hourglass:` - waiting on review
Expand Down
2 changes: 2 additions & 0 deletions internal/bot/bot.go
Original file line number Diff line number Diff line change
Expand Up @@ -898,6 +898,8 @@ func (c *Coordinator) updateDMMessagesForPR(ctx context.Context, pr prUpdateInfo
prefix := notify.PrefixForState(prState)
var action string
switch prState {
case "newly_published":
action = "newly published"
case "merged":
action = "merged"
case "closed":
Expand Down
4 changes: 4 additions & 0 deletions internal/notify/notify.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,8 @@ type PRInfo struct {
// Exported for use by bot package to ensure consistent PR state display.
func PrefixForState(prState string) string {
switch prState {
case "newly_published":
return ":new:"
case "tests_running":
return ":test_tube:"
case "tests_broken":
Expand Down Expand Up @@ -249,6 +251,8 @@ func (m *Manager) NotifyUser(ctx context.Context, workspaceID, userID, channelID
// Format: :emoji: Title <url|repo#123> · author → action
var action string
switch pr.State {
case "newly_published":
action = "newly published"
case "tests_broken":
action = "fix tests"
case "awaiting_review":
Expand Down