You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Paul Kilima <pa...@gmail.com> on 2006/10/05 15:20:59 UTC

Changing permissions after a checkout

Hello,

Our PHP framework is versioned under subversion (*). Apache is
configured so that each developer has his own virtualhost pointing to
his working copy.

I need a way to force a chmod after a checkout, so that
<framework_root>/{logs,tmp}/ directories are writable by httpd
(alternatively, chown httpd would be fine, except only root can do
that). I couldn't find help in the archive or in the free svn book.

How can I do that? Can file permissions be versioned or is this the
return of the infamous post-checkout hook? :)

Thank you!

Paul

(*) latest subversion available from Redhat RHEL 4 RPM
(subversion-1.1.4-2.ent and subversion-devel-1.1.4-2.ent, clients
access server through svnserve).

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Changing permissions after a checkout

Posted by Paul Kilima <pa...@gmail.com>.
2006/10/5, Ryan Schmidt <su...@ryandesign.com>:
> Subversion 1.1 and 1.2 are no longer supported. You should use
...

Redhat provided RPM are OK for us, even if they lag with upstream.

> Subversion does not version file permissions or ownership. If you
> require this, you can build Subversion yourself from the unofficial
> "owner-group-mode" branch:
...

Thanks for the info.

> Hooks have nothing to do with what you're trying to do, because hooks
> run on the server, but you're asking for something to happen on the
> client.

In our context, one such hook would help: we either use CLI svn logged
on the server, or run TortoiseSVN on our PCs accessing our working
copy on the server through samba (depending on which one we like
most). I do agree this is a special use though.

> What you want can most easily be accomplished by writing a wrapper
> script around the svn checkout. Instead of calling svn checkout

The problem with a wrapper script is that it does not integrate well
in our environment (CLI svn/TortoiseSVN).

I'd be great if the features you mentioned ended up in trunk (for 1.5
maybe ? :))

Thank you for your help.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: Changing permissions after a checkout

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Oct 5, 2006, at 10:20, Paul Kilima wrote:

> Our PHP framework is versioned under subversion (*). Apache is
> configured so that each developer has his own virtualhost pointing to
> his working copy.
>
> I need a way to force a chmod after a checkout, so that
> <framework_root>/{logs,tmp}/ directories are writable by httpd
> (alternatively, chown httpd would be fine, except only root can do
> that). I couldn't find help in the archive or in the free svn book.
>
> How can I do that? Can file permissions be versioned or is this the
> return of the infamous post-checkout hook? :)
>
> Thank you!
>
> Paul
>
> (*) latest subversion available from Redhat RHEL 4 RPM
> (subversion-1.1.4-2.ent and subversion-devel-1.1.4-2.ent, clients
> access server through svnserve).

Subversion 1.1 and 1.2 are no longer supported. You should use  
Subversion 1.4. David Summers provides newer RPMs for RHEL 4. Looks  
like he's up to Subversion 1.3.2, which would still be better than  
the 1.1.4 you're using. See the download page:

http://subversion.tigris.org/project_packages.html

Subversion does not version file permissions or ownership. If you  
require this, you can build Subversion yourself from the unofficial  
"owner-group-mode" branch:

http://svn.collab.net/repos/svn/branches/meta-data-versioning/

Hooks have nothing to do with what you're trying to do, because hooks  
run on the server, but you're asking for something to happen on the  
client.

What you want can most easily be accomplished by writing a wrapper  
script around the svn checkout. Instead of calling svn checkout  
yourself and expecting Subversion to properly set your directories'  
permissions, write a script which itself calls svn checkout and sets  
the permissions correctly. Then use this script when you want to  
check out, instead of running svn checkout directly.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org