On Wednesday 17 December 2008 10:34 am, sc wrote:
> 
> charles--
> 
> again i find myself struggling to maintain my own
> formatoptions settings through uses of netrw
> 
> netrw version:  v134
> 
> formatoptions before using netrw:  tcq
> formatoptions after using netrw:  nroql2
> 
> method of netrw invocation:
> 
> nmap <F11> :call MyExplore()<CR>
> 
> function! MyExplore()
>     let save_locate = @/
>     let @/ = '^' . escape(expand("%:t"), ' .\')
>     let g:netrw_sort_by = "name"
>     let g:netrw_sort_direction = "normal"
>     Explore %:p:h
>     normal gg
>     silent normal n
>     normal zz
>     let @/ = save_locate
> endfunction
> 
> this time i was using vim (not gvim) version 7.2.69 on suse
> linux 10.2
> 
> have you re-introduced old bugs, or have i found a new way
> to trick it?  or....
> 
> sc

i'd like to add a usage note so you can reproduce this:  i
used 'vime' to start my session, which is a simple script
that starts vim in netrw:

#!/bin/bash
vim -c "Explore ."

buffers i opened from that netrw had my original
formatoptions settings, even as i went back to netrw adding
more buffers, but after i quit a buffer using

nmap <silent> <F3> :silent bdelete<CR>

the buffer i landed in showed, by virtue of

nmap <S-F4> :verbose set fo?<CR>

(a mapping i was cautious enough not to get rid of) 

  formatoptions=nroql2
        Last set from /usr/local/share/vim/vim72/autoload/netrw.vim

i can't imagine how or why netrw is tampering with my
formatoptions when i am 'bdelete'ing a buffer, but it
appears that's what's happening

sc


  formatoptions=nroql2
        Last set from /usr/local/share/vim/vim72/autoload/netrw.vim

  formatoptions=nroql2
        Last set from /usr/local/share/vim/vim72/autoload/netrw.vim


--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_dev" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Raspunde prin e-mail lui