Monday, August 1, 2011

Re: Detecting Encrypted File

Reply to message «Re: Detecting Encrypted File»,
sent 13:35:05 01 August 2011, Monday
by Paul:

> I agree, it should work... but neither of these do:
>
> au! BufReadPost * if !empty(&key) | set viminfo= | endif
> au! BufRead * if !empty(&key) | set viminfo= | endif
BufRead and BufReadPost are the same events.

Original message:
> On Mon, Aug 01, 2011 at 09:40:27AM +1000, Ben Schmidt wrote:
> > BufReadPost should also work, and won't trigger every time you move the
> > cursor into the encrypted file's window/buffer.
>
> I agree, it should work... but neither of these do:
>
> au! BufReadPost * if !empty(&key) | set viminfo= | endif
> au! BufRead * if !empty(&key) | set viminfo= | endif
>
> Maybe there's something special about the file being encrypted that makes
> these not work - a bug, maybe?

No comments:

Post a Comment