all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* vc-git: interactive rebasing
@ 2021-12-03 10:13 Manuel Uberti
  2021-12-03 12:40 ` Dmitry Gutov
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Manuel Uberti @ 2021-12-03 10:13 UTC (permalink / raw)
  To: emacs-devel

Hello everyone,

as my recent bug report[1] and some writings on my blog[2] witness, I've been 
using and actually really liking the built-in VC. Beside thanking everyone 
involved with this feature, I'd like to know how one can approach an interactive 
rebase with it.

Let me try to provide an example. Usually, 'M-! git rebase master' is enough 
when I work on my projects, but sometimes I need to squash commits before 
pushing. Is it possible to rely on VC for this? If it is not a problem, could 
you describe how you would do it?

Note that relying on 'M-!' or 'shell-mode' is good too for me. As long as 
everything can be done from Emacs, I am not asking to extend VC just for this 
specific workflow.

BTW, before anyone suggests it: I know this is all doable from Magit, I was 
using Magit before (and I still have it installed). I am just trying to 
understand a different approach in order to decide which one suits me best.



[1] https://debbugs.gnu.org/cgi/bugreport.cgi?bug=52158
[2] https://www.manueluberti.eu/emacs/2021/11/27/vc/

-- 
Manuel Uberti
www.manueluberti.eu



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: vc-git: interactive rebasing
  2021-12-03 10:13 vc-git: interactive rebasing Manuel Uberti
@ 2021-12-03 12:40 ` Dmitry Gutov
  2021-12-03 13:16   ` Manuel Uberti
  2021-12-03 13:20 ` Stefan Monnier
  2021-12-03 18:46 ` Thierry Volpiatto
  2 siblings, 1 reply; 8+ messages in thread
From: Dmitry Gutov @ 2021-12-03 12:40 UTC (permalink / raw)
  To: Manuel Uberti, emacs-devel

On 03.12.2021 13:13, Manuel Uberti wrote:
> Let me try to provide an example. Usually, 'M-! git rebase master' is 
> enough when I work on my projects, but sometimes I need to squash 
> commits before pushing. Is it possible to rely on VC for this? If it is 
> not a problem, could you describe how you would do it?

I do that from the console. ;-(

git rebase -i <branch>

It's not too bad, since you usually don't need to edit the commit 
messages (much), or stage/unstage changes, for example.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: vc-git: interactive rebasing
  2021-12-03 12:40 ` Dmitry Gutov
@ 2021-12-03 13:16   ` Manuel Uberti
  2021-12-03 13:26     ` Dmitry Gutov
  0 siblings, 1 reply; 8+ messages in thread
From: Manuel Uberti @ 2021-12-03 13:16 UTC (permalink / raw)
  To: Dmitry Gutov, emacs-devel

On 03/12/21 13:40, Dmitry Gutov wrote:
> I do that from the console. ;-(
> 
> git rebase -i <branch>
> 
> It's not too bad, since you usually don't need to edit the commit messages 
> (much), or stage/unstage changes, for example.

Interesting. Do you use Emacs (or emacsclient perhaps) to eventually edit the 
commit messages?

-- 
Manuel Uberti
www.manueluberti.eu



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: vc-git: interactive rebasing
  2021-12-03 10:13 vc-git: interactive rebasing Manuel Uberti
  2021-12-03 12:40 ` Dmitry Gutov
@ 2021-12-03 13:20 ` Stefan Monnier
  2021-12-03 18:46 ` Thierry Volpiatto
  2 siblings, 0 replies; 8+ messages in thread
From: Stefan Monnier @ 2021-12-03 13:20 UTC (permalink / raw)
  To: Manuel Uberti; +Cc: emacs-devel

> Let me try to provide an example.  Usually, 'M-! git rebase master' is enough
> when I work on my projects, but sometimes I need to squash commits before
> pushing.  Is it possible to rely on VC for this? If it is not a problem,
> could you describe how you would do it?

AFAIK the standard answer here is to use Magit.


        Stefan




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: vc-git: interactive rebasing
  2021-12-03 13:16   ` Manuel Uberti
@ 2021-12-03 13:26     ` Dmitry Gutov
  2021-12-03 14:23       ` Manuel Uberti
  0 siblings, 1 reply; 8+ messages in thread
From: Dmitry Gutov @ 2021-12-03 13:26 UTC (permalink / raw)
  To: Manuel Uberti, emacs-devel

On 03.12.2021 16:16, Manuel Uberti wrote:
> Interesting. Do you use Emacs (or emacsclient perhaps) to eventually 
> edit the commit messages?

My EDITOR is Zile. But emacsclient would work just as well.



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: vc-git: interactive rebasing
  2021-12-03 13:26     ` Dmitry Gutov
@ 2021-12-03 14:23       ` Manuel Uberti
  0 siblings, 0 replies; 8+ messages in thread
From: Manuel Uberti @ 2021-12-03 14:23 UTC (permalink / raw)
  To: Dmitry Gutov, emacs-devel

On 03/12/21 14:26, Dmitry Gutov wrote:
> On 03.12.2021 16:16, Manuel Uberti wrote:
>> Interesting. Do you use Emacs (or emacsclient perhaps) to eventually edit the 
>> commit messages?
> 
> My EDITOR is Zile. But emacsclient would work just as well.

Great, thank you. I set emacsclient as the editor in Git.

-- 
Manuel Uberti
www.manueluberti.eu



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: vc-git: interactive rebasing
  2021-12-03 10:13 vc-git: interactive rebasing Manuel Uberti
  2021-12-03 12:40 ` Dmitry Gutov
  2021-12-03 13:20 ` Stefan Monnier
@ 2021-12-03 18:46 ` Thierry Volpiatto
  2021-12-04  8:18   ` Manuel Uberti
  2 siblings, 1 reply; 8+ messages in thread
From: Thierry Volpiatto @ 2021-12-03 18:46 UTC (permalink / raw)
  To: Manuel Uberti; +Cc: emacs-devel

Manuel Uberti <manuel.uberti@inventati.org> writes:

> I am just trying to understand a different approach in order to decide
> which one suits me best.

Hello Manuel, helm-ls-git have now a mode to rebase interactively.

-- 
Thierry



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: vc-git: interactive rebasing
  2021-12-03 18:46 ` Thierry Volpiatto
@ 2021-12-04  8:18   ` Manuel Uberti
  0 siblings, 0 replies; 8+ messages in thread
From: Manuel Uberti @ 2021-12-04  8:18 UTC (permalink / raw)
  To: emacs-devel, thievol

On 03/12/21 19:46, Thierry Volpiatto wrote:
> Manuel Uberti <manuel.uberti@inventati.org> writes:
> 
>> I am just trying to understand a different approach in order to decide
>> which one suits me best.
> 
> Hello Manuel, helm-ls-git have now a mode to rebase interactively.

That's great and I wasn't aware of it. Thank you, Thierry!

-- 
Manuel Uberti
www.manueluberti.eu



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2021-12-04  8:18 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-12-03 10:13 vc-git: interactive rebasing Manuel Uberti
2021-12-03 12:40 ` Dmitry Gutov
2021-12-03 13:16   ` Manuel Uberti
2021-12-03 13:26     ` Dmitry Gutov
2021-12-03 14:23       ` Manuel Uberti
2021-12-03 13:20 ` Stefan Monnier
2021-12-03 18:46 ` Thierry Volpiatto
2021-12-04  8:18   ` Manuel Uberti

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.