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

[bug report]: error doing_rebase

From
BMBulat Musin <mbulatka@yandex.ru>
Date
Feb 5, 2018, 19:26 UTC
Message-ID
<d4246fa9-5ca2-33c9-d7b6-07adfd9b55a6@yandex.ru>
Hi.
To reproduce:
git init testrepo
cd testrepo
echo 1 >> file
git add file
git commit -m'1'
echo 2 >> file
git add file
git commit -m'2'
echo 3 >> file
git add file
git commit -m'3'
Now there are 3 sequential commits, I want to squash them into 1:
git rebase -i HEAD~2
In editor I changed all "pick" to "squash", saved file, I got:

error: cannot 'squash' without a previous commit You can fix this with 'git rebase --edit-todo' and then run 'git rebase --continue'. Or you can abort the rebase with 'git rebase --abort'.

However, 2.14.1 from Ubuntu's repo does the job - squashes 3 commits into 1.
Thanks.
git version 2.16.1.72.g5be1f00a9
Next: Johannes Schindelin
Message 1 of 3 in “[bug report]: error doing_rebase”
  1. Bulat MusinFeb 5, 2018
  2. Johannes SchindelinFeb 6, 2018
  3. Johannes SchindelinFeb 7, 2018

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.