Skip to content

Commit ef8593f

Browse files
committed
Update git review usage.
Add more popular way to usage git review with automatic push to corresponding branch and to support update patch. Change-Id: Ica27111dd4a26bae89f022593320e4810104325b Signed-off-by: Baohua Yang <[email protected]>
1 parent 69345fa commit ef8593f

File tree

1 file changed

+20
-2
lines changed

1 file changed

+20
-2
lines changed

docs/Gerrit/gerrit.md

+20-2
Original file line numberDiff line numberDiff line change
@@ -88,14 +88,32 @@ be reversed as well.
8888
Currently, Gerrit is the only method to submit a change for review. **Please review
8989
the [guidelines](changes.md) for making and submitting a change**.
9090

91+
### Use git review
92+
9193
**Note:** if you prefer, you can use the [git-review](#git-review) tool instead
9294
of the following. e.g.
9395

96+
Add the following section to `.git/config`, and replace `<USERNAME>` with your
97+
gerrit id.
98+
9499
```
95-
cd <your clone dir>
96-
git review -R
100+
[remote "gerrit"]
101+
url = ssh://<USERNAME>@gerrit.hyperledger.org:29418/fabric.git
102+
fetch = +refs/heads/*:refs/remotes/gerrit/*
97103
```
98104

105+
Then submit your change with `git review`.
106+
107+
```
108+
$ cd <your code dir>
109+
$ git review
110+
```
111+
112+
When you update your patch, you can commit with `git commit --amend`, and then
113+
repeat the `git review` command.
114+
115+
### Not Use git review
116+
99117
Directions for building the source code can be found [here](../dev-setup/build.md).
100118

101119
When a change is ready for submission, Gerrit requires that the

0 commit comments

Comments
 (0)