Skip to content

Instantly share code, notes, and snippets.

@ksrb
Last active April 20, 2017 16:17
Show Gist options
  • Save ksrb/5d42bc8830bc1a4a9c070120f84a36b6 to your computer and use it in GitHub Desktop.
Save ksrb/5d42bc8830bc1a4a9c070120f84a36b6 to your computer and use it in GitHub Desktop.
Jira task list bookmarklet
javascript:(function() {
var tasks = '';
$('.ghx-swimlane:not(:nth-last-child(2))').each(function(i, elem) {
var taskTitle = $(elem).find('.ghx-parent-key').text() + ' ';
tasks += taskTitle;
var taskSummary = $(elem).find('.ghx-heading .ghx-summary').text();
if (taskSummary.substring(0, 7) === 'Flagged') {
tasks += taskSummary.substring(7, taskSummary.length) + '\n';
} else {
tasks += taskSummary + '\n';
}
});
var $otherIssues = $('.ghx-swimlane').last();
$otherIssues.find('.ghx-issue').each(function(i, elem) {
var taskTitle = $(elem).find('.ghx-key a').attr('title');
var taskSummary = $(elem).find('.ghx-summary').attr('title');
tasks += taskTitle + ' ' + taskSummary + '\n';
});
console.log(tasks);
}());
@ksrb
Copy link
Author

ksrb commented Mar 9, 2017

Bookmarklet for printing out Jira tickets

Install
Bookmarks -> Bookmark Manager/cmd + alt + b -> Right click -> Add Page -> Paste script into URL

Use

  • In Jira select 'Only My Issues'
  • Open dev console/cmd + alt + i
  • Click bookmarklet
  • Profit

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment