Git Town provides these additional Git commands:
- git town hack - cuts a new up-to-date feature branch off the main branch
- git town sync - updates the current branch with all ongoing changes
- git town new-pull-request - create a new pull request
- git town ship - delivers a completed feature branch and removes it
- git town kill - removes a feature branch
- git town prune-branches - delete all merged branches
- git town rename-branch - rename a branch
- git town append - insert a new branch as a child of the current branch
- git town prepend - insert a new branch between the current branch and its parent
- git town repo - view the repository homepage
Git Town Configuration
- git town config - displays or updates your Git Town configuration
- git town new-branch-push-flag - configures whether new empty branches are pushed to origin
- git town main-branch - displays or sets the main development branch for the current repo
- git town offline - enables/disables offline mode
- git town perennial-branches - displays or updates the perennial branches for the current repo
- git town pull-branch-strategy - displays or sets the strategy with which perennial branches are updated
- git town set-parent-branch - updates a branch's parent
Git Town Installation
- git town alias - adds or removes shorter aliases for Git Town commands
- git town completions - generates completion scripts for Bash, zsh, fish & PowerShell.
- git town version - displays the installed version of Git Town
See the installation instructions for more details.
Git Town commands can be
aliased to remove the
git town alias true
After executing this, you can run
git hack instead of
git town hack. You can
also set this manually for individual commands:
git config --global alias.hack 'town hack'
Git Town prompts for required configuration information during usage. Use the git town config command to manage the stored configuration.
- the main development branch
- the perennial branches
These configuration options have defaults, so the configuration wizard does not ask about them.
pull branch strategy
- how to sync the main branch / perennial branches with their upstream
- possible values:
new branch push flag
- whether or not branches created by hack / append / prepend should be pushed to remote repo
- possible values:
git town for an overview of the Git Town commands and
git help <command>
git help sync) for help with individual commands.
Does my whole team have to use Git Town?
No. Just make sure that all feature branches get squash-merged, for example by requiring this in your GitHub settings. If you don't know what squash-merges are, you probably want to enable them.
Thanks to our sponsors for their continued support!
Kudos to our contributors!