Re: [RFC PATCH 3/7] t3705: add tests for `git add` in sparse checkouts

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

 



On Wed, Feb 17, 2021 at 8:22 PM Eric Sunshine <sunshine@xxxxxxxxxxxxxx> wrote:
>
> On Wed, Feb 17, 2021 at 6:04 PM Junio C Hamano <gitster@xxxxxxxxx> wrote:
> > Matheus Tavares <matheus.bernardino@xxxxxx> writes:
> > > +for opt in "" -f -u --ignore-removal
> > > +do
> > > +     if test -n "$opt"
> > > +     then
> > > +             opt=" $opt"
> > > +     fi
> > > +     test_expect_success "git add$opt does not update SKIP_WORKTREE entries" '
> >
> ... A more idiomatic way to do this would
> have been:
>
>     for opt in "" -f -u --ignore-removal
>     do
>         test_expect_success " git add${opt:+ $opt} does ..." '

That's much better, thanks :)



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux