diff --git a/modules/project/pages.js b/modules/project/pages.js index 2adedc4..7d964de 100644 --- a/modules/project/pages.js +++ b/modules/project/pages.js @@ -4,16 +4,26 @@ var exec = require('child_process').exec, var pages = function(dbot) { var quoteCat = dbot.db.quoteArrs[dbot.config.name], - rev, diff, branch; + rev, diff, branch, credit, authors = []; + exec("git log --format='%cN¬' | sort -u | tr -d '\n'", function (error, stdout, sderr) { + var credit = stdout.split("¬"); // nobody uses ¬, do they? + for (var i = 0; i < credit.length; i++) { + if ((credit[i].split(" ").length) == 2){ + console.log(credit[i]); + authors.push(credit[i]); + } + } + }); exec("git rev-list --all | wc -l", function(error, stdout, stderr) { - rev = stdout + rev = stdout; }); exec("git rev-parse --abbrev-ref HEAD", function(error, stdout, stderr) { branch = stdout }); + exec("git log -1", function(error, stdout, stderr) { diff = stdout }); @@ -34,7 +44,7 @@ var pages = function(dbot) { res.render('project', { "configList": dbot.modules.project.api.configList(), - "authors": dbot.modules.project.api.getAuthors(), + "authors": authors, //dbot.modules.project.api.getAuthors(), "credits": dbot.t("credits"), "thanks": dbot.t("thanks"), "name": dbot.config.name, diff --git a/public/project.css b/public/project.css index 0659a28..6b36846 100644 --- a/public/project.css +++ b/public/project.css @@ -59,6 +59,7 @@ ul { text-align:center; margin-left:0; margin-bottom:5px; + font-size:80%; } li { background-image: linear-gradient(to bottom, #f5ebe2, #f5e6d8); diff --git a/views/project/project.jade b/views/project/project.jade index ddc04c5..9f5e3cd 100644 --- a/views/project/project.jade +++ b/views/project/project.jade @@ -50,7 +50,7 @@ html(lang='#{curr839}') #{credits} p.center #{thanks} - ul + ul#credits each author in authors li #{author} section#config