git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Fix clone not to ignore depth when performing a local clone

From
Charles Bailey <charles@hashpling.org>
Date
Dec 11, 2007, 18:26 UTC
Message-ID
<20071211182603.GA4063@hashpling.org>
In-Reply-To
<Pine.LNX.4.64.0712111154070.27959@racer.site>
On Tue, Dec 11, 2007 at 11:54:54AM +0000, Johannes Schindelin wrote:
Show 23 quoted lines
> Hi,
> 
> On Tue, 11 Dec 2007, Charles Bailey wrote:
> 
> > @@ -205,7 +205,10 @@ fi
> >  # it is local
> >  if base=$(get_repo_base "$repo"); then
> >  	repo="$base"
> > -	local=yes
> > +	if test -z "$depth"
> > +	then
> > +		local=yes
> > +	fi
> >  fi
> 
> Or shorter:
> 
> -	local=yes
> +	test -z "$depth" && local=yes
> 
> Ciao,
> Dscho
> 

Yes, I have no particular preference. I was just following the 'convention' of the -z "$origin" test a few lines above although I could see uses of both alternatives as well as instances of [...] instead of test ... .

Charles.
Previous: Johannes Schindelin
Message 3 of 3 in “Fix clone not to ignore depth when performing a local clone”
  1. Fix clone not to ignore depth when performing a local cloneCharles Bailey, Dec 11, 2007
  2. Johannes SchindelinDec 11, 2007
  3. Charles BaileyDec 11, 2007

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.