Skip to content

Improve GitHub integration setup and monorepo session matching#1

Merged
KaluJo merged 1 commit into
mainfrom
feature/github-integration
Mar 23, 2026
Merged

Improve GitHub integration setup and monorepo session matching#1
KaluJo merged 1 commit into
mainfrom
feature/github-integration

Conversation

@KaluJo
Copy link
Copy Markdown
Collaborator

@KaluJo KaluJo commented Mar 23, 2026

  • pcr github setup: auto-creates webhook via gh CLI, falls back to opening browser; adds --project-ref to supabase deploy/secrets commands; finds function source dir relative to cwd so setup works from any repo
  • projects: add getBestProjectForCursorSlug() with prefix fallback so sessions from a parent workspace (e.g. pcr-developers/) are attributed to the correct registered subproject (e.g. pcr-dev/)
  • cursor watcher: use prefix-aware slug matching instead of exact Set lookup

Made-with: Cursor

- pcr github setup: auto-creates webhook via gh CLI, falls back to opening
  browser; adds --project-ref to supabase deploy/secrets commands; finds
  function source dir relative to cwd so setup works from any repo
- projects: add getBestProjectForCursorSlug() with prefix fallback so sessions
  from a parent workspace (e.g. pcr-developers/) are attributed to the correct
  registered subproject (e.g. pcr-dev/)
- cursor watcher: use prefix-aware slug matching instead of exact Set lookup

Made-with: Cursor
@KaluJo KaluJo merged commit 6975989 into main Mar 23, 2026
KaluJo added a commit that referenced this pull request Apr 26, 2026
…#56)

`pcr show 448` always landed on draft #1 because `tui::screens::show::run`
hardcoded `focus = 0` and the show command never plumbed the user's
argument through to the TUI. Same pattern, opposite direction, in
`pcr bundle`: it opens the same TUI but on the oldest draft, when
the newest is what the user almost always wants to triage first.

Add `tui::screens::show::run_focused(drafts, initial_focus)` and
route both call sites through it:

  - `pcr show <n>` passes `n - 1` so the TUI opens on the requested
    draft.
  - `pcr bundle` (no args, TUI-eligible) passes `drafts.len() - 1`
    so the most recent draft is highlighted on open.

Out-of-range indices are clamped to the last valid row (defensive;
the show command already validates `n <= all.len()` before this
point, but the helper is now safe to call from anywhere).

`run` becomes a thin wrapper around `run_focused(drafts, 0)` so any
existing callers (none today, but the API was public) keep working.

Made-with: Cursor
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant