[Nagiosplug-devel] localisation next ;-)

Andreas Ericsson ae at op5.se
Tue Nov 30 01:09:04 CET 2004


Benoit Mortier wrote:
> Hello,
> 
> sorry to bother you with all those message...
> 
> #: plugins/check_nwstat.c:297 plugins/check_nwstat.c:322
> #: plugins/check_nwstat.c:442 plugins/check_nwstat.c:463
> #: plugins/check_nwstat.c:495 plugins/check_nwstat.c:516
> Error: Volume '%s' does not exist!
> 
> Error Should be Capitalized
> 
> #: plugins/check_nwstat.c:612
> Critical: Time not in sync with network!
> 
> Crtitical Should be Capitalized
> 

This seems like a fairly common problem. I'm sure something like this 
would catch most of them;

sed -i -e 's/_("Critical/_("CRITICAL/' -e 's/_("Warning/_("WARNING/' \
-e 's/\(usage[2 ]*\)(_("CRITICAL /\1(_("Critical/' \
-e 's/\(usage[2 ]*\)(_("WARNING /\1(_("Warning/' \
plugins/*.c

At least this works properly with sed 4.1.1. The last two lines could 
ofcourse be dropped if you want usage output to capitalise CRITICAL and 
WARNING when either one starts a message.

> #: plugins/check_nwstat.c:615
> OK! Time in sync with network!
> 
> the OK! should be remplaced by OK
> 

Most plugins use "OK - message" or "OK: message". The "OK" part could be 
stripped entirely since it doesn't add much for users running the nagios 
gui (although it IS nice to have when you're debugging plugins).

> #: plugins/check_overcr.c:460
>  - This plugin requres that Eric Molitors' Over-CR collector daemon be\n
> 
> requres should be requires
> 

-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Lead Developer




More information about the Devel mailing list