1. $ sudo aptitude update
$ sudo aptitude install git-core gitweb
$ sudo aptitude install apache2
2. $ sudo mkdir /var/www/git
$ sudo cat /etc/apache2/conf.d/git
Allow from all
AllowOverride all
Order allow,deny
Options ExecCGI
SetHandler cgi-script
DirectoryIndex gitweb.cgi
SetEnv GITWEB_CONFIG /etc/gitweb.conf
3. $ sudo cp /usr/share/gitweb/* /var/www/git
4. $ sudo cp /usr/lib/cgi-bin/gitweb.cgi /var/www/git
5. $ sudo cat /etc/gitweb.conf
$projectroot = '/opt/work/git/';
$git_temp = "/tmp";
#$home_link = $my_uri || "/";
$home_text = "indextext.html";
$projects_list = $projectroot;
$stylesheet = "/git/gitweb.css";
$logo = "/git/git-logo.png";
$favicon = "/git/git-favicon.png";
6. $ sudo /etc/init.d/apache2 reload
7.
阅读(788) | 评论(0) | 转发(0) |