vim-utils/vim-man

Buftype is somehow always set nofile

halostatue opened this issue · 7 comments

I’m not exactly sure how this is happening in my vim configuration (https://github.com/halostatue/vim-config), but ftplugin/man.vim:26 is always being set for all file types somehow when I’m editing a single file. I’ll debug a bit further when I have time, but I’m not sure why this is happening and it’s causing problems for editing and committing. This is as of master at 60aac27.

Hmm.. this is interesting. What are the steps to reproduce?

I suppose you tried the standard procedure of removing this plugin and then the problem does not appear anymore?

I haven’t had time to try to reproduce or trace this down any further quite yet, but removing the plugin causes the problem to disappear. That’s what I’ve done for now.

qazo commented

am also facing the same issue.
Could it be, that you used vim's version of ftplugin/man.vim, and removed the if &filetype == "man" line in the beginning? Cause it seems that your version sets the buftype to nofile no matter what type of file I try to save.

Hope I'm making sense here.

Hey guys,
I was able to reproduce this issue. Here's how you do it:

  • install this plugin
  • add runtime! ftplugin/man.vim to your .vimrc (this loads man.vim that comes with vim by default)
  • now when I open any file I can't write it and buftype is set to nofile

The problem is: both man.vim and this plugin are loaded.

Solution: remove runtime! ftplugin/man.vim from your vimrc.

Hey,
this issue is now documented in the readme 308bece

qazo commented

Ah, thank you.

Nudin commented

What to do it I don't have the line runtime! ftplugin/man.vim in my vimrc but get this bug?