Hi Ryan
In pre-revprop-change, this hook is enabled
************************************************************************
**
if [ "$PROPNAME" = "svn:log" -o "$PROPNAME" = "svn:author" ]; then exit
0; fi
echo "Changing revision properties other than svn:log is prohibited" >&2
exit 1
************************************************************************
**
And I author name while editing log, but here author can be edited.
See the attachment!!
So What I want now is wherever EID comes, it should convert into Name
and I guess we can try writing a wrapper stating if the EID is this ..
User is XYZ and sends that as log message.
Please share your thoughts
Regards
R.R.Vishwanath
Desk: +91 80 26588360 Extn: 44211
Cell: +91 9632243577
-----Original Message-----
From: Ryan Schmidt [mailto:subversion-2009b_at_ryandesign.com]
Sent: Thursday, June 11, 2009 3:21 PM
To: Ramachandran, Vishwanath(IE10)
Cc: Subversion Users
Subject: Re: Is it possible to have a trigger script replace user ID
(eid) with name in error messages?
On Jun 11, 2009, at 04:08, Ramachandran, Vishwanath(IE10) wrote:
> While performing a check out and commit, I/we use username as EID
> (e12345).
> We wrote in a pre-revprop change hook script, which will function in
> such a way that both log message should be edited and author name
> should
> appear.
>
> I.e. if ["$PROPNAME" = "svn:log" -o "$PROPNAME" = "svn:author" ]; then
> ...
>
> The script was successful.
Here's the relevant part of the pre-revprop-change hook that you
asked about before and that I helped you with:
if [ "$PROPNAME" = "svn:log" -o "$PROPNAME" = "svn:author" ]; then
if [ "$USER" = "e383084" -o "$USER" = "crowdadmin" ]; then
# allow this change
exit 0
fi
fi
Let's be clear on what this does: this ALLOWS the svn:log and
svn:author revision properties to be changed by your administrative
users e383084 and crowdadmin. It does not change the property on any
revision. It only ALLOWS those properties to be changed. You haven't
yet shown any script you're using that actually changes those
properties (for example with a command like "svn propset --revprop -r
123 svn:author 'newauthor'").
> But what my user requires is on the lock
> information, we get EID (instead of name), the user also wants name in
> the lock information
>
> For e.g. Say my EID is (e12345) and I locked a file X
>
> The next day, user B comes in and locks the same file X, he gets error
> and shows him the EID of the person who owns the lock:
>
>> Error: 'e12345' in file-system <"repository path">
>
> Now, in the error instead of 'e12345' can there be a name i.e.
> 'Vishwanath'
>
> And there is no script written to change EID to name, I am trying for
> that, if you can suggest me for the script
I still don't understand how you're getting "Vishwanath" to appear
e.g. in the log if the username you connect to Subversion with is
"e12345".
------------------------------------------------------
http://subversion.tigris.org/ds/viewMessage.do?dsForumId=1065&dsMessageId=2361513
To unsubscribe from this discussion, e-mail: [users-unsubscribe_at_subversion.tigris.org].
Received on 2009-06-12 08:32:17 CEST