[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to commit hunks using VC?

From: Stefan Monnier
Subject: Re: How to commit hunks using VC?
Date: Fri, 26 Oct 2018 11:56:02 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

> Is it possible to commit only some hunks using VC?

Many years ago, I used a local patch to VC that allowed me to do
"partial commits".  The way it worked, basically was:
- save/copy the current changes to some auxiliary file (there was no
  `git stash` back then, but it was similar, except it didn't actually
  change the files).
- then I could undo the hunks I didn't want to commit any which way
  I wanted (using diff-mode or manual editing, you name it).
- upon commit the previously saved changes were automatically be
  brought back.

Nowadays, you can basically do the same with `git stash`, but there's
indeed no "generic VC" support for it (only for the Git backend).


reply via email to

[Prev in Thread] Current Thread [Next in Thread]