solitasty.blogg.se

Jira client gem
Jira client gem




  1. #Jira client gem update#
  2. #Jira client gem code#

#Jira client gem code#

Doing this from code is harder, but JIRA::Client::Automated makes it as easy as possible. Transitioning an issue is what happens when you click the button that says "Resolve Issue" or "Start Progress" on it. $jira->transition_issue($key, $transition, $update_hash) $jira->transition_issue($key, $transition) So in those cases you'll need to pass in an "update_hash" which will be transformed to the proper JSON by the method. Each JIRA installation will have different fields available for each issue type and transition screen and only you will know what they are. Updating and transitioning issues is more complex. The same for closing and deleting issues. When you create a new issue, you can pass in just the pieces you want and "create_issue" will transform them to JSON for you. JIRA::Client::Automated tries to be nice to you and not make you deal directly with JSON. When you work with an issue in JIRA's REST API, it gives you a JSON file that follows this spec: Your mileage may vary with future versions.

jira client gem

This module was designed for the JIRA 5.2.11 REST API, as of March 2013, but it works fine with JIRA 6.0 as well.

#Jira client gem update#

Reading their tutorials is *highly* recommended before you start making hashes to update or transition issues. By virtue of being complete it is also somewhat large and a little complex for the beginner. WORKING WITH JIRA 6 Atlassian has made a very complete REST API for recent (> 5.0) versions of JIRA. If it does already exist you can add a comment or a new error log to that issue. If you want to avoid creating the same issue more than once you can search JIRA for it first, only creating it if it doesn't exist. You can attach error log files to the issues and then they'll be waiting in someone's open issues list when they arrive at work the next day. This module is explicitly designed to easily create and close issues within a JIRA instance via automated scripts.įor example, if you run nightly batch jobs, you can use JIRA::Client::Automated to have those jobs automatically create issues in JIRA for you when the script runs into errors. JIRA::Client::Automated is an adapter between any automated system and JIRA's REST API.

jira client gem

$jira->add_issue_watchers($key, $watcher1. $jira->close_issue($key, $resolve, $comment) # resolve is the resolution value # if you know Jira issue hash structure well. # A complex but flexible way to create a new issue, story, task or subtask My $subtask = $jira->create_subtask($project, $summary, $description, $parent_key)

jira client gem

My $issue = $jira->create_issue($project, $type, $summary, $description) $jira->trace(1) # enable tracing of requests and responses My $jira_ua = $jira->ua() # to add in a proxy My $jira = JIRA::Client::Automated->new($url) # If your JIRA instance does not use username/password for authorization My $jira = JIRA::Client::Automated->new($url, $user, $password)






Jira client gem