[mercurial][server] Mercurialリポジトリのweb公開
DocumentRoot が /html、mercurialリポジトリが /repos/foo のとき
hgwebdir.cgi, hgweb.cgiをコピー
# mkdir /html/hg # mkdir /html/hg/foo # cp /mercurial-1.0.2/hgwebdir.cgi /html/hg/index.cgi # cp /mercurial-1.0.2/hgweb.cgi /html/hg/foo/index.cgi # chmod a+x /html/hg/index.cgi # chmod a+x /html/hg/foo/index.cgi # chown -R apache:apache /html/hg
hgwebの下記の行を修正する
h = hgweb.hgweb("/home/hg/repo-name", "name of repository") ↓ h = hgweb.hgweb("/repos/foo", "foo")
#import sys #sys.path.insert(0, "/path/to/python/lib") ↓ import sys sys.path.insert(0, "/usr/local/lib/python2.4/site-packages")
apacheのconfを修正
Alias /hg "/html/hg"DirectoryIndex index.cgi AddHandler cgi-script .cgi AllowOverride All Options ExecCGI Order allow,deny Allow from all
htpアクセス
http://xxxxx/hg/foo/ でアクセスできる