Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
853 views
in Technique[技术] by (71.8m points)

svn - AnkhSVN client side pre-commit hook

Basically I want to do the same thing as the fella over there.

It seems that everybody was thinking about server-side hooks (with all their evil potential).

I want a client side script be run before commit so astyle can format the code the way my boss likes to see it.

Since my IDE (VS2010Pro) automatically checks when a file changed on the disk an opts me in for reloading it, there is no real evil with all that.

Is there any (clean) way to accomplish that with AnkhSVN?

Maybe there's also a way to extend VisualStudio to call my pre-commit-script...

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

It seems like AnkhSVN is being made to use TortoiseSVN's hook scripts, as there is a conversation about it being in the nightly builds. Also the daily updates seem to mention hooks (e.g revision 10870 and revision 10873.

Try getting a daily build and seeing the subversion options in Tools->Options->Source Control->Subversion Environment in Visual Studio. If that doesn't work try opening Windows registry to HKEY_CURRENT_USERSoftwareAnkh?SVNVisualStudio?<Version>Conf?iguration (where <Version> should be 10.0 for you) and adding a string named EnableTortoiseSvnHooks with the data True, as mentioned in the above conversation link.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...