Yuxuan 'fishy' Wang | 61698b1 | 2013-12-20 12:55:51 -0800 | [diff] [blame] | 1 | = gerrit create-branch |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 2 | |
Yuxuan 'fishy' Wang | 61698b1 | 2013-12-20 12:55:51 -0800 | [diff] [blame] | 3 | == NAME |
David Shevitz | 9754a85 | 2018-09-24 09:46:23 -0700 | [diff] [blame] | 4 | gerrit create-branch - Create a new branch. |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 5 | |
Yuxuan 'fishy' Wang | 61698b1 | 2013-12-20 12:55:51 -0800 | [diff] [blame] | 6 | == SYNOPSIS |
Michael Ochmann | e2d76a1 | 2016-06-23 17:07:37 +0200 | [diff] [blame] | 7 | [verse] |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 8 | -- |
Michael Ochmann | e2d76a1 | 2016-06-23 17:07:37 +0200 | [diff] [blame] | 9 | _ssh_ -p <port> <host> _gerrit create-branch_ |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 10 | <PROJECT> |
| 11 | <NAME> |
| 12 | <REVISION> |
| 13 | -- |
| 14 | |
Yuxuan 'fishy' Wang | 61698b1 | 2013-12-20 12:55:51 -0800 | [diff] [blame] | 15 | == DESCRIPTION |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 16 | Creates a new branch for a project. |
| 17 | |
Yuxuan 'fishy' Wang | 61698b1 | 2013-12-20 12:55:51 -0800 | [diff] [blame] | 18 | == ACCESS |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 19 | Caller should have link:access-control.html#category_create[Create Reference] |
| 20 | permission on the project. |
| 21 | |
| 22 | Administrators do not automatically have permission to create branches. It must |
| 23 | be granted via the Create Reference permission. |
| 24 | |
Yuxuan 'fishy' Wang | 61698b1 | 2013-12-20 12:55:51 -0800 | [diff] [blame] | 25 | == SCRIPTING |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 26 | This command is intended to be used in scripts. |
| 27 | |
Yuxuan 'fishy' Wang | 61698b1 | 2013-12-20 12:55:51 -0800 | [diff] [blame] | 28 | == OPTIONS |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 29 | <PROJECT>:: |
| 30 | Required; name of the project. |
| 31 | |
| 32 | <NAME>:: |
| 33 | Required; name of the branch to be created. |
| 34 | |
| 35 | <REVISION>:: |
| 36 | Required; base revision of the new branch. |
| 37 | |
Yuxuan 'fishy' Wang | 61698b1 | 2013-12-20 12:55:51 -0800 | [diff] [blame] | 38 | == EXAMPLES |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 39 | Create a new branch called 'newbranch' from the 'master' branch of |
| 40 | the project 'myproject'. |
| 41 | |
Michael Ochmann | b99feab | 2016-07-06 14:10:22 +0200 | [diff] [blame] | 42 | ---- |
David Shevitz | 9754a85 | 2018-09-24 09:46:23 -0700 | [diff] [blame] | 43 | $ ssh -p 29418 review.example.com gerrit create-branch myproject newbranch master |
Michael Ochmann | b99feab | 2016-07-06 14:10:22 +0200 | [diff] [blame] | 44 | ---- |
Mani Chandel | 7ec4ac7 | 2013-12-10 14:50:33 +0530 | [diff] [blame] | 45 | |
| 46 | GERRIT |
| 47 | ------ |
| 48 | Part of link:index.html[Gerrit Code Review] |
| 49 | |
| 50 | SEARCHBOX |
| 51 | --------- |