Skip to content

Instantly share code, notes, and snippets.

@devinmancuso
Last active November 11, 2015 05:03
Show Gist options
  • Save devinmancuso/2099a936f91e938a1a97 to your computer and use it in GitHub Desktop.
Save devinmancuso/2099a936f91e938a1a97 to your computer and use it in GitHub Desktop.
Acceptance Criteria Template Injection Bookmarklet
javascript:(function(e,a,g,h,f,c,b,d){
if(!(f=e.jQuery)||g>f.fn.jquery||h(f)){
c=a.createElement("script");
c.type="text/javascript";
c.src="http://ajax.googleapis.com/ajax/libs/jquery/"+g+"/jquery.min.js";
c.onload=c.onreadystatechange=function(){
if(!b&&(!(d=this.readyState)||d=="loaded"||d=="complete")){
h((f=e.jQuery).noConflict(1),b=1);
f(c).remove()}};
a.documentElement.childNodes[0].appendChild(c)
}
})
(window,document,"1.3.2",function($,L){
$("textarea#description").val("
h3. Assumptions\r\n
#\r\n
#\r\n
\r\n
h3. Acceptance Use Cases\r\n
\r\n
h4. UC01\r\n
*Scenario:* Single line description of the use case.\r\n
*GIVEN*\r\n
*AND*\r\n
*THEN*\r\n
\r\n
h3. Other Notes\r\n
\r\n")
});
// Props to Ben Alman's bookmarklet boilerplate http://benalman.com/projects/run-jquery-code-bookmarklet/
!function(n,e,r,t,o,a,c,i){(!(o=n.jQuery)||r>o.fn.jquery||t(o))&&(a=e.createElement("script"),a.type="text/javascript",a.src="http://ajax.googleapis.com/ajax/libs/jquery/"+r+"/jquery.min.js",a.onload=a.onreadystatechange=function(){c||(i=this.readyState)&&"loaded"!=i&&"complete"!=i||(t((o=n.jQuery).noConflict(1),c=1),o(a).remove())},e.documentElement.childNodes[0].appendChild(a))}(window,document,"1.3.2",function(n){n("textarea#description").val("\n h3. Assumptions\r\n\n #\r\n\n #\r\n\n \r\n\n h3. Acceptance Use Cases\r\n\n \r\n\n h4. UC01\r\n\n *Scenario:* Single line description of the use case.\r\n\n *GIVEN*\r\n\n *AND*\r\n\n *THEN*\r\n\n \r\n\n h3. Other Notes\r\n\n \r\n")});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment