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

Re: How to manage merges from one line while excluding its merges from another

From
Jonathan Nieder <jrnieder@gmail.com>
Date
Jun 26, 2010, 00:51 UTC
Message-ID
<20100626005151.GA12401@burratino>
In-Reply-To
<4C254B62.6020108@brooks.nu>
Lane Brooks wrote:
Show 5 quoted lines
> I'll take a look at your suggested cherry-pick script. Can it be
> rerun multiple times or is it run one-time only. In others, as
> 'devel' continues to grow can I run it again and will it cherry-pick
> intelligently or will it try to reapply commits already
> cherry-picked?
Good point.
  git cherry my devel main |
  grep -v ^- |
  while read mark rev
  do
	git cherry-pick $rev ||
	{
		echo >&2 cherry-pick failed
		break
	}
 done

I hadn’t known about the third argument to ‘git cherry’ before. Thanks for the example.

Previous: Lane Brooks
Message 4 of 4 in “How to manage merges from one line while excluding its merges from another”
  1. Lane BrooksJun 25, 2010
  2. Jonathan NiederJun 26, 2010
  3. Lane BrooksJun 26, 2010
  4. Jonathan NiederJun 26, 2010

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.