summaryrefslogtreecommitdiffstats
path: root/Documentation/cmd-index.txt
blob: 8a6cb6d3bc94cee74c94531e7e5e40f90eee16ab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
Gerrit Code Review - Command Line Tools
=======================================

Client
------

Client commands and hooks can be downloaded via scp, wget or curl
from Gerrit's daemon, and then executed on the client system.

To download a client command or hook, use scp or an http client:

  $ scp -p -P 29418 john.doe@review.example.com:bin/gerrit-cherry-pick ~/bin/
  $ scp -p -P 29418 john.doe@review.example.com:hooks/commit-msg .git/hooks/

  $ curl http://review.example.com/tools/bin/gerrit-cherry-pick
  $ curl http://review.example.com/tools/hooks/commit-msg

For more details on how to determine the correct SSH port number,
see link:user-upload.html#test_ssh[Testing Your SSH Connection].

[[client_commands]]Commands
~~~~~~~~~~~~~~~~~~~~~~~~~~~

link:cmd-cherry-pick.html[gerrit-cherry-pick]::
  Download and cherry-pick one or more changes (commits).

[[client_hooks]]Hooks
~~~~~~~~~~~~~~~~~~~~~

Client hooks can be installed into a local Git repository, improving
the developer experience when working with a Gerrit Code Review
server.

link:cmd-hook-commit-msg.html[commit-msg]::
  Automatically generate `Change-Id: ` tags in commit messages.


Server
------

Aside from the standard Git server side actions, Gerrit supports
several other commands over its internal SSH daemon.  As Gerrit does
not provide an interactive shell, the commands must be triggered
from an ssh client, for example:

  $ ssh -p 29418 review.example.com gerrit ls-projects

For more details on how to determine the correct SSH port number,
see link:user-upload.html#test_ssh[Testing Your SSH Connection].

[[user_commands]]User Commands
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

git upload-pack::
	Standard Git server side command for client side `git fetch`.

link:cmd-receive-pack.html[git receive-pack]::
	Standard Git server side command for client side `git push`.
+
Also implements the magic associated with uploading commits for
review.  See link:user-upload.html#push_create[Creating Changes].

link:cmd-review.html[gerrit approve]::
	Alias for 'gerrit review'.

link:cmd-ls-projects.html[gerrit ls-projects]::
	List projects visible to the caller.

link:cmd-query.html[gerrit query]::
	Query the change database.

link:cmd-review.html[gerrit review]::
	Verify, approve and/or submit a patch set from the command line.

link:cmd-stream-events.html[gerrit stream-events]::
	Monitor events occuring in real time.

gerrit receive-pack::
	Legacy alias for `git receive-pack`.

[[admin_commands]]Adminstrator Commands
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

link:cmd-create-account.html[gerrit create-account]::
	Create a new batch/role account.

link:cmd-create-group.html[gerrit create-group]::
	Create a new account group.

link:cmd-create-project.html[gerrit create-project]::
	Create a new project and associated Git repository.

link:cmd-flush-caches.html[gerrit flush-caches]::
	Flush some/all server caches from memory.

link:cmd-gsql.html[gerrit gsql]::
	Administrative interface to active database.

link:cmd-set-project-parent.html[gerrit set-project-parent]::
	Change the project permissions are inherited from.

link:cmd-show-caches.html[gerrit show-caches]::
	Display current cache statistics.

link:cmd-show-connections.html[gerrit show-connections]::
	Display active client SSH connections.

link:cmd-show-queue.html[gerrit show-queue]::
	Display the background work queues, including replication.

link:cmd-replicate.html[gerrit replicate]::
	Manually trigger replication, to recover a node.

link:cmd-kill.html[kill]::
	Kills a scheduled or running task.

link:cmd-show-queue.html[ps]::
	Alias for 'gerrit show-queue'.

link:cmd-suexec.html[suexec]::
	Execute a command as any registered user account.

GERRIT
------
Part of link:index.html[Gerrit Code Review]