Created
December 23, 2014 20:07
-
-
Save jayuen/b730a2dda7be1076b482 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
javascript:(function(){ | |
var ticketId = jQuery("#card-index").text().trim().replace("#", ""); | |
var ticketDescription = jQuery("#card-short-description").text().trim().replace(/\W/g, ' ').replace(/([A-Z][a-z])/g,'$1').replace(/\s{2,}/g, ' ').trim(); | |
var branchName = (ticketId + " " + ticketDescription).split(" ").join("_").toLowerCase(); | |
jQuery("#card-short-description").after("<h1>git checkout -b " + branchName + "</h1>") | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment