简体   繁体   English

我该怎么办“hg shelf apply”?

[英]How can I do “hg shelf apply”?

I would like to copy some changes from my Mercurial shelf to my working directory, leaving an unchanged copy in the shelf. 我想将一些更改从我的Mercurial书架复制到我的工作目录,在书架中保留一份未更改的副本。

Git would let me do that with git stash apply , however I can't see a way to get TortoiseHg to let me do the same. Git会让我用git stash apply来做到这一点,但是我无法看到让TortoiseHg让我这样做的方法。

Is there any way to retrieve to copy the changes from the shelf, rather than move them? 有没有办法检索从架子上复制更改,而不是移动它们?

  1. Shelve extension stores shelves in .hg/shelves . 搁板扩展商店货架.hg/shelves If you stored named shelf, you can copy file, named as shelf, before hg unshelve NAME 如果存储了命名工具架,则可以在hg unshelve NAME之前复制名为shelf的文件
  2. unshelve command has option --keep (see hg help shelve ) unshelve命令有选项--keep (参见hg help shelve --keep

hg help unshelve

says that: 说:

hg unshelve --keep     keeps shelve after unshelving

So I assume this is what you are looking for. 所以我认为这就是你要找的东西。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM