gpt4 book ai didi

vim - 如何在 Vim 的浏览旧文件中显示固定数量的条目

转载 作者:行者123 更新时间:2023-12-04 02:17:16 24 4
gpt4 key购买 nike

我是 Vim 新手。我发现浏览显示多个条目的旧文件(70 个最近打开的文件)。有什么方法可以控制我想在“浏览旧文件”列表中看到的文件数量。

我确实查了Vim的帮助,没有提到如何控制条目数?

:ol[dfiles]     List the files that have marks stored in the viminfo
file. This list is read on startup and only changes
afterwards with ":rviminfo!". Also see |v:oldfiles|.
The number can be used with |c_#<|.
{not in Vi, only when compiled with the |+eval|
feature}

:bro[wse] ol[dfiles][!]
List file names as with |:oldfiles|, and then prompt
for a number. When the number is valid that file from
the list is edited.
If you get the |press-enter| prompt you can press "q"
and still get the prompt to enter a file number.
Use ! to abandon a modified buffer. |abandon|
{not when compiled with tiny or small features}

最佳答案

通过设置 viminfo。因此,例如,要设置以前编辑过的文件的最大数量,比如 70

set viminfo='70

更多信息 :h 'viminfo' .

关于vim - 如何在 Vim 的浏览旧文件中显示固定数量的条目,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/33159618/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com