changing comments in svn to fix errors in issue linking

Added by Clay McCoy over 9 years ago

There are actually ways to change comments in svn.

http://latcarf.com/blog/archives/102-Change-Subversion-Commit-Messages-Post-Commit.html
http://subversion.tigris.org/faq.html#change-log-msg

If I do this, will Redmine automatically reindex the links between issues and commits? Is this the best way to fix an svn commit that references the wrong issue?

Replies (2)

RE: changing comments in svn to fix errors in issue linking - Added by Eric Davis over 9 years ago

If I do this, will Redmine automatically reindex the links between issues and commits? Is this the best way to fix an svn commit that references the wrong issue?

No Redmine will not automatically reindex the links but you can remove the revisions from Redmine and have it refetch it from the svn server. Example using the project foo :

$ script/console production
p = Project.find_by_identifier("foo")
p.repository.changesets.destroy_all  # Deletes all changesets Redmine added from the svn repo
p.repository.fetch_changesets        # Re-adds all changesets from the svn repo

I've ran this myself on a production system to play with the issue linking syntax. It's not harmful but I would still recommend taking a database backup just in case.

Eric

Source: http://www.redmine.org/boards/2/topics/show/230

RE: changing comments in svn to fix errors in issue linking - Added by Thomas Lecavelier over 9 years ago

Just to add a comment to Eric method: don't try this on an huge repository, since redmine will have to refetch every changesets: the database may suffer of the implicit load.

(1-2/2)