Usage
Description
Manage branches in your VibeHub project. List existing branches, create new ones, rename, or delete branches.
Arguments
Branch name to create. If omitted, lists all branches.
Options
List all branches (local + remote).
Show branches with last commit info.
Show tracking info and last fetch time.
Delete a branch (safe - checks if merged first).
Force delete a branch without merge check.
Rename a branch. Usage: -m <old-name> <new-name>
Set upstream tracking branch for the current branch.
Examples
List All Branches
Output:
The * indicates the current branch.
List Branches with Details
Output:
Create a New Branch
Creates a new branch from the current branch.
Delete a Branch (Safe)
This checks if the branch is fully merged before deleting.
Safe delete will fail if the branch has unmerged commits. Use -D to force delete.
Force Delete a Branch
Deletes the branch regardless of merge status.
Rename a Branch
Set Upstream Tracking
Branch Indicators
Restrictions
You cannot delete:
- The default branch
- Protected branches
- The currently checked out branch
Error Messages
Branch Already Exists
Solution: Choose a different name or checkout the existing branch.
Cannot Delete Current Branch
Solution: Switch to another branch first with vibe checkout.
Branch Not Fully Merged
Solution: Either merge the branch first or use -D to force delete.