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

Re: [PATCH/RFCv2 1/2] git-rebase -i: add command "drop" to remove a commit

From
Remi Galan Alfonso <remi.galan-alfonso@ensimag.grenoble-inp.fr>
Date
Jun 2, 2015, 07:23 UTC
Message-ID
<150689518.4344.1433229813195.JavaMail.zimbra@ensimag.grenoble-inp.fr>
In-Reply-To
<vpqoakz1dke.fsf@anie.imag.fr>
Show 7 quoted lines
> Ideally, I think we should do a sanity check before starting the rebase,
> and error out if we encounter an invalid command, a command that should
> be followed by a valid sha1 and does not, ...
> 
> But currently, we do the verification while applying commands, and I
> don't think there's anything really helpful to do if we encounter a
> "drop this-is-not-a-sha1" command.

While I agree that doing a sanity check before starting the rebase is a better idea, it would not be logic to do so only for the 'drop' command, it should be done for all of the various commands (as you said, checking if the commands are valid, checking if the SHA-1 following the command is valid if it was expecting one...).

However I think that it should be in a different patch, changing the whole checking system of rebase is not directly linked to the idea of the 'drop' command.

Rémi
Previous: Matthieu MoyNext: Matthieu Moy
Message 7 of 12 in “rebase -i : drop command and removed commits”
  1. 0/2 rebase -i : drop command and removed commitsGalan Rémi, Jun 1, 2015
  2. 1/2 git-rebase -i: add command "drop" to remove a commitGalan Rémi, Jun 1, 2015
  3. Junio C HamanoJun 1, 2015
  4. Matthieu MoyJun 1, 2015
  5. Remi Galan AlfonsoJun 1, 2015
  6. Matthieu MoyJun 1, 2015
  7. Remi Galan AlfonsoJun 2, 2015
  8. Matthieu MoyJun 2, 2015
  9. Junio C HamanoJun 2, 2015
  10. Remi Galan AlfonsoJun 3, 2015
  11. Junio C HamanoJun 3, 2015
  12. 2/2 git rebase -i: warn about removed commitsGalan Rémi, Jun 1, 2015

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.