简体   繁体   English

如何在 git 交互式暂存(添加)命令中导航回一级

[英]How can navigate one level back at the git interactive staging (add) command

After running the interactive staging git command $ git add -i and choosing one of the options for example "update", then I don't know how to get back to the root level to choose another option.运行交互式登台 git 命令$ git add -i并选择其中一个选项(例如“更新”)后,我不知道如何返回根级别以选择另一个选项。

Is there any keyboard shortcuts or alternative methods rather that just using "ctrl + c" and then running the code $ git add -i , again?是否有任何键盘快捷键或替代方法,而不是仅使用“ctrl + c”然后再次运行代码$ git add -i

If you press ?如果按? while interactive adding you can see that help:在交互式添加时,您可以看到该帮助:

Prompt help:
1          - select a single item
3-5        - select a range of items
2-3,6-9    - select multiple ranges
foo        - select item based on unique prefix
-...       - unselect specified items
*          - choose all items
           - (empty) finish selecting

So basically just press enter, it should return to main selection所以基本上只需按回车,它应该返回主选择

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

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