Due to differences in server configs, migrated svn hooks don't seem to work.
Errors with pre-commit hooks can cause commits to get blocked, ref: [forge:site-support:#874]
after upgrading the megameklab project, we can't checking anything into SVN now. We get the following error:
/svn/p/megameklab/code/hooks/pre-commit: line 3: /var/local/mastertree/host/sfp-svn/hook-scripts/check-case-insensitive.py: No such file or directory
I imagine other hooks would fail similarly. We should probably also remove any unnecessary hooks and update the data on other hooks. For example, the user in [forge:site-support:#862] had the following:
-bash-3.2$ pwd /home/svn/p/callflow/code/hooks -bash-3.2$ cat post-commit #!/bin/bash # The following is required for site integration, do not remove/modify. # Place user hook code in post-commit-user and it will be called from here. curl -s http://sourceforge.net/auth/refresh_repo/p/callflow/code/ DIR="$(dirname "${BASH_SOURCE[0]}")" if [ -x $DIR/post-commit-user ]; then exec $DIR/post-commit-user "$@" -bash-3.2$ cat post-commit-user #!/bin/sh # THIS FILE IS AUTOGENERATED - DO NOT EDIT /var/local/mastertree/host/sfp-svn/hook-scripts/sf-svn-stats-hook.py $* /var/local/mastertree/host/sfp-svn/hook-scripts/keepsake -p "$1" /var/local/mastertree/host/sfp-svn/hook-scripts/svnnotify --repos-path "$1" --revision "$2" --to "callflow-svn@lists.sourceforge.net" --subject-prefix "SF.net SVN: callflow:" --subject-cx --no-first-line --with-diff --viewcvs-url "http://callflow.svn.sourceforge.net/callflow/?rev=%s&view=rev" --user-domain "users.sourceforge.net" --footer "This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site." -l /usr/bin/svnlook --max-diff-length 100000 exit 0
We should probably first remove the "AUTOGENERATED" link, since that's no longer true.
I think we can probably just remove the sf classic specific hooks (sf-svn-stats-hook.py
and keepsake
).
For svnnotify, we should fix the path (iirc, it's in the standard location /usr/bin/svnnotify/
though just svnnotify
works), and update the url to the code browser (ie., the --viewcvs-url
option)
We have a few other pre-configured hooks users can add, but we didn't allow custom hooks for svn repos on classic, so it should be a finite list.
Updated
allura:cj/5076
andforge-classic:cj/5076
Clone was being done asynchronously and was not complete when the post-processing was running.
New repos will have their SVN hooks converted properly now. Separate ticket (5076) is in queue for updating existing hooks
Originally by: maddes
The separate ticket number is the same as of this ticket. Typo?
Originally by: maddes
Could you please list the correct pathes for "check-case-insensitive.py" and "check-mime-type.pl", so I can fix my already modified hooks. Thanks.
They're both in
/usr/lib64/subversion/contrib/hook-scripts
Yeah, it's a typo. The ticket is [#5213].
Edit: But it's marked private due to containing site-specific config info. I'm working on it today, however.