Skip to end of banner
Go to start of banner

How to create issue or update status using runFromCsv

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 30 Current »

This document explains the usage of the 'Jira Command Line Interface (CLI) - runFromCsv' action to create subtask(s) or issues using  or update the status of the issues using the transitionIssue action.

Status is a workflow concept (not the regular JIRA field). It must be updated by workflow progression.

Instructions

Create issue(s) using the CLI action

The following action will create issue of type sub-task(s) only.

./jira.sh --action runFromCsv --file "samplefile.csv" --common "--action createIssue --continue"

For this, the CSV file should contain the fields: project, summary, type and parent.

CLI result: When you run the above CLI createIssue action the result will be shown as below.

Run: --project "WUC" --summary "new by run from csv" --type "Sub-task" --parent "WUC-805" --action createIssue  --continue
Issue WUC-826 created with id 19408 as subtask of WUC-805. 

Run: --project "WUC" --summary "new1" --type "Sub-task" --parent "WUC-811" --action createIssue  --continue
Issue WUC-827 created with id 19409 as subtask of WUC-811. 

Run completed successfully. 2 actions were successful from file: samplefile.csv

Update the status of the issue(s), run the CLI action:

When u have a list of issue and you want to change the status of the issue, then run the following CLI action.

./jira.sh --action runFromCsv --file "samplefiletoupdate.csv" --common "--action transitionIssue --continue"

For this, the CSV file should contain the fields: issue and transition. The value(s) under issue should be the issue key(s) you want to update the status and the values under transition is to what status you want to transit the issue.

CLI result: When you run the above CLI transitionIssue action the result will be shown as below.

Run: --issue "WUC-802" --transition "Reopen" --action transitionIssue  --continue
Successfully transitioned issue WUC-802 with transition 'Reopen'.

Run: --issue "WUC-803" --transition "Done" --action transitionIssue  --continue
Successfully transitioned issue WUC-803 with transition 'Done'.



  • Before implementing it in the production environment, ensure the mentioned CLI action is tested in your non-production environment.
  • Ensure that the parameters server, user and password are mentioned in the jira.sh / jira.bat file.
  • Both CLI actions can be executed independently.
  • No labels