3
0
mirror of https://github.com/reality/dbot.git synced 2024-12-12 13:59:26 +01:00

Merge git://github.com/reality/depressionbot into database

This commit is contained in:
reality 2013-04-22 19:37:44 +00:00
commit cca4fadc42
6 changed files with 116 additions and 52 deletions

24
LICENCE
View File

@ -1,18 +1,14 @@
Copyright (c) 2012-2013 Luke Slater (tinmachin3@gmail.com) Copyright (c) 2012-2013 Luke Slater (tinmachin3@gmail.com)
Permission is hereby granted, free of charge, to any person obtaining a copy of This program is free software: you can redistribute it and/or modify
this software and associated documentation files (the "Software"), to deal in it under the terms of the GNU General Public License as published by
the Software without restriction, including without limitation the rights to the Free Software Foundation, either version 3 of the License, or
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of (at your option) any later version.
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:
The above copyright notice and this permission notice shall be included in all This program is distributed in the hope that it will be useful,
copies or substantial portions of the Software. but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR You should have received a copy of the GNU General Public License
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS along with this program. If not, see <http://www.gnu.org/licenses/>.
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

View File

@ -92,7 +92,8 @@ var pages = function(dbot) {
"languageeng": dbot.t("en"), "languageeng": dbot.t("en"),
"languageprog": dbot.t("langhead-progress"), "languageprog": dbot.t("langhead-progress"),
"languagetrans": dbot.t("langhead-translations"), "languagetrans": dbot.t("langhead-translations"),
"languagetranshead": dbot.t("translations") "languagetranshead": dbot.t("translations"),
"pullreqs": dbot.t("outstanding-pullreq")
}); });
}, },
}; };

View File

@ -16,10 +16,10 @@ var project = function(dbot) {
list.push(dbot.t("dent-account", { list.push(dbot.t("dent-account", {
"username": dbot.config.dent.username "username": dbot.config.dent.username
})); }));
}
if(_.has(dbot.config.dent.dentQuotes)) { if(_.has(dbot.config.dent.dentQuotes)) {
list.push(dbot.t("dent-push")); list.push(dbot.t("dent-push"));
} }
}
if(_.has(dbot.modules,'link')){ if(_.has(dbot.modules,'link')){
if(dbot.config.link.autoTitle){ if(dbot.config.link.autoTitle){
list.push(dbot.t("link-autotitle")); list.push(dbot.t("link-autotitle"));

View File

@ -1,7 +1,4 @@
{ {
"dbotintro": {
"en": "{botname} lorem ipsum dolor sit amet"
},
"dbotspeaks": { "dbotspeaks": {
"en": "{name} speaks {lang}", "en": "{name} speaks {lang}",
"de": "{name} spricht {lang} ({langen})", "de": "{name} spricht {lang} ({langen})",
@ -10,10 +7,12 @@
"nl": "{name} spreekt {lang} ({langen})" "nl": "{name} spreekt {lang} ({langen})"
}, },
"thanks": { "thanks": {
"en": "With thanks to:" "en": "With thanks to:",
"fr": "Merci à:"
}, },
"credits": { "credits": {
"en": "Authors" "en": "Authors",
"fr": "Développeurs"
}, },
"pagetitle": { "pagetitle": {
"en": "{botname} web interface", "en": "{botname} web interface",
@ -115,6 +114,7 @@
}, },
"milestones": { "milestones": {
"en": "Milestones" "en": "Milestones"
"fr": "étapes"
}, },
"milestoneprog": { "milestoneprog": {
"en": "Progress", "en": "Progress",
@ -173,21 +173,40 @@
"en": "{branch}" "en": "{branch}"
}, },
"git": { "git": {
"en": "version control" "en": "version control",
"de": "Versionsverwaltung",
"es": "Control de versiones",
"fr": "Festion de versions",
"it": "Controllo versione",
"nl": "Versiebeheersysteem"
}, },
"langhead-current": { "langhead-current": {
"en": "Current" "en": "Current",
"fr": "Courant"
}, },
"langhead-translations": { "langhead-translations": {
"en": "Completion" "en": "Completion",
"fr": "Achèvement"
}, },
"translations": { "translations": {
"en": "Translations" "en": "Translations",
"fr": "Traductions"
}, },
"langhead-progress": { "langhead-progress": {
"en": "Translation Progress" "en": "Translation Progress",
"fr": "Avancement de la Traduction"
}, },
"langhead-native": { "langhead-native": {
"en": "Native" "en": "Native",
"fr": "Natale"
},
"outstanding-pullreq": {
"en": "There are outstanding pull requests"
},
"oaosidl": {
"en": "The Official Aberystwyth Open Source International Development League"
},
"link-autotitle": {
"en": "Automatically titling links in channels"
} }
} }

View File

@ -3,6 +3,10 @@ pre#gitdiff {
width:80; width:80;
margin:auto; margin:auto;
text-transform:none; text-transform:none;
clear:both;
}
ul#credits {
text-transform:capitalize;
} }
div#main { div#main {
font-size:18px; font-size:18px;
@ -19,6 +23,7 @@ p.intro {
border:1px solid #ccc; border:1px solid #ccc;
padding:20px; padding:20px;
border-radius:4px; border-radius:4px;
text-transform:none;
} }
div.progress.open { div.progress.open {
background-color: #f4fff4; background-color: #f4fff4;
@ -63,3 +68,39 @@ li {
#footer { #footer {
font-size:80%; font-size:80%;
} }
h2 {
margin-top:40px;
margin-bottom:30px;
}
h3 {
margin-top:30px;
margin-bottom:20px;
}
#translations td {
text-transform:none;
}
p#pullreq {
float:right;
border-left:1px solid #ccc;
border-top:1px solid #ccc;
border-top-left-radius:5px;
padding:10px;
margin:5px;
display:none;
}
p#revnum {
float:left;
border-right:1px solid #ccc;
border-top:1px solid #ccc;
border-top-right-radius: 5px;
margin:5px;
padding:10px;
margin-bottom:0px;
}
h2 {
border-bottom: 1px solid #ccc;
border-top:1px solid #ccc;
margin-left:auto;
margin-right:auto;
width:40%;
}

View File

@ -8,12 +8,13 @@ html(lang='#{curr839}')
link(rel='stylesheet', type='text/css', href='/styles.css') link(rel='stylesheet', type='text/css', href='/styles.css')
link(rel="stylesheet", href="/project.css") link(rel="stylesheet", href="/project.css")
title #{pagetitle} title #{pagetitle}
- var mstone = "milestone" script
style(type="text/css") $(document).ready(function() {
each milestone in milestones $.get("https://api.github.com/repos/#{repo}/pulls", function(data) {
- current = mstone+milestone.number if ($.parseJSON(data).length) { $("#pullreq").show();}
- wdth = ((milestone.open_issues/(milestone.open_issues + milestone.closed_issues))*100) });
.current { width: wdth% } });
body body
div.container div.container
div#page div#page
@ -22,12 +23,14 @@ html(lang='#{curr839}')
p.intro p.intro
#{dquote} #{dquote}
section#git section#git
h3 #{development} h2 #{development}
p.center p#pullreq
a(href="https://github.com/"+repo+"/pulls") #{pullreqs}
p#revnum
#{revnum} #{revnum}
pre#gitdiff pre#gitdiff
#{diff} #{diff}
h4 #{milestoneprog} h3 #{milestonehead}
table#milestones.center table#milestones.center
tr tr
th #{milestonename} th #{milestonename}
@ -36,9 +39,9 @@ html(lang='#{curr839}')
th #{closedmilestone} th #{closedmilestone}
each milestone in milestones each milestone in milestones
- var wdth = ((milestone.closed_issues/(milestone.open_issues + milestone.closed_issues))*100) - var wdth = ((milestone.closed_issues/(milestone.open_issues + milestone.closed_issues))*100)
tr(id=mstone+milestone.number) tr(id="milestone"+milestone.number)
td td
a(href=milestone.url) a(href="https://github.com/"+repo+"/issues?milestone="+milestone.number)
#{milestone.title} #{milestone.title}
td td
div.progress(class=milestone.state) div.progress(class=milestone.state)
@ -47,8 +50,10 @@ html(lang='#{curr839}')
print #{Math.round(wdth)+"%"} print #{Math.round(wdth)+"%"}
td #{milestone.open_issues} td #{milestone.open_issues}
td #{milestone.closed_issues} td #{milestone.closed_issues}
h4 #{languagetranshead} a(#href="https://github.com/"+repo+"/")
table #{propaganda}
h3 #{languagetranshead}
table#translations
tr tr
th #{languagecurr} th #{languagecurr}
th #{languagenati} th #{languagenati}
@ -75,18 +80,20 @@ html(lang='#{curr839}')
&nbsp; &nbsp;
print #{Math.round(w)+"%"} print #{Math.round(w)+"%"}
td #{language.count} / #{translation.en.count} td #{language.count} / #{translation.en.count}
h4 #{credits} h3 #{credits}
#{thanks} #{thanks}
ul ul#credits
each author in authors each author in authors
li li
#{author} #{author}
section#config section#config
h3 #{config} h2 #{config}
ul ul
li #{currlang} li #{currlang}
li #{debugmode} li #{debugmode}
h4 #{loadmod} each config in configList
li #{config}
h3 #{loadmod}
ul#modules ul#modules
each module in modules each module in modules
li #{module} li #{module}