Skip to content

GitHub/Vercel in the notch: watch lists, right-side panel, actions - #281

Open
guerraOrzc wants to merge 2 commits into
Louis-CFM:mainfrom
guerraOrzc:contrib/a-github-vercel-panel
Open

guerraOrzc wants to merge 2 commits into
Louis-CFM:mainfrom
guerraOrzc:contrib/a-github-vercel-panel

Conversation

@guerraOrzc

@guerraOrzc guerraOrzc commented Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

Adds GitHub and Vercel watch lists, a right-side detail panel, and GitHub/Vercel actions to the Mac notch (NotchBuddy/).

This is 1 of 3 PRs split from #280:

The iPhone app, widgets and Windows/Linux app are untouched; the CoucouPhone scheme still builds. Pill IDs, the bundle ID and ~/.claude/settings.json handling are unchanged.

Screenshots

Repo picker and My PRs. Tap the GitHub title to pick a repo, then tap a row to open its list in the right card:

GitHub card: repo picker, then My PRs in the right-side panel

A Vercel deployment in the right-side panel, with its actions:

Vercel card: a deployment opens in the right-side panel

A session's branch. The chip next to a Claude Code session opens its PR, checks and preview (this branch has no open PR):

Session branch chip opening the branch panel

When two watched repos share a name (a fork and its upstream), the picker shows owner/name:

Repo picker with Louis-CFM/coucou and guerraOrzc/coucou

Settings

  • GitHub → Repositories.
    • Choose up to 20 repos to watch from a list loaded from /user/repos (owner, collaborator and organization member, archived repos excluded, up to 500 repos).
    • Watched repos are fetched by name in the pulse GraphQL query as aliases r0…rN, each checked against [A-Za-z0-9._-].
    • With none selected, the pulse works as before (your 10 most recently pushed repos).
    • Behavior change: with a watch list, My PRs, To review and default-branch CI only show those repos.
  • Vercel → Scope.
    • Personal account or a team, loaded from /v2/teams.
    • Every Vercel call (poller, project list, actions) gets ?teamId= through a new VercelAPI.url(_:).
    • Changing the scope clears the project filter and polls the new scope without an alert.

In the notch

  • Quick switch. The GitHub and Vercel card titles become a button (title + chevron) when there is more than one repo/project. It opens a chip picker in the right card, styled like the agent pills, with "All" plus the watched repos/projects. The choice is saved.
  • Right-side panel (SidePanelView.swift).
    • The right card can temporarily replace the agent pills with details:
      • a GitHub section (My PRs, To review, default-branch CI);
      • one Vercel deployment;
      • the PR/CI of a session's branch.
    • It closes with ✕ or Esc. It also closes on its own when the focused pill changes, the island collapses, or another view takes over (approval, question, chat), so approval and question cards are never hidden.
    • While other pills have a badge, the ✕ shows a small amber dot.
  • Actions. Every action needs two clicks: the first turns the button into "Confirm?" for 3 s.
    • GitHub: Merge (non-draft My PRs, squash), Approve (To review), Re-run failed jobs (failing default-branch CI, or a session's failing branch; it finds the latest failed run via actions/runs).
    • Vercel: Redeploy (Ready/Error), Cancel build (in progress), Promote (Ready, non-production).
    • The result shows in the panel header. They reuse the iPhone actions, moved from the iPhone-only PhoneLink/ServiceDetailRunner.swift into a shared ServiceAPI.swift, unchanged apart from the team scope.
  • Vercel deployments.
    • Builds in progress (BUILDING / QUEUED / INITIALIZING) are now kept and shown as "building…" with an amber dot. Before, only finished deployments were listed. The poller fetches 20 deployments instead of 5.
    • A failed deployment shows why it failed: its errorMessage, else the most specific error line of its build log (v3/deployments/{id}/events, terminal color codes stripped).
    • Alerts still fire once per finished deployment of a watched project.
    • The iPhone snapshot shows builds in progress as a warning.
  • Session → PR and CI.
    • Next to a workspace session's name (Claude Code, Cursor), a chip shows the open PR of the session's branch (#12 + CI dot), or the branch name.
    • The branch comes from the session folder's .git, read as files (GitRepoInfo.swift, no git process); worktrees and gitdir: files are followed.
    • The PR lookup (SessionGitHubLinker.swift) passes the repo and branch as GraphQL variables. It keeps only PRs whose head repo is the origin repo, so a fork's same-named branch doesn't match.
    • It runs only while the island is open on that session: at most once a minute, every 30 s while CI is running.
    • The branch name truncates in the middle to leave room for the session name; the CI dot only shows once CI is known.
    • The chip opens a panel with: the PR + Merge; or "No open pull request" + an "Open PR" compare link; the branch checks + Re-run; and the branch's Vercel deployment.
    • Not in the App Store build: the sandbox can't read .git.
  • PR → Vercel preview. In My PRs, a small Vercel mark opens the preview deployment built from the PR's branch.

Behavior changes to existing views (CLAUDE.md asks not to restyle shipped views without being asked, so flagging them here):

  • The Vercel card's left-side detail (VercelDetailView) is replaced by the right-side panel. The first deployment still opens with its "…" button; the other rows now open with a tap.
  • In a session's header, the subtitle ("Claude Code") is hidden while the branch chip is shown, so the session name keeps its room. The pill already says which agent it is.
  • The GitHub and Vercel card titles can show the focused repo/project.
  • Vercel polling now runs only while the Vercel pill is active (or iPhone sync is on), instead of whenever a token is saved.

Related open PRs

  • Mac: GitHub CI for the session's branch, pull requests and Google Calendar #247 also reads the session's branch from .git without a git process, and shows that branch's CI and your pull requests and reviews. This PR adds watch lists, the repo/project picker, the right-side panel with actions, Vercel, and the session → PR chip. If both land, the branch reading would exist twice (GitRepoInfo here, GitHubActivity there); I'll adapt this PR to whichever goes in first.

Not done / known limits

  • Localization: new strings are English only. They are plain SwiftUI literals, so they can be added to Localizable.xcstrings, but no translations are included.
  • Session PR lookup: it queries the origin repo only, so PRs opened from a fork into upstream aren't found.
  • Preview matching: it looks at the 20 most recent Vercel deployments.

Testing

  • Builds: NotchBuddy (Debug, and Debug with PHONE_LINK), CoucouAppStore (CODE_SIGNING_ALLOWED=NO) and CoucouPhone (iOS Simulator) build on Xcode 27.
  • Tests: all scripts/test-*.sh pass, including the new test-git-repo-info.sh (remote URLs, HEAD, config, worktrees) and additions to test-github-pulse.sh (alias parsing, repo filtering, SessionBranchInfo including the fork case).
  • Checked live:
    • The pulse query with aliases and the session-branch query, against the GitHub API (read-only).
    • The session lookup finds the right PR, and skips a fork PR with the same branch name.
    • On screen (the GIFs above): the repo picker, My PRs, a Vercel deployment and a session's branch panel. Actions were not clicked on real repos and projects.
  • Not tested yet: the Vercel failure reason on a real failed deployment.

🤖 Generated with Claude Code

… notch

- Settings: pick watched GitHub repos and a Vercel team + projects;
  quick-switch the focused repo/project from the card header.
- Right card swaps to a detail panel for a PR or deployment (✕ closes,
  pills come back when an agent needs approval or asks a question).
- Merge/approve/rerun and redeploy/promote/cancel from the Mac notch
  (shared ServiceAPI, moved out of the iPhone-only runner).
- Vercel building state and failure reason; PR → preview deployment.
- Claude Code session → branch/PR chip and panel (GitRepoInfo,
  SessionGitHubLinker). Vercel polls only while its pill is active.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ashes

The branch and reply chips squeezed the session name to one letter, so
the subtitle (already shown on the pill) is hidden while chips are shown.
Watching a fork and its upstream showed two identical "coucou" chips:
a repo whose name clashes with another watched repo now shows owner/name.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@guerraOrzc
guerraOrzc marked this pull request as ready for review October 7, 2026 22:22

This branch has not been deployed

No deployments
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