Tuesday, December 27, 2011

Re: Binary editing

On Dec 22, 10:35 am, Charles Campbell <Charles.E.Campb...@nasa.gov>
wrote:
>
> If it is of interest, then (going further out on a limb), perhaps
>
> " Augroup Binary: vim -b : edit binary using xxd-format! {{{2
> augroup Binary
>    au!
>    au BufReadPre   *.bin let &bin=1
>    au BufReadPost  *.bin if &bin   |%!xxd
>    au BufReadPost  *.bin set ft=xxd|endif
>    au BufWritePre  *.bin if &bin   |%!xxd -r
>    au BufWritePre  *.bin endif
>    au BufWritePost *.bin if &bin   |%!xxd
>    au BufWritePost *.bin set nomod |endif
> augroup END
>
> in your .vimrc will further assist you.  You'll probably be wanting to
> extend *.bin to additional suffices, though.  For example, if you're
> using Windows, change  *.bin  to *.exe .  If you're using linux its a
> bit more involved, as executables under linux seldom have suffices.
>

I like this better:

http://vim.wikia.com/wiki/Improved_hex_editing

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: