SVN automatically synchronizes project code to the Web site root for immediate updating

Source: Internet
Author: User
Tags learn php svn update
SVN believes everyone is not unfamiliar, first contact with the company's projects, you may find that their SVN has automatic synchronization to the official site features.

Isn't it magical,

The following is an example of an SVN server installed under Windows, which teaches you a few lines of code to implement this function.

Usually SVN server we use VISUALSVN server-side software, SVN uses the free Tortoise SVN software locally.

Post-commit is under the hooks directory of SVN.

The Post-commit.bat code is as follows:

@echo OffSET repos=%1set rev=%2set svn= "C:/Program files/visualsvn server/bin/svn.exe" SET dir=%repos%/hooksset PATH=% path%; SVN update f:/wroot123/--username ww--password wwrem "f:/wroot123/" directory must first checkout

Baidu also has a lot of such tutorials, but because it is too complicated, look at the look on the don't want to learn, this article is a simplified version, I hope to help you.

Learn PHP on the PHP Chinese web.

This article is edited by the PHP Chinese web,

Article Address: http://www.php.cn/php-weizijiaocheng-374260.html

Please do not reprint ~ ~ ~

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.