Project

General

Profile

Command line ticket creation/modification?

Added by Robert Chady about 16 years ago

Howdy, I was wondering if there was a way to create and/or modify tickets from the command line? I have a scenario where I need to create a bunch of tickets automatically and need to be able to tie it in to some other scripts.

Thanks in advance.

--Robert


Replies (3)

RE: Command line ticket creation/modification? - Added by Kazuyoshi Tlacaelel almost 16 years ago

Really? is this the only tool available?
what about other things like:

$ git commit -a -m '#43 makes the world rotate in reverse!'

that will create a link on the [#43] to the issue number 43.
is the only thing I've been able to find out just by chance
while commiting various things.

Does somebody know if there is more features like this?
I've been looking in the documents but I haven't found any!

It would be really nice if the commit message gets appended to the ticket!

RE: Command line ticket creation/modification? - Added by Kazuyoshi Tlacaelel over 15 years ago

Thanks for the reply, well there is no documentation anywhere so I had to dive into the code
figured it out.

well basically I had to dive into the code:

  1. Redmine links #
  2. Examples:
  3. Issues:
  4. #52 -> Link to issue #52
  5. Changesets:
  6. r52 -> Link to revision 52
  7. commit:a85130f -> Link to scmid starting with a85130f
  8. Documents:
  9. document#17 -> Link to document with id 17
  10. document:Greetings -> Link to the document with title "Greetings"
  11. document:"Some document" -> Link to the document with title "Some document"
  12. Versions:
  13. 0.7.1 -> Link to version with id 3
  14. version:1.0.0 -> Link to version named "1.0.0"
  15. version:"1.0 beta 2" -> Link to version named "1.0 beta 2"
  16. Attachments:
  17. attachment:file.zip -> Link to the attachment of the current object named file.zip
  18. Source files:
  19. source:some/file -> Link to the file located at /some/file in the project's repository
  20. source:some/file@52 -> Link to the file's revision 52 # source:some/file#L120 -> Link to line 120 of the file
  21. source:some/file@52#L120 -> Link to line 120 of the file's revision 52
  22. export:some/file -> Force the download of the file
  23. Forum messages:
  24. RE: E-mails from redmine.org` -> Link to message with id 1218

I did some changes so when you checkin something related to a ticket it shows in the issue
also a lot of really ugly code that shouln't be where it is and moved the repository to the bottom and putted recent commits at the top instead.

also diff links are now clickable right away from the latest commits and the commits shown in
the issues.

only tested it under git, I have no clue what it looks like in svn
so use some bits of the code or just apply the patch if you find it ok to leave all the other ugly patches I added.

enjoy!

patch.diff (8.33 KB) patch.diff patch
    (1-3/3)