[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: gettext util

From: Carles Pina i Estany
Subject: Re: gettext util
Date: Sun, 28 Mar 2010 23:05:52 +0100
User-agent: Mutt/1.5.20 (2009-06-14)


On Mar/28/2010, Vladimir '??-coder/phcoder' Serbinenko wrote:
> Carles Pina i Estany wrote:

> > b) Makes the alignment more difficult
> >   
> Why not just do like
> "  -h, --help                %s\n"
> "  -V, --version             %s\n"
> "  -v, --verbose             %s\n", _("display this message and exit"), _ 
> ("print version information and exit"), _("print verbose messages")

My reasons for argp:
a) if someone/something else can take care of counting how many spaces
before the short options, to write the "," and space and the long
option, etc. then is something that we don't need to think and do. Good for
consistency between Grub programs and other utilities

b) to not have some presentation things in Grub code (spaces, tabs,

(main one:)
c) using above way is very easy to do mistakes and swap the description
and the command of some option, let's say, updating things OR options
that depends of the platform/compiler options. It needs two ifdef in two
places instead of only one in argp and more clear, since the argp structure is

/* The options we understand. */
static struct argp_option options[] = {
{"verbose",  'v', 0,      0,  "Produce verbose output" },
{"quiet",    'q', 0,      0,  "Don't produce any output" },

All my reasons are valid if the implementation in Grub doesn't have
special problems, else I would re-consider...

Probably I'm forgetting some more positive things and missing some negative


Carles Pina i Estany

reply via email to

[Prev in Thread] Current Thread [Next in Thread]