From: Matheus Tavares Bernardino Date: Thu, 18 Feb 2021 03:11:37 GMT Subject: Re: [RFC PATCH 3/7] t3705: add tests for `git add` in sparse checkouts Message-ID: In-Reply-To: On Wed, Feb 17, 2021 at 8:22 PM Eric Sunshine wrote: > > On Wed, Feb 17, 2021 at 6:04 PM Junio C Hamano wrote: > > Matheus Tavares 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 :)