forked from GitHub/dbot
Merge git://github.com/reality/depressionbot into database
This commit is contained in:
commit
a5b65856a6
@ -14,7 +14,7 @@
|
||||
"admins": [ "batman" ],
|
||||
"moderators": [ "whatever" ],
|
||||
"moduleNames": [ "ignore", "admin", "command", "dice", "js", "kick", "quotes", "spelling", "youare", "stats", "users" ],
|
||||
"language": "english",
|
||||
"language": "en",
|
||||
"debugMode": true,
|
||||
"version": "Depressionbot IRC bot 0.4-dev - Lovingly crafted by The DepressionBot Foundation (a charity arm of the Official Aberystwyth Open Source International Development League)."
|
||||
}
|
||||
|
@ -1,84 +1,84 @@
|
||||
{
|
||||
"join": {
|
||||
"english": "Joined {channel}",
|
||||
"spanish" : "Entrado en {channel}",
|
||||
"en": "Joined {channel}",
|
||||
"es" : "Entrado en {channel}",
|
||||
"na'vi": "fpxäkìm {channel}(nemfa)",
|
||||
"welsh": "Wedi ymuno {channel}"
|
||||
"cy": "Wedi ymuno {channel}"
|
||||
},
|
||||
"part": {
|
||||
"english": "Left {channel}",
|
||||
"spanish" : "Abandonada {channel}",
|
||||
"en": "Left {channel}",
|
||||
"es" : "Abandonada {channel}",
|
||||
"na'vi": "Hum {channel}",
|
||||
"welsh": "Wedi gadael {channel}"
|
||||
"cy": "Wedi gadael {channel}"
|
||||
},
|
||||
"gpull": {
|
||||
"english": "Git pulled that shit.",
|
||||
"spanish": "Hecho git pull en esta mierda.",
|
||||
"en": "Git pulled that shit.",
|
||||
"es": "Hecho git pull en esta mierda.",
|
||||
"na'vi": "Gìtìl fì'uti stamarsìm.",
|
||||
"welsh": "Wedi tynnu git yr cach na i gyd"
|
||||
"cy": "Wedi tynnu git yr cach na i gyd"
|
||||
},
|
||||
"reload": {
|
||||
"english": "Reloaded that shit.",
|
||||
"spanish": "Recargado esta mierda.",
|
||||
"en": "Reloaded that shit.",
|
||||
"es": "Recargado esta mierda.",
|
||||
"na'vi": "Oel fìuti stìyeftxaw.",
|
||||
"welsh": "Ail-lwytho'r cach na"
|
||||
"cy": "Ail-lwytho'r cach na"
|
||||
},
|
||||
"load_module": {
|
||||
"english": "Loaded new module: {moduleName}",
|
||||
"spanish": "Cargado módulo nuevo: {moduleName}",
|
||||
"en": "Loaded new module: {moduleName}",
|
||||
"es": "Cargado módulo nuevo: {moduleName}",
|
||||
"na'vi": "Oel {moduleName}it amip stìyeftxaw.",
|
||||
"welsh": "Wedi llwytho modiwl newydd: {moduleName}"
|
||||
"cy": "Wedi llwytho modiwl newydd: {moduleName}"
|
||||
},
|
||||
"unload_module": {
|
||||
"english": "Turned off module: {moduleName}",
|
||||
"spanish": "Descargado módulo: {moduleName}",
|
||||
"en": "Turned off module: {moduleName}",
|
||||
"es": "Descargado módulo: {moduleName}",
|
||||
"na'vi": "Oel {moduleName} tswìya'.",
|
||||
"welsh": "Wedi troi ffwrdd y modiwl: {moduleName}"
|
||||
"cy": "Wedi troi ffwrdd y modiwl: {moduleName}"
|
||||
},
|
||||
"unload_error": {
|
||||
"english": "{moduleName} isn't loaded. Idiot.",
|
||||
"spanish": "{moduleName} no está cargado. Idiota.",
|
||||
"en": "{moduleName} isn't loaded. Idiot.",
|
||||
"es": "{moduleName} no está cargado. Idiota.",
|
||||
"na'vi": "Oel {moduleName}it omum. Nga skxawng lu.",
|
||||
"welsh": "Di {moduleName} ddim wedi llwytho. Twpsyn"
|
||||
"cy": "Di {moduleName} ddim wedi llwytho. Twpsyn"
|
||||
},
|
||||
"banned": {
|
||||
"english": "{user} banned from {command}",
|
||||
"spanish": "{user} está prohibido de usar {command}",
|
||||
"en": "{user} banned from {command}",
|
||||
"es": "{user} está prohibido de usar {command}",
|
||||
"na'vi": "{command}ìri {user} ke tung.",
|
||||
"welsh": "{user} wedi ei gohurio o {command}"
|
||||
"cy": "{user} wedi ei gohurio o {command}"
|
||||
},
|
||||
"unbanned": {
|
||||
"english": "{user} unbanned from {command}",
|
||||
"spanish": "{user} no está prohibido de user {command}",
|
||||
"en": "{user} unbanned from {command}",
|
||||
"es": "{user} no está prohibido de user {command}",
|
||||
"na'vi": "{command}ìri {user} tung set.",
|
||||
"welsh": "{user} wedi ei dad-wahardd o {command}"
|
||||
"cy": "{user} wedi ei dad-wahardd o {command}"
|
||||
},
|
||||
"unban_error": {
|
||||
"english": "{user} wasn't banned from that command, fool.",
|
||||
"spanish": "{user} no fue prohibido de esta instrucción, tont@.",
|
||||
"en": "{user} wasn't banned from that command, fool.",
|
||||
"es": "{user} no fue prohibido de esta instrucción, tont@.",
|
||||
"na'vi": "{user} fìtsu'oti tamung srekrr, nga skxawng lu.",
|
||||
"welsh": "Nid oedd {user} wedi ei wahardd o'r gyrchymun yna, fŵl"
|
||||
"cy": "Nid oedd {user} wedi ei wahardd o'r gyrchymun yna, fŵl"
|
||||
},
|
||||
"qlock": {
|
||||
"english": "Locked quote category: {category}",
|
||||
"spanish": "Cerrado la categoría: {category}",
|
||||
"en": "Locked quote category: {category}",
|
||||
"es": "Cerrado la categoría: {category}",
|
||||
"na'vi": "{category}ìri oel 'upxareti fmoli",
|
||||
"welsh": "Categori wedi cloi: {category}"
|
||||
"cy": "Categori wedi cloi: {category}"
|
||||
},
|
||||
"already_in_channel": {
|
||||
"english": "I'm already in {channel}",
|
||||
"en": "I'm already in {channel}",
|
||||
"na'vi": "Oel {channel}it tok li"
|
||||
},
|
||||
"not_in_channel": {
|
||||
"english": "I'm not in {channel}",
|
||||
"en": "I'm not in {channel}",
|
||||
"na'vi": "Oel {channel}it ke tok"
|
||||
},
|
||||
"already_loaded_web": {
|
||||
"english": "WHY CAN'T I LOAD ALL THIS WEB? (web already loaded)",
|
||||
"en": "WHY CAN'T I LOAD ALL THIS WEB? (web already loaded)",
|
||||
"na'vi": "PELUN OEL KE TSUN OMUM FÌWETIT NÌWOTX (wetìri oe omum li)"
|
||||
},
|
||||
"already_loaded": {
|
||||
"english": "{moduleName} is already loaded.",
|
||||
"en": "{moduleName} is already loaded.",
|
||||
"na'vi": "Oel omum teri {moduleName}it li."
|
||||
}
|
||||
}
|
||||
|
@ -1,30 +1,30 @@
|
||||
{
|
||||
"command_ban": {
|
||||
"english": "{user} is banned from using this command. Commence incineration.",
|
||||
"spanish": "{user} está prohibido de usar esta instrucción. Comenzar incineración.",
|
||||
"en": "{user} is banned from using this command. Commence incineration.",
|
||||
"es": "{user} está prohibido de usar esta instrucción. Comenzar incineración.",
|
||||
"na'vi": "Tsu'ori {user} ke tung. Nga skxawng lu.",
|
||||
"welsh": "Mae {user} wedi ei gohurio gan ddefnyddio'r gorchymun yma. Cychwyn orfflosgiad"
|
||||
"cy": "Mae {user} wedi ei gohurio gan ddefnyddio'r gorchymun yma. Cychwyn orfflosgiad"
|
||||
},
|
||||
"syntax_error": {
|
||||
"english": "Invalid syntax. Initiate incineration.",
|
||||
"spanish": "Sintaxis no válida. Iniciar incineración.",
|
||||
"en": "Invalid syntax. Initiate incineration.",
|
||||
"es": "Sintaxis no válida. Iniciar incineración.",
|
||||
"na'vi": "Ngeyä pamrel keyawr lu. Nga skxawng lu.",
|
||||
"welsh": "Cystrawen annilys. Cychwyn orfflosgiad"
|
||||
"cy": "Cystrawen annilys. Cychwyn orfflosgiad"
|
||||
},
|
||||
"usage": {
|
||||
"english": "Usage for {command}: {usage}.",
|
||||
"en": "Usage for {command}: {usage}.",
|
||||
"na'vi": "Nga tsun sivar ìlä {command}: {usage}."
|
||||
},
|
||||
"no_usage_info": {
|
||||
"english": "No usage information found for {command}.",
|
||||
"en": "No usage information found for {command}.",
|
||||
"na'vi": "Oel ke tsun sivar {comamnd}it"
|
||||
},
|
||||
"help_link": {
|
||||
"english": "Help for {module}: {link}",
|
||||
"en": "Help for {module}: {link}",
|
||||
"na'vi": "{module}ä srungìl {link} it tok"
|
||||
},
|
||||
"no_help": {
|
||||
"english": "No help found for {module}.",
|
||||
"en": "No help found for {module}.",
|
||||
"na'vi": "Fì{module}ìri oel ke tsun run srungit"
|
||||
}
|
||||
}
|
||||
|
@ -3,6 +3,15 @@ var request = require('request');
|
||||
|
||||
var dent = function(dbot) {
|
||||
this.dbot = dbot;
|
||||
this.StatusRegex = {
|
||||
identica: /\bhttps?:\/\/identi\.ca\/notice\/(\d+)\b/ig,
|
||||
twitter: /\bhttps?:\/\/twitter\.com\/\w+\/status\/(\d+)\b/ig
|
||||
};
|
||||
|
||||
this.StatusAPI = {
|
||||
identica: "http://identi.ca/api/statuses/show.json",
|
||||
twitter: "https://api.twitter.com/1/statuses/show.json"
|
||||
};
|
||||
|
||||
this.api = {
|
||||
'post': function(content) {
|
||||
@ -25,6 +34,20 @@ var dent = function(dbot) {
|
||||
}
|
||||
};
|
||||
|
||||
this.lookup = function(event, id, service) {
|
||||
request({
|
||||
url: this.StatusAPI[service],
|
||||
qs: {"id": id},
|
||||
json: true
|
||||
}, function(error, response, body) {
|
||||
if (!error && response.statusCode == 200) {
|
||||
if (_.has(body, 'text')) {
|
||||
event.reply(service + " [" + body.user.screen_name + '] ' + body.text);
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
this.commands = {
|
||||
'~dent': function(event) {
|
||||
this.api.post(event.input[1]);
|
||||
@ -40,6 +63,19 @@ var dent = function(dbot) {
|
||||
}.bind(this));
|
||||
}
|
||||
}.bind(this);
|
||||
|
||||
this.listener = function(event) {
|
||||
for (s in this.StatusRegex) {
|
||||
if (this.StatusRegex.hasOwnProperty(s)) {
|
||||
var matches = this.StatusRegex[s].exec(event.message);
|
||||
if (matches != null) {
|
||||
this.lookup(event, matches[1], s);
|
||||
}
|
||||
}
|
||||
}
|
||||
}.bind(this);
|
||||
|
||||
this.on = 'PRIVMSG';
|
||||
};
|
||||
|
||||
exports.fetch = function(dbot) {
|
||||
|
13
modules/finger/README.md
Normal file
13
modules/finger/README.md
Normal file
@ -0,0 +1,13 @@
|
||||
## Finger
|
||||
|
||||
Retrieves user information from a remote server.
|
||||
|
||||
### Description
|
||||
Uses the ``finger`` command to retrieve limited information on users.
|
||||
|
||||
|
||||
### Commands
|
||||
###~finger [username]
|
||||
Returns the real name of the user specified.
|
||||
### Dependencies
|
||||
* ``npm install request``
|
34
modules/finger/finger.js
Normal file
34
modules/finger/finger.js
Normal file
@ -0,0 +1,34 @@
|
||||
/**
|
||||
* Module Name: Finger
|
||||
* Description: Returns the name of users via the Finger protocol
|
||||
*/
|
||||
var request = require('request'),
|
||||
_ = require('underscore')._,
|
||||
exec = require('child_process').exec;
|
||||
|
||||
var finger = function(dbot) {
|
||||
var commands = {
|
||||
'~finger': function(event) {
|
||||
var username = event.params[1];
|
||||
exec("finger -s " + username + "@central.aber.ac.uk",function(error,stdout,stderr){
|
||||
stdout = stdout.replace(/(\r\n|\n|\r)/gm,"");
|
||||
name = stdout.search("Name:");
|
||||
stdout = stdout.substring(name);
|
||||
ret = stdout.search("Dir");
|
||||
stdout = stdout.substring(6,ret);
|
||||
if (stdout == "Welcom") {
|
||||
event.reply(dbot.t("nonexistent",{user: username}));
|
||||
} else {
|
||||
event.reply(dbot.t("name",{user: username, name: stdout}));
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
this.commands = commands;
|
||||
|
||||
this.on = 'PRIVMSG';
|
||||
};
|
||||
|
||||
exports.fetch = function(dbot) {
|
||||
return new finger(dbot);
|
||||
};
|
8
modules/finger/strings.json
Normal file
8
modules/finger/strings.json
Normal file
@ -0,0 +1,8 @@
|
||||
{
|
||||
"name": {
|
||||
"en": "{user} is {name}."
|
||||
},
|
||||
"nonexistent": {
|
||||
"en": "{user} not found."
|
||||
}
|
||||
}
|
@ -1,64 +1,64 @@
|
||||
{
|
||||
"ignore_usage": {
|
||||
"english": "{user}: Usage: ~ignore [module]. Modules you can ignore are: {modules}.",
|
||||
"spanish": "{user}: Modo de empleo: ~ignore [módulo]. Módulos que tú puedes ignorar son: {modules}.",
|
||||
"en": "{user}: Usage: ~ignore [module]. Modules you can ignore are: {modules}.",
|
||||
"es": "{user}: Modo de empleo: ~ignore [módulo]. Módulos que tú puedes ignorar son: {modules}.",
|
||||
"na'vi": "{user}: Sar: ~ignore ['u]. U, nga ke tìng mikyun: {modules}.",
|
||||
"welsh": "{user}: Defnydd: ~ignore [modiwl]. Modiwlau a allech anwybyddu yw: {modules}."
|
||||
"cy": "{user}: Defnydd: ~ignore [modiwl]. Modiwlau a allech anwybyddu yw: {modules}."
|
||||
},
|
||||
"already_ignoring": {
|
||||
"english": "{user}: You're already ignoring that module.",
|
||||
"spanish": "{user}: Ya ignoras este módulo.",
|
||||
"en": "{user}: You're already ignoring that module.",
|
||||
"es": "{user}: Ya ignoras este módulo.",
|
||||
"na'vi": "{user}: 'uri nga ke tìng mikyun srekrr.",
|
||||
"welsh": "{user}: Mi rwyt ti'n anwybyddu'r modiwl yna'n barod."
|
||||
"cy": "{user}: Mi rwyt ti'n anwybyddu'r modiwl yna'n barod."
|
||||
},
|
||||
"ignored": {
|
||||
"english": "{user}: Now ignoring {module}.",
|
||||
"spanish": "{user}: Estás ignorando {module}.",
|
||||
"en": "{user}: Now ignoring {module}.",
|
||||
"es": "{user}: Estás ignorando {module}.",
|
||||
"na'vi": "{user}: Nga ke terìng mikyun {module}ne set.",
|
||||
"welsh": "{user}: Nawr yn anwybyddu {module}"
|
||||
"cy": "{user}: Nawr yn anwybyddu {module}"
|
||||
},
|
||||
"invalid_ignore": {
|
||||
"english": "{user}: That isn't a valid module name.",
|
||||
"spanish": "{user}: Ese no es un nombre de un módulo valido.",
|
||||
"en": "{user}: That isn't a valid module name.",
|
||||
"es": "{user}: Ese no es un nombre de un módulo valido.",
|
||||
"na'vi": "{user}: Tsatstxo eyawr ke lu.",
|
||||
"welsh": "{user}: Nid oedd hwna'n modiwl dilys"
|
||||
"cy": "{user}: Nid oedd hwna'n modiwl dilys"
|
||||
},
|
||||
"unignore_usage": {
|
||||
"english": "{user}: Usage: ~unignore [module]. Modules you are currently ignoring: {modules}.",
|
||||
"spanish": "{user}: Modo de empleo: ~unignore [módulo]. Módulos que ignoras ahora mismo: {modules}.",
|
||||
"en": "{user}: Usage: ~unignore [module]. Modules you are currently ignoring: {modules}.",
|
||||
"es": "{user}: Modo de empleo: ~unignore [módulo]. Módulos que ignoras ahora mismo: {modules}.",
|
||||
"na'vi": "{user}: Sar: ~unignore ['u]. Uri, nga ke terìng mikyun: {modules}.",
|
||||
"welsh": "{user}: Defnydd ~unignore [modiwl]. Modiwlau rydech yn anwybyddu ar hyn o bryd: {modules}"
|
||||
"cy": "{user}: Defnydd ~unignore [modiwl]. Modiwlau rydech yn anwybyddu ar hyn o bryd: {modules}"
|
||||
},
|
||||
"invalid_unignore": {
|
||||
"english": "{user}: You're not ignoring that module or it doesn't exist.",
|
||||
"spanish": "{user}: No ignoras este módulo o no existe.",
|
||||
"en": "{user}: You're not ignoring that module or it doesn't exist.",
|
||||
"es": "{user}: No ignoras este módulo o no existe.",
|
||||
"na'vi":"{user}: Nga terìng mikyun fu fì'ul fìtsengit ke tok.",
|
||||
"welsh": "{user}: Nid wyt ti'n anwybyddu'r modiwl yna neu nid yw e'n bodoli"
|
||||
"cy": "{user}: Nid wyt ti'n anwybyddu'r modiwl yna neu nid yw e'n bodoli"
|
||||
},
|
||||
"unignored": {
|
||||
"english": "{user}: No longer ignoring {module}.",
|
||||
"spanish": "{user}: Ya no ignoras {module}.",
|
||||
"en": "{user}: No longer ignoring {module}.",
|
||||
"es": "{user}: Ya no ignoras {module}.",
|
||||
"na'vi": "{user}: Nga terìng mikyun {module}ne set",
|
||||
"welsh": "{user}: Ddim yn anwybyddu {module} bellach"
|
||||
"cy": "{user}: Ddim yn anwybyddu {module} bellach"
|
||||
},
|
||||
"ignoring_channel": {
|
||||
"english": "Now ignoring {module} in {channel}",
|
||||
"en": "Now ignoring {module} in {channel}",
|
||||
"na'vi": "Oe ke stayawm {module}ur mì {channel}"
|
||||
},
|
||||
"already_ignoring_channel": {
|
||||
"english": "Already ignoring {module} in {channel}",
|
||||
"en": "Already ignoring {module} in {channel}",
|
||||
"na'vi": "Oe ke stayawm {module}ur mì {channel} li"
|
||||
},
|
||||
"module_not_exist": {
|
||||
"english": "{module} isn't loaded or doesn't exist.",
|
||||
"en": "{module} isn't loaded or doesn't exist.",
|
||||
"na'vi": "Oel ke omum teri {module}it fu {module} ke fkeytok"
|
||||
},
|
||||
"unignoring_channel": {
|
||||
"english": "No longer ignoring {module} in {channel}",
|
||||
"en": "No longer ignoring {module} in {channel}",
|
||||
"na'vi": "Oel stayawm {module}ur mì {channel} set."
|
||||
},
|
||||
"not_ignoring_channel": {
|
||||
"english": "{module} wasn't being ignored in {channel}",
|
||||
"en": "{module} wasn't being ignored in {channel}",
|
||||
"na'vi": "Oel stayawm {module}ur mì {channel} li."
|
||||
}
|
||||
}
|
||||
|
@ -1,14 +1,14 @@
|
||||
{
|
||||
"user_kicks": {
|
||||
"english": "{user} has been kicked {kicks} times and has kicked people {kicked} times.",
|
||||
"spanish": "Se ha expulsado {user} {kicks} veces y {user} ha expulsado personas {kicked} veces.",
|
||||
"en": "{user} has been kicked {kicks} times and has kicked people {kicked} times.",
|
||||
"es": "Se ha expulsado {user} {kicks} veces y {user} ha expulsado personas {kicked} veces.",
|
||||
"na'vi": "Tuteol {user}it tsrame'i {kicks} hìmtxan ulte sute tsrame'i {kicked} hìmtxan.",
|
||||
"welsh": "Cafwyd {user} ei gicio {kicks} gwaith ac wedi cicio pobl {kicked} gwaith."
|
||||
"cy": "Cafwyd {user} ei gicio {kicks} gwaith ac wedi cicio pobl {kicked} gwaith."
|
||||
},
|
||||
"kicked_dbot": {
|
||||
"english": "Thou shalt not kick {botname}",
|
||||
"spanish": "No expulsás {botname}",
|
||||
"en": "Thou shalt not kick {botname}",
|
||||
"es": "No expulsás {botname}",
|
||||
"na'vi": "Ngal {botname}it ke tsun tsrive'i",
|
||||
"welsh": "Ni ddylech cicio {botname}"
|
||||
"cy": "Ni ddylech cicio {botname}"
|
||||
}
|
||||
}
|
||||
|
@ -23,3 +23,6 @@ which was posted in the current channel.
|
||||
Returns the first [Urban Dictionary](http://www.urbandictionary.com) definition for the headword provided.
|
||||
#### ~xkcd <comic ID>
|
||||
Returns a link to the [xkcd](http://xkcd.com) comic specified, or the latest one if a comic is not given. Use '*' to return a link to a random comic.
|
||||
|
||||
### Requirements
|
||||
* [node-ent](https://github.com/substack/node-ent)
|
||||
|
@ -4,7 +4,8 @@
|
||||
* information about links.
|
||||
*/
|
||||
var request = require('request'),
|
||||
_ = require('underscore')._;
|
||||
_ = require('underscore')._,
|
||||
ent = require('ent');
|
||||
|
||||
var link = function(dbot) {
|
||||
this.urlRegex = /(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/ig;
|
||||
@ -14,8 +15,8 @@ var link = function(dbot) {
|
||||
if(!error && response.statusCode == 200) {
|
||||
body = body.replace(/(\r\n|\n\r|\n)/gm, " ");
|
||||
var title = body.valMatch(/<title>(.*)<\/title>/, 2);
|
||||
if(title) {
|
||||
event.reply(title[1]);
|
||||
if(title && title.length < 140) {
|
||||
event.reply(ent.decode(title[1]));
|
||||
}
|
||||
}
|
||||
});
|
||||
|
@ -1,12 +1,13 @@
|
||||
{
|
||||
"title_not_found": {
|
||||
"english": "No page title found.",
|
||||
"en": "No page title found.",
|
||||
"na'vi": "Oel ke tsun run 'upxare atxin."
|
||||
},
|
||||
"xkcd": {
|
||||
"english": "xkcd {num}: {title} https://xkcd.com/{num}"
|
||||
"en": "xkcd {num}: {title} https://xkcd.com/{num}"
|
||||
},
|
||||
"no-hits": {
|
||||
"english": "No hits."
|
||||
"en": "No hits.",
|
||||
"na'vi": "Oel ke tsun rivum ayuoti."
|
||||
}
|
||||
}
|
||||
|
@ -1,87 +1,87 @@
|
||||
{
|
||||
"newpoll_usage": {
|
||||
"english": "Usage: ~newpoll name [options=opt1,opt2,opt3] description",
|
||||
"spanish" : "Modo de empleo: ~newpoll nombre [options=opción1,opción2,opción3] descripción",
|
||||
"en": "Usage: ~newpoll name [options=opt1,opt2,opt3] description",
|
||||
"es" : "Modo de empleo: ~newpoll nombre [options=opción1,opción2,opción3] descripción",
|
||||
"na'vi": "Usage: ~newpoll tstxo [sìftxey=tìfxey1,tìfxey2,fìfxey3] tìsla'tsu",
|
||||
"welsh": "Defnydd: ~newpoll enw [optiynau=opt1,opt2,op3] disgrifiad"
|
||||
"cy": "Defnydd: ~newpoll enw [optiynau=opt1,opt2,op3] disgrifiad"
|
||||
},
|
||||
"poll_exists": {
|
||||
"english": "Poll '{name}' already exists.",
|
||||
"spanish" : "Votación '{name}' ya existe.",
|
||||
"en": "Poll '{name}' already exists.",
|
||||
"es" : "Votación '{name}' ya existe.",
|
||||
"na'vi": "sìpawm sna'o '{name}' fkeytok srekrr.",
|
||||
"welsh": "Mae'r pôl {name} bodoli'n barod"
|
||||
"cy": "Mae'r pôl {name} bodoli'n barod"
|
||||
},
|
||||
"poll_created": {
|
||||
"english": "Poll '{name}' created ({description}). Cast thy votations! - {url}",
|
||||
"spanish" : "Votación '{name}' creado ({description}). ¡Emited sus votas! - {url}",
|
||||
"en": "Poll '{name}' created ({description}). Cast thy votations! - {url}",
|
||||
"es" : "Votación '{name}' creado ({description}). ¡Emited sus votas! - {url}",
|
||||
"na'vi": "sìpawm sna'o '{name}' ngìyop ({description}). Nga tìpe'unit Pe'eiun - {url}"
|
||||
},
|
||||
"poll_describe": {
|
||||
"english": "{name}: {description} - {url}."
|
||||
"en": "{name}: {description} - {url}."
|
||||
},
|
||||
"changed_vote": {
|
||||
"english": "{user} changed their vote in {poll} to '{vote}' ({count}).",
|
||||
"spanish" : "{user} cambió su voto en {poll} a '{vote}' ({count}).",
|
||||
"en": "{user} changed their vote in {poll} to '{vote}' ({count}).",
|
||||
"es" : "{user} cambió su voto en {poll} a '{vote}' ({count}).",
|
||||
"na'vi": "{user} lìyatem ngeyä tìpe'un {poll}mì, ngeyä tìpe'un amip '{vote}'({count}) lu.",
|
||||
"welsh": "Newidiodd {user} eu pleidlais yn {poll} i '{vote}' ({count})."
|
||||
"cy": "Newidiodd {user} eu pleidlais yn {poll} i '{vote}' ({count})."
|
||||
},
|
||||
"voted": {
|
||||
"english": "{user} voted for '{vote}' in {poll} ({count}).",
|
||||
"spanish" : "{user} votó para '{vote}' en {poll} ({count}).",
|
||||
"en": "{user} voted for '{vote}' in {poll} ({count}).",
|
||||
"es" : "{user} votó para '{vote}' en {poll} ({count}).",
|
||||
"na'vi": "'{vote}'ìri {user} pìye'un {poll}mì ({count}).",
|
||||
"welsh": "Pledleisiodd {user} am '{vote}' yn {poll} ({count})."
|
||||
"cy": "Pledleisiodd {user} am '{vote}' yn {poll} ({count})."
|
||||
},
|
||||
"invalid_vote": {
|
||||
"english": "Invalid vote: {vote}",
|
||||
"spanish" : "Vota inválida: {vote}",
|
||||
"en": "Invalid vote: {vote}",
|
||||
"es" : "Vota inválida: {vote}",
|
||||
"na'vi": "Ngeyä tìpe'un keyawr lu ({vote}).",
|
||||
"welsh": "Pleidlais annilys: {vote}"
|
||||
"cy": "Pleidlais annilys: {vote}"
|
||||
},
|
||||
"poll_unexistent": {
|
||||
"english": "Poll '{name}' doesn't exist.",
|
||||
"spanish" : "Votación '{name}' no existe.",
|
||||
"en": "Poll '{name}' doesn't exist.",
|
||||
"es" : "Votación '{name}' no existe.",
|
||||
"na'vi": "sìpawm sna'o '{name}' ke fkeytok.",
|
||||
"welsh": "Nid yw pôl '{name}' yn bodoli"
|
||||
"cy": "Nid yw pôl '{name}' yn bodoli"
|
||||
},
|
||||
"option_added": {
|
||||
"english": "{user}: '{option}' added to '{name}'.",
|
||||
"spanish" : "{user}: '{option}' añadido a '{name}'.",
|
||||
"en": "{user}: '{option}' added to '{name}'.",
|
||||
"es" : "{user}: '{option}' añadido a '{name}'.",
|
||||
"na'vi": "'{name}'ur {user}ìl '{option}'it sung.",
|
||||
"welsh": "{user}: Ychwanegwyd '{option}' i '{name}'"
|
||||
"cy": "{user}: Ychwanegwyd '{option}' i '{name}'"
|
||||
},
|
||||
"option_exists": {
|
||||
"english": "{user}: '{option}' already exists in '{name}'.",
|
||||
"spanish" : "{user}: '{option}' ya existe en '{name}'.",
|
||||
"en": "{user}: '{option}' already exists in '{name}'.",
|
||||
"es" : "{user}: '{option}' ya existe en '{name}'.",
|
||||
"na'vi": "{user}: '{option}' fkeytok srekrr '{name}'mì.",
|
||||
"welsh": "{user}: Mae '{option}' yn bodoli'n barod yn '{name}'."
|
||||
"cy": "{user}: Mae '{option}' yn bodoli'n barod yn '{name}'."
|
||||
},
|
||||
"not_poll_owner": {
|
||||
"english": "{user}: You don't own the '{name}' poll.",
|
||||
"spanish" : "{user}: La votación '{name}' no es tuyo.",
|
||||
"en": "{user}: You don't own the '{name}' poll.",
|
||||
"es" : "{user}: La votación '{name}' no es tuyo.",
|
||||
"na'vi": "{user}: ngaru '{name}' sìpawm sna'o ke lu.",
|
||||
"welsh": "{user}: Nid ydech chi'n berchen y pôl '{name}'."
|
||||
"cy": "{user}: Nid ydech chi'n berchen y pôl '{name}'."
|
||||
},
|
||||
"option_removed": {
|
||||
"english": "{user}: '{option}' removed from '{name}'",
|
||||
"spanish" : "{user}: '{option}' eliminado de '{name}'",
|
||||
"en": "{user}: '{option}' removed from '{name}'",
|
||||
"es" : "{user}: '{option}' eliminado de '{name}'",
|
||||
"na'vi": "{user}: '{option}'it 'aku '{name}'ta",
|
||||
"welsh": "{user}: '{option}' wedi ei ddileu o '{name}'"
|
||||
"cy": "{user}: '{option}' wedi ei ddileu o '{name}'"
|
||||
},
|
||||
"av_voted": {
|
||||
"english": "{user} voted '{vote}' in {poll}.",
|
||||
"spanish": "{user} votó '{vote}' en {poll}.",
|
||||
"en": "{user} voted '{vote}' in {poll}.",
|
||||
"es": "{user} votó '{vote}' en {poll}.",
|
||||
"na'vi": "{user}ìl '{vote}'it pìye'un '{poll}'mì.",
|
||||
"welsh": "Pledleisiodd {user} am '{vote}' yn {poll}"
|
||||
"cy": "Pledleisiodd {user} am '{vote}' yn {poll}"
|
||||
},
|
||||
"av_changed_vote": {
|
||||
"english": "{user} changed their vote in {poll} to '{vote}'.",
|
||||
"spanish" : "{user} cambió su voto en {poll} a '{vote}'.",
|
||||
"en": "{user} changed their vote in {poll} to '{vote}'.",
|
||||
"es" : "{user} cambió su voto en {poll} a '{vote}'.",
|
||||
"na'vi": "{user}ìl lìyatem ngeyä tìpa'unit '{poll}'mì, ngeyä tìpe'un '{vote} lu set.",
|
||||
"welsh": "Newidiodd {user} eu pleidlais yn {poll} i '{vote}'"
|
||||
"cy": "Newidiodd {user} eu pleidlais yn {poll} i '{vote}'"
|
||||
},
|
||||
"count": {
|
||||
"english": "The running-order of poll '{poll}' ({description}) is: {places}.",
|
||||
"en": "The running-order of poll '{poll}' ({description}) is: {places}.",
|
||||
"na'vi": "Sute tsnì pole'un '{poll}'mì ({description}) lu: {places}.",
|
||||
"welsh": "Trefn yr pôl '{poll}' ({description}) yw: {places}"
|
||||
"cy": "Trefn yr pôl '{poll}' ({description}) yw: {places}"
|
||||
}
|
||||
}
|
||||
|
@ -77,7 +77,7 @@ var commands = function(dbot) {
|
||||
var needle = event.input[2];
|
||||
if(_.has(quotes, haystack)) {
|
||||
var matches = _.filter(quotes[haystack], function(quote) {
|
||||
return _.indexOf(quote, needle) != -1;
|
||||
return quote.indexOf(needle) != -1;
|
||||
}, this);
|
||||
|
||||
if(matches.length == 0) {
|
||||
@ -192,7 +192,7 @@ var commands = function(dbot) {
|
||||
},
|
||||
|
||||
'~link': function(event) {
|
||||
var key = event.params[1].trim().toLowerCase();
|
||||
var key = event.input[1].toLowerCase();
|
||||
if(_.has(quotes, key)) {
|
||||
event.reply(dbot.t('quote_link', {
|
||||
'category': key,
|
||||
@ -214,6 +214,7 @@ var commands = function(dbot) {
|
||||
commands['~rm'].regex = [/^~rm ([\d\w\s-]+?)[ ]?=[ ]?(.+)$/, 3];
|
||||
commands['~rmlast'].regex = [/^~rmlast ([\d\w\s-]*)/, 2];
|
||||
commands['~qadd'].regex = [/^~qadd ([\d\w\s-]+?)[ ]?=[ ]?(.+)$/, 3];
|
||||
commands['~link'].regex = [/^~link ([\d\w\s-]*)/, 2];
|
||||
|
||||
commands['~rmconfirm'].access = 'moderator';
|
||||
commands['~rmdeny'].access = 'moderator';
|
||||
|
@ -1,130 +1,130 @@
|
||||
{
|
||||
"category_not_found": {
|
||||
"english": "Nobody loves {category}",
|
||||
"spanish": "Nadie ama a {category}",
|
||||
"en": "Nobody loves {category}",
|
||||
"es": "Nadie ama a {category}",
|
||||
"na'vi": "{category} yawne ke lu kawturu.",
|
||||
"welsh": "Does neb yn caru {category}"
|
||||
"cy": "Does neb yn caru {category}"
|
||||
},
|
||||
"large_categories": {
|
||||
"english": "Largest categories: ",
|
||||
"spanish": "Los categorías más grandes: ",
|
||||
"en": "Largest categories: ",
|
||||
"es": "Los categorías más grandes: ",
|
||||
"na'vi": "U atsawl: ",
|
||||
"welsh": "Categoriau mwyaf: "
|
||||
"cy": "Categoriau mwyaf: "
|
||||
},
|
||||
"empty_category": {
|
||||
"english": "That category has no quotes in. Commence incineration.",
|
||||
"spanish": "Categoría vacía. Iniciar incineración.",
|
||||
"en": "That category has no quotes in. Commence incineration.",
|
||||
"es": "Categoría vacía. Iniciar incineración.",
|
||||
"na'vi": "Tsauru upxare lu. Nga skxawng lu.",
|
||||
"welsh": "Nid yw'r categori yna efo dyfyniadau. Cychwyn orfflosgiad"
|
||||
"cy": "Nid yw'r categori yna efo dyfyniadau. Cychwyn orfflosgiad"
|
||||
},
|
||||
"no_results": {
|
||||
"english": "No results found.",
|
||||
"spanish": "No hubo ningún resultado.",
|
||||
"en": "No results found.",
|
||||
"es": "No hubo ningún resultado.",
|
||||
"na'vi": "Oel kea humit rìmun",
|
||||
"welsh": "Dim canlyniadau ar gael"
|
||||
"cy": "Dim canlyniadau ar gael"
|
||||
},
|
||||
"locked_category": {
|
||||
"english": "{category} is locked. Commence incineration.",
|
||||
"spanish": "{category} está cerrada. Comenzar incineración.",
|
||||
"en": "{category} is locked. Commence incineration.",
|
||||
"es": "{category} está cerrada. Comenzar incineración.",
|
||||
"na'vi": "{category} ke fkeytok set. Nga skxawng lu nafì'u",
|
||||
"welsh": "Mae {category} wedi cloi. Cychwyn orfflosgiad"
|
||||
"cy": "Mae {category} wedi cloi. Cychwyn orfflosgiad"
|
||||
},
|
||||
"no_quotes": {
|
||||
"english": "No quotes exist under {category}",
|
||||
"spanish": "Ninguna cita existe en {category}",
|
||||
"en": "No quotes exist under {category}",
|
||||
"es": "Ninguna cita existe en {category}",
|
||||
"na'vi": "Kea upxare fkeytok {category}mì",
|
||||
"welsh": "Does dim dyfyniadau gan {category}"
|
||||
"cy": "Does dim dyfyniadau gan {category}"
|
||||
},
|
||||
"last_removed": {
|
||||
"english": "Last quote removed from {category}.",
|
||||
"spanish": "Última cita quitado de {category}.",
|
||||
"en": "Last quote removed from {category}.",
|
||||
"es": "Última cita quitado de {category}.",
|
||||
"na'vi": "Oel 'upxareti aham 'aku {category}ta",
|
||||
"welsh": "Dyfyniad olaf wedi ei ddileu o {category}"
|
||||
"cy": "Dyfyniad olaf wedi ei ddileu o {category}"
|
||||
},
|
||||
"no_recent_adds": {
|
||||
"english": "No quotes were added recently.",
|
||||
"spanish": "Ninguna cita fue añadido recientamente.",
|
||||
"en": "No quotes were added recently.",
|
||||
"es": "Ninguna cita fue añadido recientamente.",
|
||||
"na'vi": "Kea upxareti samung nìfkrr",
|
||||
"welsh": "Nid oes unrhyw dyfyniadau wedi ei ychwwanegu'n ddiweddar"
|
||||
"cy": "Nid oes unrhyw dyfyniadau wedi ei ychwwanegu'n ddiweddar"
|
||||
},
|
||||
"rmlast_spam": {
|
||||
"english": "No spamming that shit. Try again in a few minutes...",
|
||||
"spanish": "No me inundes de mierda. Intenta otra vez en unos minutos...",
|
||||
"en": "No spamming that shit. Try again in a few minutes...",
|
||||
"es": "No me inundes de mierda. Intenta otra vez en unos minutos...",
|
||||
"na'vi": "Nga Tsasngelit ke zene fpivere'. Sweylu nga fmivi ye'rìn...",
|
||||
"welsh": "Peidiwch a sbamio hwna. Triwch eto mewn ychydyg funudau..."
|
||||
"cy": "Peidiwch a sbamio hwna. Triwch eto mewn ychydyg funudau..."
|
||||
},
|
||||
"removed_from": {
|
||||
"english": "'{quote}' removed from {category}",
|
||||
"spanish": "'{quote}' quitado de {category}",
|
||||
"en": "'{quote}' removed from {category}",
|
||||
"es": "'{quote}' quitado de {category}",
|
||||
"na'vi": "'{quote}'(it/ti) 'ìyaku {category}",
|
||||
"welsh": "'{quote}' wedi ei ddileu o {category}"
|
||||
"cy": "'{quote}' wedi ei ddileu o {category}"
|
||||
},
|
||||
"q_not_exist_under": {
|
||||
"english": "'{quote}' doesn't exist under '{category}'.",
|
||||
"spanish": "'{quote}' no existe en '{category}'.",
|
||||
"en": "'{quote}' doesn't exist under '{category}'.",
|
||||
"es": "'{quote}' no existe en '{category}'.",
|
||||
"na'vi": "'{quote}' ke fkeytok '{category}'ta.",
|
||||
"welsh": "Nid yw '{quote}' yn bodoli yn '{category}'"
|
||||
"cy": "Nid yw '{quote}' yn bodoli yn '{category}'"
|
||||
},
|
||||
"total_quotes": {
|
||||
"english": "Total quote count: {count}.",
|
||||
"spanish": "Total de citas: {count}.",
|
||||
"en": "Total quote count: {count}.",
|
||||
"es": "Total de citas: {count}.",
|
||||
"na'vi": "'upxareri holpxay: {count}.",
|
||||
"welsh": "Cyfanswm dyfyniadau: {count}."
|
||||
"cy": "Cyfanswm dyfyniadau: {count}."
|
||||
},
|
||||
"quote_exists": {
|
||||
"english": "Quote already in DB. Initiate incineration.",
|
||||
"spanish": "Cita ya existe. Iniciar incineración.",
|
||||
"en": "Quote already in DB. Initiate incineration.",
|
||||
"es": "Cita ya existe. Iniciar incineración.",
|
||||
"na'vi": "'Upxarel säomumit fìtsengit tok srekrr. Nga skxawng lu.",
|
||||
"welsh": "Dyfyniad yn y gronfa ddata yn barod. Cychwyn orfflosgiad"
|
||||
"cy": "Dyfyniad yn y gronfa ddata yn barod. Cychwyn orfflosgiad"
|
||||
},
|
||||
"quote_saved": {
|
||||
"english": "Quote saved in '{category}' ({count}).",
|
||||
"spanish": "Cita guardada en '{category}' ({count}).",
|
||||
"en": "Quote saved in '{category}' ({count}).",
|
||||
"es": "Cita guardada en '{category}' ({count}).",
|
||||
"na'vi": "Oe zayerok '{category}'mì ({count}).",
|
||||
"welsh": "Dyfyniad wedi ei gadw yn '{category}' ({count})."
|
||||
"cy": "Dyfyniad wedi ei gadw yn '{category}' ({count})."
|
||||
},
|
||||
"quote_replace": {
|
||||
"english": "No replacing arrays, you whore.",
|
||||
"spanish": "No sustituites arrays, hijo de puta.",
|
||||
"en": "No replacing arrays, you whore.",
|
||||
"es": "No sustituites arrays, hijo de puta.",
|
||||
"na'vi": "Ngal fìsäomumit ke tsun rivawn. Nga muntxa sayi suteo hrh.",
|
||||
"welsh": "Peidiwch a newid rhestrau, y cachgi"
|
||||
"cy": "Peidiwch a newid rhestrau, y cachgi"
|
||||
},
|
||||
"quote_count": {
|
||||
"english": "{category} has {count} quotes.",
|
||||
"spanish": "{category} tiene {count} citas.",
|
||||
"en": "{category} has {count} quotes.",
|
||||
"es": "{category} tiene {count} citas.",
|
||||
"na'vi": "{count}a upxare {category}ur lu.",
|
||||
"welsh": "{count} dyfyniad yn {category}"
|
||||
"cy": "{count} dyfyniad yn {category}"
|
||||
},
|
||||
"quote_link": {
|
||||
"english": "Link to {category} - {url}",
|
||||
"spanish": "Enlace a {category} - {url}",
|
||||
"en": "Link to {category} - {url}",
|
||||
"es": "Enlace a {category} - {url}",
|
||||
"na'vi": "Fya'o {category}ne - {url}",
|
||||
"welsh": "Dolen i {category} - {url}"
|
||||
"cy": "Dolen i {category} - {url}"
|
||||
},
|
||||
"search_results": {
|
||||
"english": "{category} ({needle}): '{quote}' [{matches} results]",
|
||||
"spanish" : "{category} ({needle}): '{quote}' [{matches} resultados]",
|
||||
"en": "{category} ({needle}): '{quote}' [{matches} results]",
|
||||
"es" : "{category} ({needle}): '{quote}' [{matches} resultados]",
|
||||
"na'vi": "{category} ({needle}): '{quote}' [kum a{matches}]",
|
||||
"welsh": "{category} ({needle}): '{quote}' [{matches} canlyniad]"
|
||||
"cy": "{category} ({needle}): '{quote}' [{matches} canlyniad]"
|
||||
},
|
||||
"quote_cache_auto_remove": {
|
||||
"english": "There are {count} quotes in the removal cache, which will be automatically cleared.",
|
||||
"en": "There are {count} quotes in the removal cache, which will be automatically cleared.",
|
||||
"na'vi": "{count}a 'upxarel sngelit tok, Oel 'ayku sngelit lukenga."
|
||||
},
|
||||
"quote_cache_manual_remove": {
|
||||
"english": "There are {count} quotes in the removal cache, which must be manually cleared.",
|
||||
"en": "There are {count} quotes in the removal cache, which must be manually cleared.",
|
||||
"na'vi": "{count}a 'upxarel sngelit tok slä oel ke 'ayku sngelit tafral nga zene 'aivku"
|
||||
},
|
||||
"quote_cache_cleared": {
|
||||
"english": "{count} quotes cleared from the removal cache.",
|
||||
"en": "{count} quotes cleared from the removal cache.",
|
||||
"na'vi": "Oel 'aìmku {count}a 'upxareti ta sngel."
|
||||
},
|
||||
"quote_cache_reinstated": {
|
||||
"english": "{count} quotes reinstated from the removal cache.",
|
||||
"en": "{count} quotes reinstated from the removal cache.",
|
||||
"na'vi": "{count}a 'upxare tolätxaw ta sngel."
|
||||
},
|
||||
"rm_cache_limit": {
|
||||
"english": "Attention: Too many quotes removed, rmCache must be cleared or reinstated manually with ~rmconfirm or ~rmdeny.",
|
||||
"en": "Attention: Too many quotes removed, rmCache must be cleared or reinstated manually with ~rmconfirm or ~rmdeny.",
|
||||
"na'vi": "Oel zerok 'upxareti apxay set, sweylu txo nga 'aivku upxareti ìlä ~rmconfirm fu ~rmdeny."
|
||||
}
|
||||
}
|
||||
|
@ -1,44 +1,58 @@
|
||||
{
|
||||
"rain-0": {
|
||||
"english" : "It's not raining in {place}."
|
||||
"en" : "It's not raining in {place}.",
|
||||
"na'vi": "tompa ke zup {place}ur."
|
||||
},
|
||||
"rain-1": {
|
||||
"english" : "It's raining in {place}."
|
||||
"en" : "It's raining in {place}.",
|
||||
"na'vi":"tompa zup {place}ur."
|
||||
},
|
||||
"rain-2": {
|
||||
"english" : "It's raining rather a lot in {place}."
|
||||
"en" : "It's raining rather a lot in {place}.",
|
||||
"na'vi":"tompa zup {place}ur nìhawng."
|
||||
},
|
||||
"rain-3": {
|
||||
"english" : "It's raining shitloads."
|
||||
"en" : "It's raining shitloads.",
|
||||
"na'vi":"tompa zup {place}ur nìhawng."
|
||||
},
|
||||
"rain-4": {
|
||||
"english" : "It's raining fucktons."
|
||||
"en" : "It's raining fucktons.",
|
||||
"na'vi": "tompa zup {place}ur nìhawng."
|
||||
},
|
||||
"rain-5": {
|
||||
"english" : "It's raining whales (in {place})!"
|
||||
"en" : "It's raining whales (in {place})!",
|
||||
"na'vi": "payoang zup {place}ur"
|
||||
},
|
||||
"rain-6": {
|
||||
"english" : "IT'S SO FUCKING WET OUT HERE MAN"
|
||||
"en" : "IT'S SO FUCKING WET OUT HERE MAN",
|
||||
"na'vi" : "pey lu oeru nìhawng taluna tok fìtengeti"
|
||||
},
|
||||
"rain-7": {
|
||||
"english" : "I AM SO MOIST RIGHT NOW"
|
||||
"en" : "I AM SO MOIST RIGHT NOW",
|
||||
"na'vi":"pey lu oeru nìhawng taluna tok fìtengeti"
|
||||
},
|
||||
"rain-8": {
|
||||
"english" : "You used a #3 pencil instead of #2, didn't you?"
|
||||
"en" : "You used a #3 pencil instead of #2, didn't you?",
|
||||
"na'vi": "Nga pamrel sami hu pencìl a#3 ulte ke pamrel sami pencìl a#2 kefyak?"
|
||||
},
|
||||
"rain-9": {
|
||||
"english" : "WELCOME TO ATLANTIS"
|
||||
"en" : "WELCOME TO ATLANTIS",
|
||||
"na'vi": "ziva'u nìprrte atlantisftu."
|
||||
},
|
||||
"rain-10": {
|
||||
"english" : "GET INSIDE"
|
||||
"en" : "GET INSIDE",
|
||||
"na'vi": "Sweylu txo nga livatam futa ngal fìtsengeti tok"
|
||||
},
|
||||
"rain-11": {
|
||||
"english" : "LOL U PROBABLY DIED"
|
||||
"en" : "LOL U PROBABLY DIED",
|
||||
"na'vi": "hrh kxawm nga tolerkup."
|
||||
},
|
||||
"rain-e": {
|
||||
"english" : "Unable to fetch weather data."
|
||||
"en" : "Unable to fetch weather data.",
|
||||
"na'vi":"Oel ke tsun rivum sänumeti teriyafkeyk."
|
||||
},
|
||||
"rain-u": {
|
||||
"english": "Location too ambigious to process."
|
||||
"en": "Location too ambigious to process.",
|
||||
"na'vi":"tsengeri, yayayr lu oeru."
|
||||
}
|
||||
}
|
||||
|
@ -1,18 +1,18 @@
|
||||
{
|
||||
"report": {
|
||||
"english": "Attention: {reporter} has reported {reported} in {channel}. The reason given was: \"{reason}.\"",
|
||||
"en": "Attention: {reporter} has reported {reported} in {channel}. The reason given was: \"{reason}.\"",
|
||||
"na'vi": "{reporter}ìl fpìl futa {reported} fe' lu taluna {reason}."
|
||||
},
|
||||
"reported": {
|
||||
"english": "Thank you, {reported} has been reported to the channel administrators.",
|
||||
"en": "Thank you, {reported} has been reported to the channel administrators.",
|
||||
"na'vi": "Irayo si ngari, fìtsengìri ayeyktan omum teri {reported}it set."
|
||||
},
|
||||
"user_not_found": {
|
||||
"english": "{reported} isn't a known user in {channel}.",
|
||||
"en": "{reported} isn't a known user in {channel}.",
|
||||
"na'vi": "Oel ke omum {reported}it mì {channel}."
|
||||
},
|
||||
"not_in_channel": {
|
||||
"english": "I am not present in {channel}.",
|
||||
"en": "I am not present in {channel}.",
|
||||
"na'vi": "Oel {channel}it ke tok."
|
||||
}
|
||||
}
|
||||
|
@ -1,14 +1,14 @@
|
||||
{
|
||||
"spelling_self": {
|
||||
"english": "{correcter} meant: {fix}",
|
||||
"spanish": "{correcter} quería decir: {fix}",
|
||||
"en": "{correcter} meant: {fix}",
|
||||
"es": "{correcter} quería decir: {fix}",
|
||||
"na'vi": "Sweylu {correcter} pamrel sivi: {fix}",
|
||||
"welsh": "Oedd {correcter} yn feddwl: {fix}"
|
||||
"cy": "Oedd {correcter} yn feddwl: {fix}"
|
||||
},
|
||||
"spelling_other": {
|
||||
"english": "{correcter} thinks {candidate} meant: {fix}",
|
||||
"spanish": "{correcter} piensa que {candidate} queria decir: {fix}",
|
||||
"en": "{correcter} thinks {candidate} meant: {fix}",
|
||||
"es": "{correcter} piensa que {candidate} queria decir: {fix}",
|
||||
"na'vi": "{correcter} fpìl futa sweylu {candiate} pamrel sivi: {fix}",
|
||||
"welsh": "Mae {correcter} yn meddwl bod {candidate} yn feddwl: {fix}"
|
||||
"cy": "Mae {correcter} yn meddwl bod {candidate} yn feddwl: {fix}"
|
||||
}
|
||||
}
|
||||
|
4
modules/spotify/config.json
Normal file
4
modules/spotify/config.json
Normal file
@ -0,0 +1,4 @@
|
||||
{
|
||||
"dependencies": [ "command" ],
|
||||
"ignorable": true
|
||||
}
|
73
modules/spotify/spotify.js
Normal file
73
modules/spotify/spotify.js
Normal file
@ -0,0 +1,73 @@
|
||||
var request = require('request'),
|
||||
_ = require('underscore')._;
|
||||
|
||||
var spotify = function(dbot) {
|
||||
/* examples:
|
||||
* http://open.spotify.com/track/42SYMWISn7xUpTNPLw9V5E
|
||||
* spotify:track:42SYMWISn7xUpTNPLw9V5E
|
||||
* http://open.spotify.com/artist/3yY2gUcIsjMr8hjo51PoJ8
|
||||
* spotify:artist:3yY2gUcIsjMr8hjo51PoJ8
|
||||
* http://open.spotify.com/album/30g571JKoxs8AnsgAViV2J
|
||||
* spotify:album:30g571JKoxs8AnsgAViV2J
|
||||
*/
|
||||
this.spotifyRegex = /(\b(https?:\/\/open.spotify.com\/(artist|track|album)\/\w*|spotify:(artist|track|album):\w*)\b)/ig;
|
||||
this.spotifyLookup = 'http://ws.spotify.com/lookup/1/.json';
|
||||
this.spotifySearch = 'http://ws.spotify.com/search/1/track.json';
|
||||
|
||||
this.lookup = function(event, link) {
|
||||
request({
|
||||
url: this.spotifyLookup,
|
||||
qs: {uri: link},
|
||||
json: true
|
||||
}, function(error, response, body) {
|
||||
if (!error && response.statusCode == 200) {
|
||||
var spotify = "\u00039spotify\u000f";
|
||||
if (_.has(body, 'track')) {
|
||||
event.reply(dbot.t("track", {s: spotify, artist: _.map(body.track.artists, function(a) { return a.name }).join(', '), album: body.track.album.name, track: body.track.name}));
|
||||
}
|
||||
else if (_.has(body, 'album')) {
|
||||
event.reply(dbot.t("album", {s: spotify, artist: body.album.artist, album: body.album.name}));
|
||||
}
|
||||
else if (_.has(body, 'artist')) {
|
||||
event.reply(dbot.t("artist", {s: spotify, artist: body.artist.name}));
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
var commands = {
|
||||
'~spotify': function(event) {
|
||||
var query = event.input[1];
|
||||
request({
|
||||
url: this.spotifySearch,
|
||||
qs: {q: query},
|
||||
json: true
|
||||
}, function(error, response, body) {
|
||||
if (!error && response.statusCode == 200) {
|
||||
var spotify = "\u00039spotify\u000f";
|
||||
if (_.has(body, 'tracks') && body.tracks[0] && _.has(body.tracks[0], 'href')) {
|
||||
var t = body.tracks[0].href;
|
||||
t = t.replace(/:/g, '/');
|
||||
t = t.replace(/spotify/, 'http://open.spotify.com');
|
||||
event.reply(dbot.t("found", {s: spotify, artist: _.map(body.tracks[0].artists, function(a) { return a.name }).join(', '), album: body.tracks[0].album.name, track: body.tracks[0].name, url: t}));
|
||||
} else {
|
||||
event.reply(dbot.t("not-found", {s: spotify}));
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
};
|
||||
commands['~spotify'].regex = [/^~spotify (.*)/, 2];
|
||||
this.listener = function(event) {
|
||||
var spotifyMatches = event.message.match(this.spotifyRegex);
|
||||
if (spotifyMatches != null) {
|
||||
this.lookup(event, spotifyMatches[0]);
|
||||
}
|
||||
}.bind(this);
|
||||
this.on = 'PRIVMSG';
|
||||
this.commands = commands;
|
||||
};
|
||||
|
||||
exports.fetch = function(dbot) {
|
||||
return new spotify(dbot);
|
||||
};
|
18
modules/spotify/strings.json
Normal file
18
modules/spotify/strings.json
Normal file
@ -0,0 +1,18 @@
|
||||
{
|
||||
"artist": {
|
||||
"english": "{s} [artist] {artist}"
|
||||
},
|
||||
"album": {
|
||||
"english": "{s} [album] {artist} – {album}"
|
||||
},
|
||||
"track": {
|
||||
"english": "{s} [track] {artist} – {track} (from {album})"
|
||||
},
|
||||
"found": {
|
||||
"english": "{s} [{url}] {artist} – {track} (from {album})"
|
||||
},
|
||||
"not-found": {
|
||||
"english": "{s} No results.",
|
||||
"na'vi": "{s}, Oel ke tsun rivum ayuoti."
|
||||
}
|
||||
}
|
@ -1,26 +1,26 @@
|
||||
{
|
||||
"alias": {
|
||||
"english": "{alias} is an alias of {user}",
|
||||
"en": "{alias} is an alias of {user}",
|
||||
"na'vi": "ayfko syaw {user} {alias} nìteng"
|
||||
},
|
||||
"primary": {
|
||||
"english": "{user} is a primary user with {count} aliases, ",
|
||||
"en": "{user} is a primary user with {count} aliases, ",
|
||||
"na'vi": "{user} lu txin ulte {count}a stxo lu poru, "
|
||||
},
|
||||
"unknown_alias": {
|
||||
"english": "{alias} does not currently exist as an alias or known user.",
|
||||
"en": "{alias} does not currently exist as an alias or known user.",
|
||||
"na'vi": "{alias} ke fkeytok nìfkrr"
|
||||
},
|
||||
"aliasparentset": {
|
||||
"english": "{newParent} is now the parent user, and {newAlias} is an alias.",
|
||||
"en": "{newParent} is now the parent user, and {newAlias} is an alias.",
|
||||
"na'vi": "{newParent} lu sa'sem set ulte {newAlias} lu stxo set nìteng."
|
||||
},
|
||||
"unprimary_error": {
|
||||
"english": "One of those users isn't currently recorded as a primary user.",
|
||||
"en": "One of those users isn't currently recorded as a primary user.",
|
||||
"na'vi": "fo sute txin ke lu."
|
||||
},
|
||||
"merged_users": {
|
||||
"english": "{old_user} and their aliases have been merged into {new_user}.",
|
||||
"en": "{old_user} and their aliases have been merged into {new_user}.",
|
||||
"na'vi": "{old_user} ulte stxo alahe {new_user} lu set."
|
||||
}
|
||||
}
|
||||
|
2
run.js
2
run.js
@ -94,7 +94,7 @@ DBot.prototype.t = function(string, formatData) {
|
||||
if(_.has(this.strings, string)) {
|
||||
var lang = this.config.language;
|
||||
if(!_.has(this.strings[string], lang)) {
|
||||
lang = "english";
|
||||
lang = "en";
|
||||
}
|
||||
|
||||
formattedString = this.strings[string][lang].format(formatData);
|
||||
|
14
strings.json
14
strings.json
@ -1,17 +1,17 @@
|
||||
{
|
||||
"correction": {
|
||||
"english": "Did you mean: ",
|
||||
"spanish": "¿Querías decir: ",
|
||||
"en": "Did you mean: ",
|
||||
"es": "¿Querías decir: ",
|
||||
"na'vi": "Srake sweylu nga pamrel sivi: ",
|
||||
"welsh": "A oeddech chi'n feddwl: "
|
||||
"cy": "A oeddech chi'n feddwl: "
|
||||
},
|
||||
"module_load_error": {
|
||||
"english": "Failed to load module: {moduleName}",
|
||||
"spanish": "No se pudó cargar el módulo: {moduleName}",
|
||||
"en": "Failed to load module: {moduleName}",
|
||||
"es": "No se pudó cargar el módulo: {moduleName}",
|
||||
"na'vi": "Oeru Oel {moduleName}it sung.",
|
||||
"welsh": "Wedi methu a llwytho modiwl: {moduleName}"
|
||||
"cy": "Wedi methu a llwytho modiwl: {moduleName}"
|
||||
},
|
||||
"url": {
|
||||
"english": "http://{host}:{port}/{path}"
|
||||
"en": "http://{host}:{port}/{path}"
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user