[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: [PATCH] -- FAQ: more detail for "Why aren't my repository hooks working"

From: <kfogel_at_collab.net>
Date: 2005-03-02 17:02:52 CET

Eric Hanchrow <offby1@blarg.net> writes:
> I've answered this question a few times on IRC, and have decided that
> that constitutes "frequent" ... so:

Many of your patches to the FAQ and other documentation have been
applied, and really there's no reason you shouldn't be committing them
directly. (We should have realized this earlier, IMHO, it's just that
the patches were spread over a long time, so we never noticed the
accumulation.)

Anyway, if you're okay with it, just send your tigris username and a
plaintext password to

   sussman@collab.net
   cmpilato@collab.net
   fitz@collab.net
   kfogel@collab.net

and one of us will set you up as a docs committer. Naturally, you can
still post review first whenever your judgement tells you to.

In this case, your change looks good to me. Just one problem: make
sure to preserve the old anchor name ("hooks-environment"). It's fine
to add the new "hooks-debugging" name as the canonical for this
question, but we always must leave old anchors in place too, for
compatibility -- people often link directly to a question using these
anchors, and we don't want to break those old links.

You can see an example of this strategy in r11008, where we left the
name "win32-hooks" for compatibility, on this very same item. (It's
visible in the context of your patch, in fact.)

-Karl

> [[[
> Add more detail to ``Why aren't my repository hooks working?''
> ]]]
> Index: faq.html
> ===================================================================
> --- faq.html (revision 13185)
> +++ faq.html (working copy)
> @@ -182,9 +182,7 @@
> with Apache on Win32 and I'm getting an error saying that the
> module cannot be found, yet the mod_dav_svn.so file is right
> there in <tt>\Apache\modules.</tt></a></li>
> -<li><a href="#hook-environment">Why aren't my repository hooks working?
> - They're supposed to invoke external programs, but the invocations
> - never seem to happen.</a></li>
> +<li>Why aren't my repository hooks working?</li>
> <li><a href="#diff-cmd">Why does my --diff-cmd complain about '-u'?
> I tried to override it with --extensions, but it's not working.</a></li>
> <li><a href="#plaintext-passwords">Ahhh! I just discovered that my
> @@ -2388,10 +2386,12 @@
> <![CDATA[-----------------------------------------------------------]]>
>
> <a name="win32-hooks"></a> <!-- for compatibility with old question -->
> -<h3><a name="hook-environment" title="#hook-environment"
> - >Why aren't my repository hooks working?
> +<h3><a name="hook-debugging" title="#hook-debugging"
> + >Why aren't my repository hooks working?</a></h3>
> + <ul>
> + <li>
> They're supposed to invoke external programs, but the invocations
> - never seem to happen.</a></h3>
> + never seem to happen.
>
> <p>When invoking other programs from repository hook scripts, try
> using absolute paths. The environment the hooks get when Subversion
> @@ -2400,7 +2400,30 @@
> environment the hooks get when you test them by hand. In particular,
> $PATH on Unix, or %PATH% on Windows, may not have all the directories
> you expect.</p>
> -
> +</li>
> + <li>General tips</li>
> +<p>
> +If you're using Linux or Unix, try running the script "by hand", after
> + doing the following preparation:
> + <ol>
> + <li>Use "sudo" or similar to become the user who normally
> + would run the script. This might be <tt>httpd</tt> or
> + <tt>www-data</tt>, for example, if you're using Apache;
> + it might be a user like <tt>svn</tt> if you're running
> + svnserve and have created a special user.</li>
> + <li>
> + Invoke the script with the "env" program. Here's an
> + example for the post-commit hook:
> +<blockquote><pre>
> + $ env - ./pre-commit /var/lib/svn-repos 1234
> +</pre></blockquote>
> + </li>
> + <li>
> + Check your console for errors.
> + </li>
> + </ol>
> +</p>
> +</ul>
>
> <![CDATA[-----------------------------------------------------------]]>
>
> --
> We don't know how to use the security and encryption features
> of our e-mail server. We are so confused that we cannot even be
> certain that this e-mail was delivered to the proper person. So,
> if you received this e-mail because of our incompetence, please
> delete it and notify us as soon as possible. Notice that this is
> being written in the most scary legalistic way, so no one notices
> how incompetent we are.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: dev-help@subversion.tigris.org

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Mar 2 17:26:30 2005

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.