Beautify things

This commit is contained in:
Anatoliy Chakkaev 2013-03-26 23:34:01 +04:00
parent 58e2349575
commit 5e24bd960f
2 changed files with 10 additions and 8 deletions

View File

@ -28,7 +28,7 @@ docs/man/%.3: docs/%.md scripts/doc.sh
docs/html/%.3.html: docs/%.md scripts/doc.sh docs/footer.html
scripts/doc.sh $< $@
docs/html/index.html: docs/jugglingdb.md scripts/doc.sh
docs/html/index.html: docs/jugglingdb.md scripts/doc.sh docs/footer.html
scripts/doc.sh $< $@
man: $(MAN_DOCS)

View File

@ -1,15 +1,17 @@
<script>
var filename = location.href.match(/([^\/]+)?\.3.html(#.*?)?$/)[1];
var div = document.createElement('div');
div.innerHTML = 'Found a typo? ' +
linkTo('View', 'blob') + ' and ' +
linkTo('edit', 'edit') + ' this file online at GitHub.';
var filename = location.href.match(/([^\/]+)?\.3.html(#.*?)?$/);
if (filename) {
var div = document.createElement('div');
div.innerHTML = 'Found a typo? ' +
linkTo('View', 'blob') + ' and ' +
linkTo('edit', 'edit') + ' this file online at GitHub.';
document.getElementById('man').appendChild(div);
document.getElementById('man').appendChild(div);
}
function linkTo(text, dir) {
return '<a href="https://github.com/1602/jugglingdb/' +
dir + '/master/docs/' + filename + '.md">' + text + '</a>';
dir + '/master/docs/' + filename[1] + '.md">' + text + '</a>';
}
addLink('h3', '&para;');