gitosis 没有自动生成 projects.list,gitweb 无法工作

标签 git gitosis

我设置了一个 gitosis 管理的 git 服务器。

git clone 没问题。

但是当我通过 gitweb.conf 如下设置 gitweb 时:


$projectroot = "/srv/gitosis/repositories";

$git_temp = "/tmp";

$home_text = "indextext.html";

$projects_list = "/srv/gitosis/gitosis/projects.list";

$stylesheet = "/gitweb/gitweb.css";

$logo = "/gitweb/git-logo.png";

$favicon = "/gitweb/git-favicon.png";

顺便说一句,commet 已被删除,因为特殊符号 # 用作粗体前缀。

通过“http://localhost/cgi-bin/gitweb.cgi”访问gitweb报“403 Forbidden - No projects found

我检查了 projects.list 文件是空的,这是 gitweb 访问失败的原因吗? 什么是正确的内容?我可以手动添加吗?

最佳答案

对于要通过 gitweb 发布的每个项目,您都需要在 gitosis.conf 中使用它:

[repo myreponame]
gitweb = yes

还可以选择添加 ownerdescription

您可以在 gitosis 的 documentation 中找到更多信息, 链接自 author's website .

关于gitosis 没有自动生成 projects.list,gitweb 无法工作,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1783516/

相关文章:

linux - Git 找不到存储库

gitosis + git 错误 : fatal: '/home/git/repositories/idea-generator.git' does not appear to be a git repository

git - gitosis 的接收后 Hook

当 .gitignore 中排除了父文件夹时,Git 包含任意嵌套的子文件夹

git - 如何在 Git 中执行 "hg backout X"?

git - 我刚刚在哪个 git 分支?

git bash : git@server: command not found

git - 我可以在 git 中检索已创建、暂存、从未提交但随后被删除的文件吗?

git - 我可以将 .gitmodules 文件放在子目录中吗?

Gitosis 和 ssh key - 电子邮件地址与 git 电子邮件地址有什么关系吗?