Scientific Linux 6
Sponsored Link

Subversion - Update Data from Repository2011/06/04

This is how to update data on server from Subversion's repository. For this example, Update data under /var/www/html from repository.
This example based on that there are no data under the directory on server in initial operation.
[1] It's necesarry to checkout to the data-directory as an initial operation on server.
# svn co [repository] [a directory you'd like to update]

[root@www ~]#
svn co file:///var/www/svn/site /var/www/html

[2] Operate like follows to update data from repository.
[root@www ~]#
svn update /var/www/html

U   /var/www/html/policy.html
Updated to revision 4.
[3] If you'd like to change properties of files, create a script like follows.
[root@www ~]#
# update data and also change owner and permission of files
# this is an example

svn update /var/www/html
find /var/www/html -type d -print0 | xargs -0 chmod 705
chown -R fermi. /var/www/html

while read FILE PERM
find /var/www/html -name "$FILE" -type f -print0 | xargs -0 chmod $PERM
done <<EOL
*.html 604
*.cgi 705
*.xml 604
*.jpg 604
*.gif 604

[root@www ~]#
chmod 700

[root@www ~]#

U /var/www/html/note.cgi
Updated to revision 9.
Matched Content