有谁帮忙给 “Git for windows" 做个补丁:”gitweb/gerrit"在Windows的集成

62 views
Skip to first unread message

Larry Cai

unread,
May 22, 2012, 9:44:52 PM5/22/12
to got...@googlegroups.com
Gitweb是Git缺省的代码网上浏览的一个模块,附带在Git发布版本中,我考虑了如何不用Apache服务器使Gitweb在Gerrit中工作,这个在搭实验和演示环境中特别有用。

看blog: http://larrycai.github.com/2012/05/19/gerrit-gitweb-windows.html

我在msysgit的github中提交了这个问题和方案  https://github.com/msysgit/git/issues/9 ,他们也同意了。只是我没有时间做这个补丁(patch)。

谁能做一下?

在你的commit 信息中联到这个issue,给我一点credit就可以了;-)

@蒋鑫:你有兴趣吗?

rgs/larry
--
True software development embraces consistent inconsistency.
blog: http://codeslife.com
weibo: http://weibo.com/larrycaiyu

Jiang Xin

unread,
May 22, 2012, 10:38:51 PM5/22/12
to GotGit
On May 23, 9:44 am, Larry Cai <larry.ca...@gmail.com> wrote:
> Gitweb是Git缺省的代码网上浏览的一个模块,附带在Git发布版本中,我考虑了如何不用Apache服务器使Gitweb在Gerrit中工作,这个在 搭实验和演示环境中特别有用。
>

我在想为什么 msysgit 没有把 git-instaweb 这个 shell 脚本加进去呢?

在非Windows环境下,执行下面的命令即可启动一个 gitweb:

git instaweb -p 8080 -d [ apache2 | lighttpd | plackup | webrick ]

即使没有安装 Apache 或是 lighttpd, 实际上还有两个选择。

* plackup: 是一个 Perl 的 webserver 实现
* webrick: 是一个 Ruby 的 webserver 实现。

webrick 很简单,只要装了 ruby 一般就装上了 webrick。启动 gitweb 只需:

git instaweb -p 8080 -d webrick

对于 Perl 的解决方案,用 cpan 安装相关的包即可。在 Mac OS X 环境下,
我进行了如下安装:

$ cpan Plack
$ cpan CGI::Emulate::PSGI
$ cpan CGI::Compile

然后执行这个命令启用 gitweb:

$ git instaweb -p 8080 -d plack

--
Jiang Xin

Larry Cai

unread,
May 22, 2012, 10:51:59 PM5/22/12
to got...@googlegroups.com
学习了,对这也是几种支持gitweb的方式。

大部分人不愿再下载(不熟悉)Perl和ruby模块,只想用Git而已,只是为了简单。

rgs/larry

2012/5/23 Jiang Xin <worldhe...@gmail.com>

--
您收到这封邮件是因为您订阅了 Google Groups "GotGit" 邮件组。
向邮件组发言很简单,发送邮件到: got...@googlegroups.com 即可。
如果不想继续收到相关邮件,发送退订邮件到 gotgit+un...@googlegroups.com
您也可以通过 Web 界面访问和配置本邮件列表:
http://groups.google.com/group/gotgit?hl=en?hl=en

Jiang Xin

unread,
May 22, 2012, 11:19:09 PM5/22/12
to GotGit
On May 23, 10:51 am, Larry Cai <larry.ca...@gmail.com> wrote:
> 学习了,对这也是几种支持gitweb的方式。
>
> 大部分人不愿再下载(不熟悉)Perl和ruby模块,只想用Git而已,只是为了简单。

git instaweb 的四种解决方案,都要启动 web server,是比较重的实现方案。
(实际上 webrick, Plack 的方案的方便程度已经接近于 hg serve 了)

对于和 Gerrit 的整合,因为 Gerrit 已经实现了 webserver,显然你提出的 Perl CGI
是最理想的整合方案。这个方案(添加对 Perl CGI 模组支持)可以在 Gerrit 中做,
也可以在 Git 中做。如果在 Git 中做,能顺便将 git instaweb 的 Plack 也支持进去
显然是最好的。

>
> rgs/larry
>
> 2012/5/23 Jiang Xin <worldhello....@gmail.com>

Larry Cai

unread,
May 23, 2012, 12:42:01 AM5/23/12
to got...@googlegroups.com
那你有空提交两个Patch吗 ? 哈哈。

rgs/larry

2012/5/23 Jiang Xin <worldhe...@gmail.com>
On May 23, 10:51 am, Larry Cai <larry.ca...@gmail.com> wrote:

Jiang Xin

unread,
May 23, 2012, 1:10:42 AM5/23/12
to GotGit
最近太忙了,Git本地化工作也耽误了。

On May 23, 12:42 pm, Larry Cai <larry.ca...@gmail.com> wrote:
> 那你有空提交两个Patch吗 ? 哈哈。
>
> rgs/larry
>

> 2012/5/23 Jiang Xin <worldhello....@gmail.com>

Larry Cai

unread,
May 23, 2012, 5:07:09 AM5/23/12
to got...@googlegroups.com
但是你可以把建议提交上去,这也很棒!

2012/5/23 Jiang Xin <worldhe...@gmail.com>
Reply all
Reply to author
Forward
0 new messages