【发布时间】:2011-02-10 04:06:44
【问题描述】:
我尝试通过 XAMPP Apache 通过 CGI Python 脚本 hgwebdir.cgi 发布多个现有的 mercurial 存储库位置...如本教程中的https://www.mercurial-scm.org/wiki/HgWebDirStepByStep
当我尝试使用浏览器访问存储库路径时,我从 apache 错误日志中收到以下错误:
脚本头提前结束:hgwebdir.cgi
[Tue Apr 20 16:00:50 2010] [error] [client 91.67.44.216] Premature end of script headers: hgwebdir.cgi
[Tue Apr 20 16:00:50 2010] [error] [client 91.67.44.216] File "C:/hostdir/xampp/cgi-bin/hg/hgwebdir.cgi", line 39\r
[Tue Apr 20 16:00:50 2010] [error] [client 91.67.44.216] test = c:/hostdir/mercurial/test/\r
[Tue Apr 20 16:00:50 2010] [error] [client 91.67.44.216] ^\r
[Tue Apr 20 16:00:50 2010] [error] [client 91.67.44.216] SyntaxError: invalid syntax\r
这是脚本失败的文件路径(如果我删除它,我会得到一个空的 HTML 页面,其中没有可视元素):
[paths]
test = c:/hostdir/mercurial/test/
/hg = c:/hostdir/mercurial/**
/ = c:/hostdir/mercurial/
有人知道吗?
【问题讨论】:
标签: windows apache mercurial cgi xampp