Re: [PATCH v6 3/6] set-head: better output for --auto

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

 



Thanks for the very helpful review on the series! Most of it is clear to me and
I agree with, so for brevity I'll only comment where I have a question/comment.

On Thu Oct 10, 2024 at 23:05, karthik nayak <karthik.188@xxxxxxxxx> wrote:
[snip]

> > diff --git a/t/t5505-remote.sh b/t/t5505-remote.sh
> > index 532035933f..77c12b8709 100755
> > --- a/t/t5505-remote.sh
> > +++ b/t/t5505-remote.sh
> > @@ -429,12 +429,51 @@ test_expect_success 'set-head --auto' '
> >  	)
> >  '
> >
> > +test_expect_success 'set-head --auto detects creation' '
> > +	(
> > +		cd test &&
> > +		rm .git/refs/remotes/origin/HEAD &&
>
> does this work with reftables too?

You got me there, probably not. I'm guessing I should use git update-ref or
something similar to set these values manually instead of editing the file.

On the other hand, is there a way to force the tests to run on a reftables
backend? t/README does not mention anything about this and since in a previous
round it already came up that I forgot to update the reftables backend, it
would be nice if I could actually test everything with that as well.

>
> > +		git remote set-head --auto origin >output &&
> > +		echo "'\''origin/HEAD'\'' is now created and points to '\''main'\''" >expect &&
>
> Nit: might be cleaner to use `${SQ}` here and below
You mean something like this?

	git remote set-head --auto origin >output &&
	HEAD="'\''origin/HEAD'\''" &&
	echo "${HEAD} is now created and points to '\''main'\''" >expect &&

I tried a few variations and this is what I could get working, but I may be
simply missing something with the backtick.

Thanks,
Bence

-- 
bence.ferdinandy.com






[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