Skip to content

Instantly share code, notes, and snippets.

@lorin
Forked from dwcramer/logabuglinktest
Created September 22, 2013 01:04
Show Gist options
  • Save lorin/6655674 to your computer and use it in GitHub Desktop.
Save lorin/6655674 to your computer and use it in GitHub Desktop.
<a id="logABugLink" href="">Log a bug</a>
<script language="JavaScript">
var bugTitle = "4.1. Simplicity in Cloud Files™ Introduction - API v1";
var buildTime = "Built 20130918T23 04 24Z05 00"
var docUrl = "at url " + window.location.pathname;
var gitSha = "git SHA a997cbc1" ;
var gitRepo = "git Repo git@github.rackspace.com:IX/cloud-files.git ";
var lineFeed = "%0A";
var fieldComment = encodeURI(buildTime) + lineFeed + encodeURI(gitSha) + lineFeed + encodeURI(docUrl) + lineFeed + encodeURI(gitRepo);
var urlBase = "https://bugs.launchpad.net/openstack-manuals/+filebug?field.title="
var bugLink = urlBase + encodeURIComponent(bugTitle) + "&field.comment=" + fieldComment ;
document.write("<br/><br/>bugLink="+bugLink);
document.getElementById("logABugLink").href=bugLink;
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment