Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   ArchLinux Pacman Development (http://www.linux-archive.org/archlinux-pacman-development/)
-   -   pactree: fix --sync getopt value (http://www.linux-archive.org/archlinux-pacman-development/712544-pactree-fix-sync-getopt-value.html)

Dave Reisner 10-15-2012 06:40 PM

pactree: fix --sync getopt value
 
On Mon, Oct 15, 2012 at 02:29:07PM -0400, Andrew Gregory wrote:
> The long --sync options has apparently never worked.
>
> Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
> ---
> src/util/pactree.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/util/pactree.c b/src/util/pactree.c
> index 4488645..ab5d90a 100644
> --- a/src/util/pactree.c
> +++ b/src/util/pactree.c
> @@ -217,7 +217,7 @@ static int parse_options(int argc, char *argv[])
> {"help", no_argument, 0, 'h'},
> {"linear", no_argument, 0, 'l'},
> {"reverse", no_argument, 0, 'r'},
> - {"sync", no_argument, 0, 'S'},
> + {"sync", no_argument, 0, 's'},

wat. Could you give an example of this breaking? Even if it is, I can't
possibly understand how this is the correct fix. -s is strictly --search
whereas --sync is a toplevel action and must therefore by capitalized.

# pacman --sync -yy
:: Synchronizing package databases...
staging 40.9 KiB 444K/s 00:00 [---------------------] 100%
allanbrokeit 876.0 B 0.00B/s 00:00 [---------------------] 100%
allanbrokeit.sig 287.0 B 0.00B/s 00:00 [---------------------] 100%
etc etc...



> {"unique", no_argument, 0, 'u'},
>
> {"config", required_argument, 0, OP_CONFIG},
> --
> 1.7.12.2
>
>

Dave Reisner 10-15-2012 06:42 PM

pactree: fix --sync getopt value
 
On Mon, Oct 15, 2012 at 02:40:18PM -0400, Dave Reisner wrote:
> On Mon, Oct 15, 2012 at 02:29:07PM -0400, Andrew Gregory wrote:
> > The long --sync options has apparently never worked.
> >
> > Signed-off-by: Andrew Gregory <andrew.gregory.8@gmail.com>
> > ---
> > src/util/pactree.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/src/util/pactree.c b/src/util/pactree.c
> > index 4488645..ab5d90a 100644
> > --- a/src/util/pactree.c
> > +++ b/src/util/pactree.c
> > @@ -217,7 +217,7 @@ static int parse_options(int argc, char *argv[])
> > {"help", no_argument, 0, 'h'},
> > {"linear", no_argument, 0, 'l'},
> > {"reverse", no_argument, 0, 'r'},
> > - {"sync", no_argument, 0, 'S'},
> > + {"sync", no_argument, 0, 's'},
>
> wat. Could you give an example of this breaking? Even if it is, I can't
> possibly understand how this is the correct fix. -s is strictly --search
> whereas --sync is a toplevel action and must therefore by capitalized.
>
> # pacman --sync -yy
> :: Synchronizing package databases...
> staging 40.9 KiB 444K/s 00:00 [---------------------] 100%
> allanbrokeit 876.0 B 0.00B/s 00:00 [---------------------] 100%
> allanbrokeit.sig 287.0 B 0.00B/s 00:00 [---------------------] 100%
> etc etc...
>

Yay ignore this, I can't read. Your patch is fine.

>
>
> > {"unique", no_argument, 0, 'u'},
> >
> > {"config", required_argument, 0, OP_CONFIG},
> > --
> > 1.7.12.2
> >
> >


All times are GMT. The time now is 11:56 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.