patrick91 / patrick91/shortcake
Add option to specify custom branch name
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 4
- Forks
- 0
- Avg merge
- 4h 22m
- Merged PRs (30d)
- 5
Description
Problem
Currently, branch names are always auto-generated from the commit message with no way to override. This can be limiting when:
- The commit message doesn't translate well to a branch name
- User has a specific naming convention
- Multiple commits with similar messages create confusing branch names
Examples from Other Tools
Charcoal:
charcoal create -n my-custom-branch -m "My commit message"
st:
st create my-custom-branch # Or prompts interactively
Proposed Solution
Add a --name (or -n) flag to the create command:
shortcake create --name my-feature-branch
Implementation Options
Option 1: Flag Only
shortcake create --name custom-branch
# Opens editor, commits, uses 'custom-branch' as name
Option 2: Interactive Fallback
shortcake create
# After commit, show: "Generated branch name: add-new-feature"
# Prompt: "Use this name? [Y/n] (or enter custom name):"
Option 3: Positional Argument
shortcake create [branch-name]
# If provided, use it; otherwise auto-generate
User Stories
- As a developer, I want to use my team's branch naming convention (e.g.,
feature/TICKET-123-description) - As a developer, I want to preview the auto-generated name and change it if needed
- As a developer, I want to create branches without committing first (empty branch for future work)
Implementation Notes
Related code: shortcake/cli.py:125-132
Would need to modify the create command to accept an optional name parameter and skip auto-generation if provided.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the create command in shortcake/cli.py:125-132 and trace how the branch name is currently generated. Clarify which proposed interface should be implemented, then make the selected name override or complement auto-generation as specified. Done means the create command supports the agreed custom-branch workflow.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 52/100