mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-23 19:19:32 +01:00
Added Babelfish.languages (which we should've had long ago)
This commit is contained in:
parent
ede140bcde
commit
aa6e663768
@ -58,6 +58,14 @@ class Babelfish(callbacks.Privmsg):
|
|||||||
_abbrevs['zh'] = 'chinese'
|
_abbrevs['zh'] = 'chinese'
|
||||||
for language in babelfish.available_languages:
|
for language in babelfish.available_languages:
|
||||||
_abbrevs[language] = language
|
_abbrevs[language] = language
|
||||||
|
|
||||||
|
def languages(self, irc, msg, args):
|
||||||
|
"""takes no arguments
|
||||||
|
|
||||||
|
Returns the languages that Babelfish can translate to/from.
|
||||||
|
"""
|
||||||
|
irc.reply(utils.commaAndify(babelfish.available_languages))
|
||||||
|
|
||||||
def translate(self, irc, msg, args):
|
def translate(self, irc, msg, args):
|
||||||
"""<from-language> [to] <to-language> <text>
|
"""<from-language> [to] <to-language> <text>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user