What if you have too many changes inside one patch in the hg mq patch queue?

The purpose of the hg mq plugin is to be able to make perfect commits in your repository, not to confuse the changes you made to your diffuse ADHD caused by incoherence through your code;

For instance....

I work on the x error when I notice the y error and start working on it. At this point, you should create a new patch in the patch queue so as not to confuse the changes when it is hg qfinishbound to your repository.

Now suppose that in a minute you forgot to make a new patch in the process hg qrefresh. Then, realizing your mistake, you want to separate the changes from one patch into two patches.

I understand that it involves editing the patch file (and the new patch file) in the queue in order to separate the changes from the individual patches and commit them later. However, I still cannot edit diff fix files.

Where can I find out about this? And how can this be done?

+5
source share
4 answers

Another option (assuming it works on your platform) is version 2.0 of TortoiseHG. An inappropriate utility called Shelve allows you to move chunks and files between patches or to the working directory. It is available for Windows, Linux, and possibly for OSX.

http://tortoisehg.bitbucket.io/

+3
source

SO, " MQ.

+2

, .hgrc :

[extensions]
hgext.record =

hg qrefresh nothing

( , "nothing" - : qrefresh - , , , , do - "0" )

hg qrecord <patchName> , . qnew qrecord. , , qpop, qfold .hg/patches/series, .

+2

viq="vim $(hg root)/.hg/patches/", !

viq, , diff , .

I prefer this over interactive methods (for example git add -i), because I don’t feel as safe working with an interactive prompt as I work from my editor (I know that my editor makes backups, has trivial undo, etc. .. ..).

0
source

All Articles