On Tuesday 24 of August 2010 11:46:12 Marc Herbert wrote: > Hi, > > Since the --terse option of nmcli is obviously meant to be parsed, > shouldn't it ignore locales? Or maybe avail two options: --terse versus > --cterse. > > LANG=ko_KR.utf8 nmcli --terse --fields state nm > 연결 끊겼음 > >
It's always safer to use LC_ALL=C (or LANG=C) when parsing program outputs and not to rely on output not being localized. In many cases it is. Think of e.g. 'date'. Moreover, I think it's better, for consistency, to have output localized regardless of specified options. And instead of adding another option, you can simple set C locale. But I agree that we can emphasize in man page that the output is localized and one should consider that when parsing. Jirka Some localization recommendations: http://developers.sun.com/dev/gadc/technicalpublications/articles/archi18n.html _______________________________________________ networkmanager-list mailing list [email protected] http://mail.gnome.org/mailman/listinfo/networkmanager-list
