[systemd-devel] [PATCH 2/2] accelerometer: display short options too

Zbigniew Jędrzejewski-Szmek zbyszek at in.waw.pl
Tue Dec 30 16:14:42 PST 2014


On Tue, Dec 30, 2014 at 08:29:27PM +0100, Paul Menzel wrote:
> Am Dienstag, den 30.12.2014, 18:58 +0100 schrieb Robert Milasan:
> > ---
> >  src/udev/accelerometer/accelerometer.c | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> Awesome! Thank you for splitting these up and submitting a v2!
> 
> > diff --git a/src/udev/accelerometer/accelerometer.c
> > b/src/udev/accelerometer/accelerometer.c index 23d6f78..9c13d97 100644
> > --- a/src/udev/accelerometer/accelerometer.c
> > +++ b/src/udev/accelerometer/accelerometer.c
> > @@ -198,8 +198,8 @@ static void test_orientation(struct udev *udev,
> >  static void help(void)
> >  {
> >          printf("Usage: accelerometer [options] <device path>\n"
> > -               "  --debug         debug to stderr\n"
> > -               "  --help          print this help text\n\n");
> > +               "  -d,--debug         debug to stderr\n"
> > +               "  -h,--help          print this help text\n\n");
> 
> 1. I still wonder if the description is aligned after this patch is
> applied.
> 2. A space after the comma, `-d, --debug` would be helpful in my
> opinion.

It's good enough. Other code in src/udev uses this style. If they
are changed to be more like the rest of systemd, it can all be done
in one fell swoop.

Applied.

Zbyszek


More information about the systemd-devel mailing list