svn directory as webroot
What I would like to do is point the webroot from my dev webserver to some dir that is in some way li开发者_高级运维nked to svn so when I commit changes they will be automatically visible on my dev webserver.
Any clue how I can do this?
EDIT
i'm creating a django project so i'm justing the Django development server
You can make your wwwroot a working copy of the svn repository, by checking it out from the server. To get the automatic updates working, you'll either have to look into a post-commit hook or have a cron job (or similar) run a task to update the wwwroot every X minutes or so.
Generally, you will want to check your website out into a directory that you use as your web root, and then set up a Subversion post-commit hook that will check out the latest version into that directory every time someone commits a new version.
Having a production server auto-update is probably not a great idea. But if you'd like to do that with dev boxes, look into a continuous integration service like Hudson. It can watch your source repository and automatically update one or more working copies every time you commit code. If you have any other work which needs to be done (eg, execute builds, restart daemons/services, flush some caches, etc.), this can do that work as well.
精彩评论