Skip to main content
gx handoff generates a formatted summary of your branch: commits, file changes, and stats. Useful for PR descriptions, Slack updates, or standup notes.

Usage

Flags

Auto Base Detection

gx automatically determines the base branch to compare against:
  1. If --against is specified, use that branch
  2. If the current branch is in the stack, use the stack parent
  3. Otherwise, use the HEAD branch (main/master)

Output Formats

Plain (default)

For stacked branches, the header shows the relationship:

Markdown (--markdown or --md)

Examples

Combine --markdown and --copy to generate a PR description and paste it directly into GitHub.
  • If the clipboard copy fails (e.g., no clipboard utility available), gx prints WARN Could not copy to clipboard. but still shows the output
  • If there are no changes between the branches, gx prints > No changes between <current> and <base>.
  • File stats are computed using git diff --stat with the triple-dot syntax (merge base)
  • The markdown format is designed to paste cleanly into GitHub PR descriptions