On Thu, Aug 27, 2009 at 03:38:37PM -0600, Byron Clark wrote:
>
> So, even simpler and more secure is a snippet like this in your .vimrc:
>
> if has("autocmd")
> " gpg encrypted files
> if exists("$KEY")
> autocmd BufNewFile,BufReadPre *.gpg :set secure viminfo= noswapfile
> nobackup nowritebackup \history=0 binary
> autocmd BufReadPost *.gpg :%!gpg -d 2>/dev/null
> autocmd BufWritePre *.gpg :%!gpg -e -r $KEY 2>/dev/null
> autocmd BufWritePost *.gpg u
> endif
> endif
I assume you need to set $KEY somewhere, right? Is that just a path to
a key file?
--
Andrew McNabb
http://www.mcnabbs.org/andrew/
PGP Fingerprint: 8A17 B57C 6879 1863 DE55 8012 AB4D 6098 8826 6868
/*
PLUG: http://plug.org, #utah on irc.freenode.net
Unsubscribe: http://plug.org/mailman/options/plug
Don't fear the penguin.
*/