Re: [PATCH v2 1/2] Add project-wide .vimrc configuration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jeff King wrote:

> Ideally we'd combine the autoloader for BufRead and FileType, but it
> seems non-trivial to do so. I think:
> 
>   au BufNewFile,BufRead /path/to/git/* if &filetype == "c" | setl ... | endif
> 
> works, though it's a little clunky, as each line would need to repeat
> it.

Yeah, that works, *temporarily*. If the user has configured
~/.vim/after/ftplugin/c.vim, that would override those autocommand
settings when the file is reloaded. Which is precisely why the above is
not recommended.

> I don't think we need to solve "here's how to trigger some settings
> for some directories" for everyone. We should let them integrate the
> settings as they see fit.

Yeah. But how?

I already explored this at dept, and I arrived at only one sensible
option.

-- 
Felipe Contreras



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux