如何在Gitolite配置中添加存储库的描述

时间:2012-10-22 15:47:12

标签: git repository gitolite

我正在使用gitolite为我的GIT服务器进行用户维护。一切正常,除了回购描述。我已经在gitolite.conf中设置了诸如“reponame = repo description”之类的repo的描述。早期版本(在v3.x之前)它的工作。现在它不起作用。我正在使用

的信息
  • gitolite v3.1
  • GIT v1.7.1
  • Perl v5.10.1

这是我的gitolite.conf文件http://pastebin.com/DYCK3uRLhttp://arulraj.net/gitolite.conf。由于该回购描述文件不是使用gitolite自动生成的,因此接收后电子邮件邮件主题和签名没有描述。我该如何解决这个问题??

3 个答案:

答案 0 :(得分:7)

我很高兴现在说它已修好了。我在gitolite post_compile部分添加了这个https://github.com/sitaramc/gitolite/blob/master/src/triggers/post-compile/update-description-file脚本。

1.打开HOME目录中的 .gitolite.rc 文件并编辑post_compile部分。

    POST_COMPILE                =>
    [
        'post-compile/ssh-authkeys',
        'post-compile/update-git-configs',
        'post-compile/update-gitweb-access-list',
        'post-compile/update-git-daemon-access-list',
        'post-compile/update-description-file',
    ],

2.然后在gitolite.conf中添加repo的描述。请参考以下

repo    testing
RW+     =   @all
desc = "GIT testing"

3.然后提交并推送您的更改。

现在自动创建说明。我的新配置文件http://pastebin.com/c8Ggfbdihttp://arulraj.net/gitolite.conf.new

答案 1 :(得分:4)

从gitolite 3.5开始,您不必放置POST_COMPILE内容。就像使用"cgit"启用ENABLE => [ 'cgit' ]选项一样。然后运行gitolite设置,然后将使用.git/description选项中的值创建gitweb.description个文件。

答案 2 :(得分:2)

来自adding a description to repos you created

ssh git@host desc -h

Watch out the WRITER_CAN_UPDATE_DESC setting以避免"致命:您未获得授权"错误。

相关问题