如何最好地从颠覆更新网站 [英] How to best update a website from subversion

查看:26
本文介绍了如何最好地从颠覆更新网站的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个由 MySQL 数据库支持的 PHP 网站和一个向 Subversion 提交代码的小型程序员团队.通常我们编写代码,在本地进行测试,提交到 Subversion,然后将更改的文件复制到隐藏区域进行在线测试.

I have a PHP website backed by a MySQL database and a small team of programmers submitting code to subversion. Typically we write code, test it locally, commit to subversion and then copy changed files to a hidden area for online testing.

但是也可能会犯错误.有时我想刷新站点,以便毫无疑问地知道站点代码和数据库确实代表了颠覆中的内容.我希望尽可能接近一键式解决方案,以确保万无一失.

However mistakes can be made. Occasionally I want to refresh the site so that I know, without a doubt, that the site code and database really represents what's in subversion. I'd like to get as close to a one click solution as possible so that it's foolproof.

最好的方法是什么?

顺便说一句,如果重要的话,我们在 Windows 机器上开发.

BTW, if it matters, we develop on windows machines.

推荐答案

每次提交后都可以使用 post-commit hook 自动完成导出:

The export can be automatically done after every commit with a post-commit hook:

http://svnbook.red-bean.com/en/1.5/svn.ref.reposhooks.post-commit.html

您可以设置钩子自动导出隐藏区域内的项目以供在线测试.

You can setup the hook to automatically export the project inside the hidden area for the online testing.

这篇关于如何最好地从颠覆更新网站的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆