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

Re: how to squash a few commits in the past

From
GGelonida <gelonida@gmail.com>
Date
May 5, 2010, 21:41 UTC
Message-ID
<4BE1E5F6.3040606@gmail.com>
In-Reply-To
<w2zf3271551005050619td67d697y97d7e9181c4496fc@mail.gmail.com>
Hi Ragu,
Ramkumar Ramachandra wrote:
Show 15 quoted lines
> Hi,
> 
> On Mon, May 3, 2010 at 11:20 PM, Gelonida <gelonida@gmail.com> wrote:
>> Is it normal, that git gets lost wehn rebasing such a structure.
> 
> While performing an interactive rebase, conflicts can often occur and
> this is quite normal.
> 
>>> Automatic cherry-pick failed.  After resolving the conflicts,
>>> mark the corrected paths with 'git add <paths>', and
>>> run 'git rebase --continue'
>>> Could not apply 67f3f6d... preparation for #241
> 
> The problem and solution is described in that message. Open the file,
> resolve the conflict and continue the rebase operation.

Yes merging manually could be a theortical solution, but I really don't understand, why I should merge anything at all.

The history is purely linear at the places where I want to squash.

These two commits precede a few more consecutive commits, traverse then a tree which forks to multiple branches, which partially cherrypick from each other and will then join again to a unique linear sequence.

If I have a history of several hundred commits and I am asked several times to merge, just because I want to squash two consecutve commits without any branches going out or in, then something (probably the way I try to attack the problem or much less likely a mysterious git bug) is kind of wrong.

I'm still looking for a solution, where I specify only the commits to be squashed and everything else stays untouched without any further userinteraction

Previous: Ramkumar RamachandraNext: Johannes Sixt
Message 7 of 8 in “how to squash a few commits in the past”
  1. GelonidaMay 3, 2010
  2. Michael J GruberMay 3, 2010
  3. GelonidaMay 3, 2010
  4. GelonidaMay 3, 2010
  5. GelonidaMay 3, 2010
  6. Ramkumar RamachandraMay 5, 2010
  7. GelonidaMay 5, 2010
  8. Johannes SixtMay 6, 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.