pieter / gitbot forked from kballard/six

GitBot is the bot running in #git on Freenode

This URL has Read+Write access

gitbot /
name age message
file .gitignore Sat Mar 15 13:54:27 -0700 2008 Add .gitignore for data and config.yml [kballard]
file LICENSE Mon Jun 18 15:02:52 -0700 2007 Added a MIT license. [Sune Foldager]
file README Tue Jul 08 14:20:20 -0700 2008 Allow syntax to specify files It is now possib... [pieter]
file Rakefile Mon Jul 21 15:41:48 -0700 2008 Add a Rakefile and fix requires This adds a "t... [pieter]
file TODO.txt Mon Jun 18 22:28:40 -0700 2007 Tidying up logging Changing the timestamp to a... [Caius Durling]
file config.example Wed Aug 20 14:21:59 -0700 2008 Add a Git Manpage lookup [pieter]
file cybot.rb Thu Jul 10 06:54:36 -0700 2008 Clean up directory layout This moves plugins t... [pieter]
directory lib/ Tue Nov 03 05:27:12 -0800 2009 GitWeb source: also parse new gitweb URL's [pieter]
directory plugins/ Loading commit data...
file repositories.yaml Thu Jul 10 07:51:05 -0700 2008 Update the repositories file [pieter]
directory test/ Thu Sep 25 07:44:00 -0700 2008 GitWeb: Also handle urls with a dash in them [pieter]
README
GitBot
======

GitBot is based on "Six", the bot used in ##textmate on freenode. This bot
was forked of of "CyBot". "Six" can be found on github.com/kballard/six.

GitBot allows you to specify commits in an irc channel, and get an url to
that commit back. Currently, it only supports gitweb urls.

Repository Configuration
=======
Repositories are specified in a YAML'd version of a ruby 
hash[servername][channelname] array. An example can be found in the supplied
repositories.yaml, but the general syntax is:

---
freenode:
  channel1:
  - http://repo1
  - http://repo2
  channel2:
  - http://repo
ircnet:
 channel1:
 - http://repo

Note the explicit use of spaces. The configuration file can be specified with
the plugins/gitweb/configfile config path (see the supplied config.example).

Syntax
=======

There are two ways to trigger GitBot. The first is implicit by pasting a sha1.
This sha1 can be abbrevated (to at least 7 characters) or a full sha1. In this
case, GitBot will walk through the supplied repo list from top to bottom to
search for the sha1. On the first hit it will return the repository and a link
to the object. If the object is a commit or hash, it will also supply the
subject.

There is also an explicit syntax in the form of <(repo SP)? ref (COLON path)?>
(where SP is a space). If repo is supplied, GitBot will only look in a
repository with that name. Otherwise, it will walk all repositories. ref can
be anything like a sha1, a tag or a branch name. Commit walking is not
accepted, so "HEAD^" will fail. If GitBot cannot find the ref, it will produce
an error message. If a path is specified, GitBot will try to look up that tree
or blob and gives a url to that object once found.

Notes
======

As GitBot walks the repository list, the order in which you specify
repositories is important. In general, you should you put the "main" one on
the top. For #git, this is http://repo.or.cz/w/git.git. Alternates can be put
under it, but be careful with too many repositories as this can cause a big
load on the servers.