Improved documentation for the ciabot scripts.
[git.git] / contrib / ciabot / INSTALL
blob8253865d2261569a64842659c97262eac62339c2
1 = Installation instructions =
3 Two scripts are included.  The Python one (ciabot.py) is faster and
4 more capable; the shell one (ciabot.sh) is a fallback in case Python
5 gives your git hosting site indigestion. (I know of no such sites.)
7 It is no longer necessary to modify the script in order to put it
8 in place; in fact, this is now discouraged. It is entirely
9 configurable with the following git config variables:
11 ciabot.project = name of the project (required)
12 ciabot.repo = name of the project repo for gitweb/cgit purposes
13 ciabot.xmlrpc  = if true (default), ship notifications via XML-RPC
14 ciabot.revformat = format in which the revision is shown
16 The ciabot.repo value defaults to ciabot.project lowercased.
18 The revformat variable may have the following values
19 raw -> full hex ID of commit
20 short -> first 12 chars of hex ID
21 describe -> describe relative to last tag, falling back to short
22 The default is 'describe'.
24 Once you've set these variables, try your script with -n to see the
25 notification message dumped to stdout and verify that it looks sane.
27 After verifying correct function, install one of these scripts either
28 in a post-commit hook or in an update hook.
30 In post-commit, run it without arguments. It will query for
31 current HEAD and the latest commit ID to get the information it
32 needs.
34 In update, call it with a refname followed by a list of commits:
35 You want to reverse the order git rev-list emits because it lists
36 from most recent to oldest.
38 /path/to/ciabot.py ${refname} $(git rev-list ${oldhead}..${newhead} | tac)