How to scroll up to view the output of system command in Vim

匆匆过客 提交于 2019-12-02 06:47:36

问题


I really like run some system command in vim like

:!rspec

but the annoying thing is I can't scroll up to see the output information

I'm using Macvim in Mac 10.9, anyone know how to do this?


回答1:


As far as I know, you can't scroll up in output that comes from an external source.

Messages do have a simple scrolling facility but only for the messages over which Vim has full control. See :h messages.

Looking at your screenshot though, I can tell you that you're doing it wrong. Running RSpec through :!rspec is inefficient. Vim has an RSpec compiler in its runtime.

:compiler rspec
:make

Now RSpec output is parsed and filled into your quickfix list for easy navigation.

For even more RSpec power such as asynchronous test runs check out dispatch.vim.



来源:https://stackoverflow.com/questions/18130722/how-to-scroll-up-to-view-the-output-of-system-command-in-vim

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!