Skip to content

Instantly share code, notes, and snippets.

@shadyvb
Last active August 29, 2015 13:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shadyvb/8946540 to your computer and use it in GitHub Desktop.
Save shadyvb/8946540 to your computer and use it in GitHub Desktop.
[userscript] Unassigned filter in GitHub issues screen
// ==UserScript==
// @name Unassigned issues filter in GitHub
// @namespace
// @version 0.1
// @description Add unassigned issue link in issues filters
// @match https://github.com/*/*/issues*
// @copyright 2014+, Shady Sharaf <shady@sharaf.me>
// @see http://stackoverflow.com/questions/9711923/is-there-any-way-show-all-github-tickets-without-an-assignee
// ==/UserScript==
var fn = function(){
var ul = $('.filter-list.js-pjax-active'),
clone = ul.children().last().clone(),
anchor = clone.find('a')
;
if ( clone ) {
anchor.attr('href', anchor.attr('href').replace(/mentioned\/[^\/\?]+/, 'assigned/none') ).text('Unassigned');
ul.append(clone);
}
}
$(document).on('pjax:complete', function() {
fn();
});
fn();
@shadyvb
Copy link
Author

shadyvb commented Feb 11, 2014

Preview:

image

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