blob: 308e313460bcabdbfc981ef22ccbe53525be58dc [file] [log] [blame]
John DeNisco06dcd452018-07-26 12:45:10 -04001.. _gitreview:
2
3***************************
4Merging FD.io VPP documents
5***************************
6
7This section describes how to get FD.io VPP documents reviewed and merged.
8
9Git Review
10==========
11
12The VPP documents use the gerrit server and git review.
13
14Clone with ssh
15--------------
16
17To get FD.io VPP documents reviewed the VPP repository should be cloned with ssh.
18
19Use the following to setup you ssh key
20
21.. code-block:: console
22
23 $ ssh-keygen -t rsa
24 $ keychain
25 $ cat ~/.ssh/id_rsa.pub
26
27Copy that key to the gerrit server.
28Then clone the repo with:
29
30.. code-block:: console
31
32 $ git clone ssh://gerrit.fd.io:29418/vpp
33 $ cd vpp
34
35New patch
36--------------
37
38To get a new patch reviewed use the following:
39
40.. code-block:: console
41
John DeNisco2d1a0432018-07-26 16:21:31 -040042 $ git status
43 $ git add <filename>
44 $ git commit -s
45 $ git review
John DeNisco06dcd452018-07-26 12:45:10 -040046
47If the patch is a draft use the following:
48
49.. note::
50
John DeNisco2d1a0432018-07-26 16:21:31 -040051 $ git review -D
John DeNisco06dcd452018-07-26 12:45:10 -040052
53
54To get back to the master:
55
56.. code-block:: console
57
John DeNisco2d1a0432018-07-26 16:21:31 -040058 $ git reset --hard origin/master
59 $ git checkout master
John DeNisco06dcd452018-07-26 12:45:10 -040060
61Existing patch
62--------------
63
64To modify an existing patch:
65
66
67.. code-block:: console
68
John DeNisco2d1a0432018-07-26 16:21:31 -040069 $ git status
70 $ git add <filename>
71 $ git commit --amend
72 $ git review