简体   繁体   English

防止NERD树在启动时打开缓冲区

[英]Prevent NERD Tree from opening buffer on start

I'm using Janus for Vim customizations. 我正在使用Janus进行Vim自定义。

One thing that bothers me is that it opens NERD Tree in a separate buffer on start. 困扰我的一件事是它在启动时在一个单独的缓冲区中打开NERD Tree I don't want to disable NERD Tree completely. 我不想完全禁用NERD树。 Just want to not get it opened on start. 只是想在开始时不打开它。

Is there a way without tweaking the internals of Janus? 有没有办法没有调整 Janus 的内部

Finally figured it out based on the Janus configuration mentioned by @romanl. 最后根据@romanl提到的Janus配置计算出来。

I had to add to ~/.vimrc.after 我不得不添加到~/.vimrc.after

augroup AuNERDTreeCmd
  autocmd!
augroup end

Yet another "plugin distribution for Vim" user who chose to give complete control over his Vim configuration to someone else and has no idea how to change the default behaviour. 另一个“Vim的插件发行版”用户选择完全控制他的Vim配置给其他人,并且不知道如何更改默认行为。 Yeah, "easy" is so better than "hard". 是的,“简单”比“硬”更好。

This behaviour is probably defined in an autocmd , somewhere in your "janus" directory or whatever it uses to store its things. 此行为可能在autocmd定义,位于“janus”目录中的某个位置或用于存储其内容的任何内容。 Maybe here . 也许在这里

You should probably take this as an opportunity to rethink your choice, drop Janus entirely and adopt a saner configuration strategy. 您应该以此为契机重新考虑您的选择,完全放弃Janus并采用更合理的配置策略。

If you are the one adding/removing stuff to your ~/.vimrc and installing plugins, you simply can't find yourself in such a situation. 如果您是添加/删除~/.vimrc并安装插件的人,那么您根本无法找到自己处于这种情况。

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

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