blob: 68f686d859a62bc590b69a01463babc619d13870 [file] [log] [blame]
git-receive-pack - Receive what is pushed into the repository
'git receive-pack'
[--reviewer <address> | --re <address>]
[--cc <address>]
Invoked by 'git push' and updates the project's repository with
the information fed from the 'git push' end.
End users can supply options to this command by passing them through
to 'git push', which will relay them automatically.
The remote repository that will receive the pushed objects,
and create (or update) changes. Within Gerrit Code Review
this is the name of a project. The optional leading `/`
and or trailing `.git` suffix will be removed, if supplied.
--reviewer <address>::
--re <address>::
Automatically add <address> as a reviewer to any change
created or updated by the pushed commit objects. These
changes will appear in the reviewer's dashboard, and will
also be emailed to the reviewer.
May be specified more than once to request multiple reviewers.
This is a Gerrit Code Review specific extension.
--cc <address>::
Carbon-copy <address> on the created or updated changes,
but don't request them to perform a review. Like with
--reviewer the changes will appear in the CC'd user's
dashboard, and will be emailed to them.
May be specified more than once to specify multiple CCs.
This is a Gerrit Code Review specific extension.
Above <address> may be the complete email address, or, if Gerrit is
configured with HTTP authentication (e.g. within a single domain),
just the local part (typically username).
Any user who has configured an SSH key.
Send a review for a change on the master branch to
git push --receive-pack='git receive-pack --reviewer' ssh:// HEAD:refs/for/master
Send reviews, but tagging them with the topic name 'bug42':
git push --receive-pack='git receive-pack --reviewer' ssh:// HEAD:refs/for/master/bug42
Also CC two other parties:
git push --receive-pack='git receive-pack --reviewer --cc --cc' ssh:// HEAD:refs/for/master
Configure a push macro to perform the last action:
git config remote.charlie.url ssh://
git config remote.charlie.push HEAD:refs/for/master
git config remote.charlie.receivepack 'git receive-pack --reviewer --cc --cc'
afterwards `.git/config` contains the following:
[remote "charlie"]
url = ssh://
push = HEAD:refs/for/master
receivepack = git receive-pack --reviewer --cc --cc
and now sending a new change for review to charlie, CC'ing both
alice and bob is much easier:
git push charlie
* link:user-upload.html[Uploading Changes]
Part of link:index.html[Gerrit Code Review]