runsascoded/ghpr#5 Improve create and init workflows
This PR includes several improvements to the create and init commands, making the PR/Issue creation workflow more robust and user-friendly.
- Remove placeholder confusion - Templates now use plain
# Titleformat; link-references added automatically after PR/Issue creation - Interactive web editor support - Default mode opens browser, waits for user confirmation, then fetches PR info and updates file
- Support user-namespaced branches - Auto-detects remote branch names when local branch differs (e.g., local
ws3→ remotem/rw/ws3) - Better parent repo detection - Uses
git rev-parse --show-toplevelto properly find parent repo when running from nestedgh/new/directory - Flexible opening behavior - New
-y/--yescount flag:- Default (no flag): Opens web editor during creation (interactive, waits for Enter)
-yonce: Creates PR then views result-yytwice: Creates silently without opening
- Complete workflow setup - Creates initial commit and configures gist mirror automatically, eliminating manual force-push
- Plain template - No more
[owner/repo#XXXX]placeholders to confuse users
- Fix
createto use remote branch name for PRs - Fix
createto use git to find parent repo root - Add
-y/--yescount flag to control opening behavior increate - Fix placeholder link handling in
create - Make
initcreate initial commit and set up gist mirror - Remove placeholder format, use plain titles until PR created