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

Re: cvsexportcommit dies when applying an (empty) merge commit

From
Robin Rosenberg <robin.rosenberg.lists@dewire.com>
Date
Nov 26, 2009, 06:51 UTC
Message-ID
<200911260751.06377.robin.rosenberg.lists@dewire.com>
In-Reply-To
<4B0D1C1A.60707@yahoo.co.uk>
onsdag 25 november 2009 12:59:22 skrev  Nick Woolley:
Show 25 quoted lines
> Hi,
>
> I have a git repository with a merge point on the master branch.  This
> merge commit is empty, and just contains a commit message:
>
>   Merge commit 'otherbranch'
>
> I'm trying to export this branch into CVS using git-cvsexportcommit (the
> latest version from the master branch). It's actually done in a wrapper
> script [1] but the command that gets invoked is essentially:
>
>  git cvsexportcommit -p -v -u -w  'cvscheckout/HEAD/my-cvs-module' -c \
>     <parent commit> <commit>
>
> Where <commit> is the empty merge commit.  However this invocation dies and
> aborts the process of exporting the branch half way.
>
> The fatal error I get is:
>
>  Applying to CVS commit <commit> from parent <parent commit>
>  Checking if patch will apply
>  Applying
>  error: No changes
>  cannot patch at /usr/lib/git-core/git-cvsexportcommit line 324.
>
[....]
> Is the existing behaviour deliberately fatal, or is this worth supplying a
> patch for?

I'm not the only contributor, but I'd say its a omission. cvsexportcommit doesn't export commits. It export deltas, that is the change relative to one of the parents. It is reasonable that cvsexportcommit can "export" an empty commit by doing nothing and exiting with 0. Printing some kind of warning seems reasonable too.

- robin
Previous: Nick Woolley
Message 4 of 4 in “cvsexportcommit dies when applying an (empty) merge commit”
  1. Nick WoolleyNov 25, 2009
  2. Michael J GruberNov 25, 2009
  3. Nick WoolleyNov 25, 2009
  4. Robin RosenbergNov 26, 2009

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.