Note that there are some explanatory texts on larger screens.

plurals
  1. POLetting CommitTicketUpdater work in trac with svn
    primarykey
    data
    text
    <p>I use trac as my issue tracking system, together with svn. Lately I have discovered that commit messages may also modify tickets (add comments, close them) with the distributed CommitTicketUpdater (appears in tracopt), starting from trac 0.12 (the version I use).</p> <p>This is installed on ubuntu 12.04. My post-commit code is as simple as that:</p> <pre><code>REV="$2" /usr/bin/trac-admin /var/trac/proj changeset added robo $REV </code></pre> <p>where 'robo' is the name of my repository, as defined in trac. This actually works quite well; changesets appear in trac, together with the commit message as written during svn commit. The problem is not here.</p> <p>The plugin (http://trac.edgewall.org/wiki/CommitTicketUpdater) should look for strings such as "see #22" or "fix #23" in the commit message, and update/close the relevant ticket. This is quite flexible in syntax. I've had the plugin enabled from the admin web tab (and applied changes), and even tried to upgrade (though, no upgrade was needed).</p> <p>I have configured the plugin under [ticket] in my trac.ini file so:</p> <pre><code>commit_ticket_update_envelope = commit_ticket_update_commands.close = close closed closes fix fixed fixes commit_ticket_update_commands.refs = &lt;ALL&gt; commit_ticket_update_check_perms = false commit_ticket_update_notify = false </code></pre> <p>but I have tried many other variations, including commenting some of these lines. I have also tried to put [] in the envelope option, but that did not change.</p> <p>Bottom line is that while changesets are added, nothing changes in the ticket.</p> <p>I was thinking that this might be a permissions issue. Hence, I have added TRAC_ADMIN to anonymous, but that hasn't changed anything. I have realized that I am not sure how trac handles linux users; they do not authenticate to the web server in any way... But how else can that be done?</p> <p>So I have committed with root, and it worked. So this is all about linux permissions. Though, my user belongs to 'svn' group, that has writing permission all over my project folder. This does not suffice, though, committing with root <strong>does</strong> work.</p> <p>My next direction was to add myself (and any other committer) to sudoers, with no password for the operation of that hook.</p> <p>This was done so: I have added 'hansz debi = NOPASSWD: /usr/bin/trac-admin' (where debi is the server name and hansz is my user name), and modified the post-commit line to:</p> <pre><code>sudo -u root /usr/bin/trac-admin /var/trac/proj changeset added robo $REV </code></pre> <p>That has not helped as well. Committing as root works, and as myself - not.</p> <p>This is where I stop trying, and ask for your help.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload