Ticket #96 (closed enhancement: fixed)
Opened 8 years ago
Last modified 3 months ago
Automatic closing of ticket after check in
| Reported by: | kmr@… | Owned by: | jonas |
|---|---|---|---|
| Priority: | low | Milestone: | 0.7 |
| Component: | ticket system | Version: | 0.5.1 |
| Severity: | normal | Keywords: | |
| Cc: | |||
| Release Notes: | |||
| API Changes: | |||
Description
It would be handy if checking in the fix for a ticket could automatically
close the ticket. For example the comment for [112] says that it "fixes
#50" and then the next thing in the timeline is: "Ticket #50 closed by
daniel"
This could be streamlined if Trac could spot the "fixes #50" in the
comment and close the ticket, perhaps after adding a comment to the
ticket saying "Fixed by [112]".
To avoid accidental closing of tickets perhaps the syntax in the check
in message should be something like:
[fixes #50]
Attachments
Change History
comment:1 Changed 8 years ago by jonas
- Milestone set to 0.6
comment:2 Changed 8 years ago by daniel
I agree, it's better to do this in a post-commit script in svn.. Thinking about it, there's a possible (and entirely subjective perspective of the individual team) advantage of not closing tickets automatically - an extra round of auditing, or at least eyeballing, of patches coming in before closing the related ticket.
Just a thought. It is a neat and useful feature though.
There's more stuff we could do in post-commit too, like synchronize the db or mop the floor :-)
comment:3 Changed 8 years ago by jonas
- Status changed from new to assigned
comment:4 Changed 8 years ago by jonas
- Milestone changed from 0.6 to 0.7
The script was added to the repository in [294]. I'm still leaving this ticket open until the script has some sort of documentation in the wiki. This won't block 0.6 any more though.
comment:5 Changed 8 years ago by daniel
- Resolution set to fixed
- Status changed from assigned to closed
Fixed in [294].
comment:6 Changed 6 years ago by anonymous
More about automatically changing tickets with SCM commits can be found
in this FAQ entry
or search for "trac-post-commit-hook"
It took me a bit too long to find that info, this ticket was my first
Google hit. Hopefully this comment will save some people some time :)
comment:7 Changed 3 months ago by anonymous
The link (mentioned above) is has moved to: http://trac.edgewall.org/wiki/TracFaq#can-trac-automatically-update-a-ticket-when-i-commit-a-changeset



Yes, this is a good idea, the debian bug tracking system does something similar.
But we don't want to force this behavour on people, so a simple (optional)
svn post commit script might be a better idea…