如何获取包含 diff 链接的 CVS 通知电子邮件?

发布于 2024-09-01 13:32:33 字数 322 浏览 7 评论 0 原文

有没有办法让 CVS 电子邮件通知包含指向我的 ViewCVS 服务器的链接,在其中单击链接可以显示差异?

目前我的 loginfo 文件只有这样的条目 ^安装猫| /usr/bin/Mail -s "[cvs-update 安装]" [电子邮件受保护]

然后我们收到的电子邮件(我想是相当标准的)包含提交消息和更改的文件列表。

干杯, 罗

Is there any way to get CVS e-mail notifications to inlude links to my ViewCVS server where clicking a link could bring up the diff ?

Currently my loginfo file just has entries like this
^installation cat | /usr/bin/Mail -s "[cvs-update installation]" [email protected]

The e-mails we all then get (Afairly standard I imagine) contain the commit message and list of files changed.

Cheers,
Ro

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

帅的被狗咬 2024-09-08 13:32:33

我不知道 ViewCVS 是否可以做到这一点,但我知道 WebSVN 可以做到这一点,尽管这需要您从 CVS 转换为 SVN。

这是 来自我的 WebSVN 差异的链接文本。如果 ViewCVS 没有办法做到这一点,您也可以自己编写 ViewCVS 的扩展,使用 enscript 突出显示

EDTI:ViewCVS 支持此功能,您似乎可以通过扩展提交后挂钩脚本来实现此目的(我假设这就是您发送通知电子邮件的方式)。

格式似乎是:

http://yoursite/cgi-bin/viewvc.cgi/path/to/change/name_of_changed_file?view=diff&r1=insert_head_num_here&r2=insert_head_num_minus_one_here&diff_format=h

例如,来自gentoo的viewcvs存储库。

http://sources.gentoo.org/cgi-bin/viewvc.cgi/path-sandbox/trunk/COPYING?view=diff&r1=363&r2=8&diff_format=h

由于 diff 的 URL 具有给定的格式,因此您应该能够将每次提交的信息处理为一系列链接,每个链接都指向已更改文件的 diff。

希望这有帮助

I don't know if this is possible with ViewCVS, but I know it's possible with WebSVN, though that would require you to convert from CVS to SVN.

Here's an link text from my WebSVN of a diff. It's probably also possible for you to write an extension to ViewCVS yourself if ViewCVS doesn't have a way to do it, using enscript highlighting

EDTI: This is supported in ViewCVS, and it seems that you could probably do this by extending your post-commit hook script (I'm assuming that's how you doing notification emails).

The format seems to be:

http://yoursite/cgi-bin/viewvc.cgi/path/to/change/name_of_changed_file?view=diff&r1=insert_head_num_here&r2=insert_head_num_minus_one_here&diff_format=h

For example, from gentoo's viewcvs repository.

http://sources.gentoo.org/cgi-bin/viewvc.cgi/path-sandbox/trunk/COPYING?view=diff&r1=363&r2=8&diff_format=h

Since the URL to the diff has a given format, you should be able to process the information from each commit into a series of links, each link pointing to a diff for a changed file.

Hope that's helpful

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文