diff options
author | Yaohan Chen <yaohan.chen@gmail.com> | 2007-07-09 08:31:45 +0000 |
---|---|---|
committer | Yaohan Chen <yaohan.chen@gmail.com> | 2007-07-09 08:31:45 +0000 |
commit | 069d8c8dd5ab841cc5efcfeae1cdc2e7f93c2976 (patch) | |
tree | 49df20137605bccaeff99ef4340c0d3551f090f7 /lib/rbot/botuser.rb | |
parent | 47fd0312cf67aab35ba3cfd3ef898f83b09a7f0f (diff) |
integrated ruby-gettext
modified a few files to allow translated messages
created gettext template file
initialized gettext files for Japanese and Simplified Chinese
Diffstat (limited to 'lib/rbot/botuser.rb')
-rw-r--r-- | lib/rbot/botuser.rb | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/rbot/botuser.rb b/lib/rbot/botuser.rb index 9a34b341..8d01632e 100644 --- a/lib/rbot/botuser.rb +++ b/lib/rbot/botuser.rb @@ -19,13 +19,13 @@ module Irc BotConfig.register BotConfigStringValue.new( 'auth.password',
:default => 'rbotauth', :wizard => true,
- :desc => 'Password for the bot owner' )
+ :desc => _('Password for the bot owner'))
BotConfig.register BotConfigBooleanValue.new( 'auth.login_by_mask',
:default => 'true',
- :desc => 'Set false to prevent new botusers from logging in without a password when the user netmask is known')
+ :desc => _('Set false to prevent new botusers from logging in without a password when the user netmask is known'))
BotConfig.register BotConfigBooleanValue.new( 'auth.autologin',
:default => 'true',
- :desc => 'Set false to prevent new botusers from recognizing IRC users without a need to manually login')
+ :desc => _('Set false to prevent new botusers from recognizing IRC users without a need to manually login'))
# BotConfig.register BotConfigIntegerValue.new( 'auth.default_level',
# :default => 10, :wizard => true,
# :desc => 'The default level for new/unknown users' )
@@ -683,7 +683,8 @@ module Irc else
# cmds = cmdtxt.split('::')
# @bot.say chan, "you don't have #{cmds.last} (#{cmds.first}) permissions here" if chan
- @bot.say chan, "#{user}, you don't have '#{cmdtxt}' permissions here" if chan
+ @bot.say chan, _("%{user}, you don't have '%{command}' permissions here") %
+ {:user=>user, :command=>cmdtxt} if chan
return false
end
end
|