lazygit icon indicating copy to clipboard operation
lazygit copied to clipboard

Merge squash

Open mark2185 opened this issue 3 years ago • 10 comments

Discussed in https://github.com/jesseduffield/lazygit/discussions/1296

Originally posted by mestihudson April 26, 2021 Is there a way to get a git merge <branch> --squash? I know that is possible to use a custom command, but I'd like to follow the lazygit way.

Thanks for this awesome tool.

mark2185 avatar Jul 05 '22 16:07 mark2185

I recommend creating a menu under M in which we'd have options such as:

  • m would merge as usual
  • s would merge with --squash
  • n for --no-commit,
  • e for --edit

I don't know, surely people will think of something.

@jesseduffield what do you say about moving this to the m key, and having the current m (Rebase options) appear only when in a rebase/merge context? Is that easily doable?

I remember reading about that somewhere...

Closing this should also close #650.

mark2185 avatar Jul 22 '22 20:07 mark2185

this would be reallllly sweet

9mm avatar Sep 15 '23 20:09 9mm

@mark2185 all those options are orthogonal so it sounds like we'll need to solve https://github.com/jesseduffield/lazygit/issues/2849 before we can do this (not necessarily the 'complex mode' thing but the menu that lets you configure different args before confirming an action)

jesseduffield avatar Sep 16 '23 05:09 jesseduffield

bump, would love to see this too

all500234765 avatar Mar 18 '24 11:03 all500234765

bump, this would be really great

ofurtumi avatar Apr 03 '24 08:04 ofurtumi