---
name: "git-refactor"
section: "1"
platform: "linux"
package: "git-extras"
version: "4.6.0-1"
release: "Debian 10 (Buster)"
platforms: ["linux"]
url: "https://new.carta.tech/git-refactor"
---

# git-refactor(1)

Create refactor branch

## NAME

**git-refactor** - Create refactor branch

## SYNOPSIS

**git-refactor** \[-r\|--remote \[remote\_name\]\] \[finish\] \<name\>

## DESCRIPTION

Create the given refactor branch

## OPTIONS

\<-r\|--remote \[remote\_name\]\>

Setup a remote tracking branch using **remote\_name**. If **remote\_name** is not supplied, use **origin** by default.

\<finish\>

Merge and delete the refactor branch.

\<name\>

The name of the refactor branch.

## EXAMPLES

```
$ git refactor mainlib_refactor
`...`
$ git commit -m "Some changes"
`...`
$ git checkout master
$ git refactor finish mainlib_refactor
$ $ git refactor -r upstream mainlib_refactor
```

## AUTHOR

Written by Jesus Espino \<*jespinog@gmail.com*\>\
 Modified by Mark Pitman \<*mark.pitman@gmail.com*\>

## REPORTING BUGS

\<*https://github.com/tj/git-extras/issues*\>

## SEE ALSO

\<*https://github.com/tj/git-extras*\>
