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

Re: [PATCH v2] git-svn: Make following parents atomic

From
Junio C Hamano <gitster@pobox.com>
Date
Dec 8, 2008, 08:33 UTC
Message-ID
<7v1vwj83sd.fsf@gitster.siamese.dyndns.org>
In-Reply-To
<1228717252-1016-1-git-send-email-deskinm@umich.edu>
Deskin Miller <deskinm@umich.edu> writes:
Show 8 quoted lines
> +test_expect_success "follow-parent is atomic" '
> +	cd wc &&
> +	svn up &&
> +	svn mkdir stunk &&
> +	cd stunk &&
> +	echo "trunk stunk" > readme &&
> +	svn add readme &&
> +	cd .. &&

If you need to chdir around inside a test, please do that in a subshell, so that after failing any command in between, the next test will not start in an unexpected directory.

Show 7 quoted lines
> +	svn ci -m "trunk stunk" &&
> +	echo "stunk like junk" >> stunk/readme &&
> +	svn ci -m "really stunk" &&
> +	echo "stink stank stunk" >> stunk/readme &&
> +	svn ci -m "even the grinch agrees" &&
> +	cd .. &&
> +	svn copy -m "stunk flunked" "$svnrepo"/stunk "$svnrepo"/flunk &&
> +	(svn cp -m "early stunk flunked too" \
> +		"$svnrepo"/stunk@17 "$svnrepo"/flunked ||
> +	svn cp -m "early stunk flunked too" \
> +		-r17 "$svnrepo"/stunk "$svnrepo"/flunked) &&

On the other hand, I do not see a need for this portion to be in a subshell. Wouldn't a normal statement grouping with {} work just as well?

Previous: Deskin MillerNext: Deskin Miller
Message 5 of 9 in “git-svn: Make following parents atomic”
  1. git-svn: Make following parents atomicDeskin Miller, Dec 7, 2008
  2. [ANNOUNCE] git-svn-bugfix script (Re: [PATCH] git-svn: Make following parents atomic)Deskin Miller, Dec 7, 2008
  3. Deskin MillerDec 7, 2008
  4. git-svn: Make following parents atomicDeskin Miller, Dec 8, 2008
  5. Junio C HamanoDec 8, 2008
  6. git-svn: Make following parents atomicDeskin Miller, Dec 8, 2008
  7. Eric WongDec 8, 2008
  8. Thomas JaroschDec 16, 2008
  9. Thomas JaroschDec 22, 2008

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.