r1169 - in /trunk/packages/vim: debian/changelog patches/netrwPlugin.vim-bwipe.diff

jamessan at users.alioth.debian.org jamessan at users.alioth.debian.org
Wed Jan 23 20:06:59 UTC 2008


Author: jamessan
Date: Wed Jan 23 20:06:59 2008
New Revision: 1169

URL: http://svn.debian.org/wsvn/pkg-vim/?sc=1&rev=1169
Log:
* Updated patches:
  - netrwPlugin.vim-bwipe.diff:
    + Do a full refresh of NetRW since the functionality is spread out among
      multiple files.

Modified:
    trunk/packages/vim/debian/changelog
    trunk/packages/vim/patches/netrwPlugin.vim-bwipe.diff

Modified: trunk/packages/vim/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-vim/trunk/packages/vim/debian/changelog?rev=1169&op=diff
==============================================================================
--- trunk/packages/vim/debian/changelog (original)
+++ trunk/packages/vim/debian/changelog Wed Jan 23 20:06:59 2008
@@ -6,8 +6,12 @@
   * debian/control:
     - Re-add ruby1.8 Build-Depends since that's required for Vim to detect
       that it can build with Ruby support.  (Closes: #462284)
-
- -- James Vega <jamessan at debian.org>  Wed, 23 Jan 2008 14:54:06 -0500
+  * Updated patches:
+    - netrwPlugin.vim-bwipe.diff:
+      + Do a full refresh of NetRW since the functionality is spread out among
+        multiple files.
+
+ -- James Vega <jamessan at debian.org>  Wed, 23 Jan 2008 15:05:09 -0500
 
 vim (1:7.1-231+1) unstable; urgency=low
 

Modified: trunk/packages/vim/patches/netrwPlugin.vim-bwipe.diff
URL: http://svn.debian.org/wsvn/pkg-vim/trunk/packages/vim/patches/netrwPlugin.vim-bwipe.diff?rev=1169&op=diff
==============================================================================
--- trunk/packages/vim/patches/netrwPlugin.vim-bwipe.diff (original)
+++ trunk/packages/vim/patches/netrwPlugin.vim-bwipe.diff Wed Jan 23 20:06:59 2008
@@ -15,7 +15,7 @@
   finish
  endif
 -let g:loaded_netrwPlugin = 1
-+let g:loaded_netrwPlugin = "v118b"
++let g:loaded_netrwPlugin = "v119"
  let s:keepcpo            = &cpo
  if v:version < 700
   echohl WarningMsg | echo "***netrw*** you need vim version 7.0 for this version of netrw" | echohl None
@@ -58,3 +58,8826 @@
  
  " Maps:
  if !exists("g:netrw_nogx") && maparg('g','n') == ""
+Index: vim/runtime/autoload/netrw.vim
+===================================================================
+--- vim/runtime/autoload/netrw.vim.orig
++++ vim/runtime/autoload/netrw.vim
+@@ -1,7 +1,7 @@
+ " netrw.vim: Handles file transfer and remote directory listing across
+ "            AUTOLOAD SECTION
+-" Date:		May 05, 2007
+-" Version:	109
++" Date:		Jan 15, 2008
++" Version:	119
+ " Maintainer:	Charles E Campbell, Jr <NdrOchip at ScampbellPfamily.AbizM-NOSPAM>
+ " GetLatestVimScripts: 1075 1 :AutoInstall: netrw.vim
+ " Copyright:    Copyright (C) 1999-2007 Charles E. Campbell, Jr. {{{1
+@@ -14,8 +14,7 @@
+ "               in no event will the copyright holder be liable for any damages
+ "               resulting from the use of this software.
+ "               of this software.
+-" COMBAK: worked with tmpfile s:GetTempname() in NetRead() NetWrite()
+-"         !!NEEDS DEBUGGING && TESTING!!!
++" note: worked with tmpfile s:GetTempname() in NetRead() NetWrite()
+ "redraw!|call inputsave()|call input("Press <cr> to continue")|call inputrestore()
+ "
+ "  But be doers of the Word, and not only hearers, deluding your own selves {{{1
+@@ -30,7 +29,7 @@
+  let s:WARNING = 1
+  let s:ERROR   = 2
+ endif
+-let g:loaded_netrw = "v109"
++let g:loaded_netrw = "v119"
+ if v:version < 700
+  call netrw#ErrorMsg(s:WARNING,"you need vim version 7.0 or later for version ".g:loaded_netrw." of netrw",1)
+  finish
+@@ -115,6 +114,18 @@
+ 
+ " ---------------------------------------------------------------------
+ " Default values for netrw's global variables {{{2
++" Cygwin Detection ------- {{{3
++if !exists("g:netrw_cygwin")
++ if has("win32") || has("win95") || has("win64") || has("win16")
++  if &shell =~ '\%(\<bash\>\|\<zsh\>\)\%(\.exe\)\=$'
++   let g:netrw_cygwin= 1
++  else
++   let g:netrw_cygwin= 0
++  endif
++ else
++  let g:netrw_cygwin= 0
++ endif
++endif
+ " Default values - a-c ---------- {{{3
+ if !exists("g:netrw_alto")
+  let g:netrw_alto= &sb
+@@ -128,23 +139,16 @@
+ if !exists("g:netrw_chgwin")
+  let g:netrw_chgwin    = -1
+ endif
+-if !exists("g:netrw_cygwin")
+- if has("win32") || has("win95") || has("win64") || has("win16")
+-  if &shell =~ '\%(\<bash\>\|\<zsh\>\)\%(\.exe\)\=$'
+-   let g:netrw_cygwin= 1
+-  else
+-   let g:netrw_cygwin= 0
+-  endif
+- else
+-  let g:netrw_cygwin= 0
+- endif
+-else
+- let g:netrw_cygwin= 0
++if !exists("g:netrw_compress")
++ let g:netrw_compress= "gzip"
+ endif
+ " Default values - d-f ---------- {{{3
+ if !exists("g:NETRW_DIRHIST_CNT")
+  let g:NETRW_DIRHIST_CNT= 0
+ endif
++if !exists("g:netrw_decompress")
++ let g:netrw_decompress= { ".gz" : "gunzip" , ".bz2" : "bunzip2" , ".zip" : "unzip" , ".tar" : "tar -xf"}
++endif
+ if !exists("g:netrw_dirhistmax")
+  let g:netrw_dirhistmax= 10
+ endif
+@@ -198,9 +202,35 @@
+  let g:netrw_list_hide= ""
+ endif
+ " Default values - lh-lz ---------- {{{3
++if !exists("g:netrw_localcopycmd")
++ if has("win32") || has("win95") || has("win64") || has("win16")
++  if g:netrw_cygwin
++   let g:netrw_localcopycmd= "cp"
++  else
++   let g:netrw_localcopycmd= "copy"
++  endif
++ elseif has("unix") || has("macunix")
++  let g:netrw_localcopycmd= "cp"
++ else
++  let g:netrw_localcopycmd= ""
++ endif
++endif
+ if !exists("g:netrw_local_mkdir")
+  let g:netrw_local_mkdir= "mkdir"
+ endif
++if !exists("g:netrw_localmovecmd")
++ if has("win32") || has("win95") || has("win64") || has("win16")
++  if g:netrw_cygwin
++   let g:netrw_localmovecmd= "mv"
++  else
++   let g:netrw_localmovecmd= "move"
++  endif
++ elseif has("unix") || has("macunix")
++  let g:netrw_localmovecmd= "mv"
++ else
++  let g:netrw_localmovecmd= ""
++ endif
++endif
+ if !exists("g:netrw_local_rmdir")
+  let g:netrw_local_rmdir= "rmdir"
+ endif
+@@ -224,6 +254,19 @@
+ if !exists("g:netrw_mkdir_cmd")
+  let g:netrw_mkdir_cmd= g:netrw_ssh_cmd." USEPORT HOSTNAME mkdir"
+ endif
++if !exists("g:netrw_mousemaps")
++ if exists("&mouse") && &mouse =~ '[anh]'
++  let g:netrw_mousemaps= 1
++ else
++  let g:netrw_mousemaps= 0
++ endif
++endif
++if !exists("g:netrw_retmap")
++ let g:netrw_retmap= 0
++endif
++if !exists("g:netrw_preview")
++ let g:netrw_preview= 0
++endif
+ if !exists("g:netrw_scpport")
+  let g:netrw_scpport= "-P"
+ endif
+@@ -254,6 +297,8 @@
+ if !exists("g:netrw_shq")
+  if exists("&shq") && &shq != ""
+   let g:netrw_shq= &shq
++ elseif exists("&sxq") && &sxq != ""
++  let g:netrw_shq= &sxq
+  elseif has("win32") || has("win95") || has("win64") || has("win16")
+   if g:netrw_cygwin
+    let g:netrw_shq= "'"
+@@ -287,6 +332,9 @@
+   let g:netrw_use_noswf= 0
+ endif
+ " Default values - t-w ---------- {{{3
++if !exists("g:netrw_ctags")
++ let g:netrw_ctags= "ctags"
++endif
+ if !exists("g:netrw_timefmt")
+  let g:netrw_timefmt= "%c"
+ endif
+@@ -304,8 +352,8 @@
+ endif
+ " ---------------------------------------------------------------------
+ " Default values for netrw's script variables: {{{2
+-if !exists("s:netrw_cd_escape")
+-  let s:netrw_cd_escape="[]#*$%'\" ?`!&();<>\\"
++if !exists("g:netrw_cd_escape")
++  let g:netrw_cd_escape="[]#*$%'\" ?`!&();<>\\"
+ endif
+ if !exists("g:netrw_fname_escape")
+  let g:netrw_fname_escape= ' ?&;'
+@@ -327,9 +375,9 @@
+ " ==============================
+ 
+ " ------------------------------------------------------------------------
+-" NetSavePosn: saves position of cursor on screen {{{2
+-fun! netrw#NetSavePosn()
+-"  call Dfunc("netrw#NetSavePosn()")
++" netrw#NetrwSavePosn: saves position of cursor on screen {{{2
++fun! netrw#NetrwSavePosn()
++"  call Dfunc("netrw#NetrwSavePosn()")
+   " Save current line and column
+   let w:netrw_winnr= winnr()
+   let w:netrw_line = line(".")
+@@ -339,20 +387,28 @@
+   norm! H0
+   let w:netrw_hline= line(".")
+ 
+-  call netrw#NetRestorePosn()
+-"  call Dret("netrw#NetSavePosn : winnr=".w:netrw_winnr." line=".w:netrw_line." col=".w:netrw_col." hline=".w:netrw_hline)
++  " set up string holding position parameters
++  let ret          = "let w:netrw_winnr=".w:netrw_winnr."|let w:netrw_line=".w:netrw_line."|let w:netrw_col=".w:netrw_col."|let w:netrw_hline=".w:netrw_hline
++
++  call netrw#NetrwRestorePosn()
++"  call Dret("netrw#NetrwSavePosn : winnr=".w:netrw_winnr." line=".w:netrw_line." col=".w:netrw_col." hline=".w:netrw_hline)
++  return ret
+ endfun
+ 
+ " ------------------------------------------------------------------------
+-" NetRestorePosn: restores the cursor and file position as saved by NetSavePosn() {{{2
+-fun! netrw#NetRestorePosn()
+-"  call Dfunc("netrw#NetRestorePosn() winnr=".(exists("w:netrw_winnr")? w:netrw_winnr : -1)." line=".(exists("w:netrw_line")? w:netrw_line : -1)." col=".(exists("w:netrw_col")? w:netrw_col : -1)." hline=".(exists("w:netrw_hline")? w:netrw_hline : -1))
++" netrw#NetrwRestorePosn: restores the cursor and file position as saved by NetrwSavePosn() {{{2
++fun! netrw#NetrwRestorePosn(...)
++"  call Dfunc("netrw#NetrwRestorePosn() a:0=".a:0." winnr=".(exists("w:netrw_winnr")? w:netrw_winnr : -1)." line=".(exists("w:netrw_line")? w:netrw_line : -1)." col=".(exists("w:netrw_col")? w:netrw_col : -1)." hline=".(exists("w:netrw_hline")? w:netrw_hline : -1))
+   let eikeep= &ei
+   set ei=all
+   if expand("%") == "NetrwMessage"
+    exe s:winBeforeErr."wincmd w"
+   endif
+ 
++  if a:0 > 0
++   exe a:1
++  endif
++
+   " restore window
+   if exists("w:netrw_winnr")
+ "   call Decho("restore window: exe silent! ".w:netrw_winnr."wincmd w")
+@@ -377,134 +433,198 @@
+   endif
+ 
+   let &ei= eikeep
+-"  call Dret("netrw#NetRestorePosn")
++"  call Dret("netrw#NetrwRestorePosn")
+ endfun
+ 
+-" ===============================
+-" NetOptionSave: save options and set to "standard" form {{{2
+-"DechoTabOn
+-fun! s:NetOptionSave()
+-"  call Dfunc("s:NetOptionSave() win#".winnr()." buf#".bufnr("."))
+-  if !exists("w:netrw_optionsave")
+-   let w:netrw_optionsave= 1
++" ---------------------------------------------------------------------
++" s:NetrwOptionSave: save options and set to "standard" form {{{2
++"  06/08/07 : removed call to NetrwSafeOptions(), either placed
++"             immediately after NetrwOptionSave() calls in NetRead
++"             and NetWrite, or after the s:NetrwEnew() call in
++"             NetrwBrowse.
++"             vt: normally its "w:" or "s:" (a variable type)
++fun! s:NetrwOptionSave(vt)
++"  call Dfunc("s:NetrwOptionSave(vt<".a:vt.">) win#".winnr()." buf#".bufnr(".")."<".bufname(bufnr(".")).">")
++
++"  call Decho(a:vt."netrw_optionsave".(exists("{a:vt}netrw_optionsave")? ("=".{a:vt}netrw_optionsave) : " doesn't exist"))
++  if !exists("{a:vt}netrw_optionsave")
++   let {a:vt}netrw_optionsave= 1
+   else
+-"   call Dret("s:NetOptionSave : netoptionsave=".w:netrw_optionsave)
++"   call Dret("s:NetrwOptionSave : options already saved")
+    return
+   endif
++"  call Decho("fo=".&fo.(exists("&acd")? " acd=".&acd : " acd doesn't exist"))
+ 
+   " Save current settings and current directory
+   let s:yykeep          = @@
+   if exists("&l:acd")
+-   let w:netrw_acdkeep  = &l:acd
++   let {a:vt}netrw_acdkeep  = &l:acd
+   endif
+-  let w:netrw_aikeep    = &l:ai
+-  let w:netrw_awkeep    = &l:aw
+-  let w:netrw_cikeep    = &l:ci
+-  let w:netrw_cinkeep   = &l:cin
+-  let w:netrw_cinokeep  = &l:cino
+-  let w:netrw_comkeep   = &l:com
+-  let w:netrw_cpokeep   = &l:cpo
++  let {a:vt}netrw_aikeep    = &l:ai
++  let {a:vt}netrw_awkeep    = &l:aw
++  let {a:vt}netrw_cikeep    = &l:ci
++  let {a:vt}netrw_cinkeep   = &l:cin
++  let {a:vt}netrw_cinokeep  = &l:cino
++  let {a:vt}netrw_comkeep   = &l:com
++  let {a:vt}netrw_cpokeep   = &l:cpo
+   if g:netrw_keepdir
+-   let w:netrw_dirkeep  = getcwd()
++   let {a:vt}netrw_dirkeep  = getcwd()
+   endif
+-  let w:netrw_fokeep    = &l:fo           " formatoptions
+-  let w:netrw_gdkeep    = &l:gd           " gdefault
+-  let w:netrw_hidkeep   = &l:hidden
+-  let w:netrw_magickeep = &l:magic
+-  let w:netrw_repkeep   = &l:report
+-  let w:netrw_spellkeep = &l:spell
+-  let w:netrw_twkeep    = &l:tw           " textwidth
+-  let w:netrw_wigkeep   = &l:wig          " wildignore
++  let {a:vt}netrw_fokeep    = &l:fo           " formatoptions
++  let {a:vt}netrw_gdkeep    = &l:gd           " gdefault
++  let {a:vt}netrw_hidkeep   = &l:hidden
++  let {a:vt}netrw_magickeep = &l:magic
++  let {a:vt}netrw_repkeep   = &l:report
++  let {a:vt}netrw_spellkeep = &l:spell
++  let {a:vt}netrw_twkeep    = &l:tw           " textwidth
++  let {a:vt}netrw_wigkeep   = &l:wig          " wildignore
+   if has("win32") && !has("win95")
+-   let w:netrw_swfkeep= &l:swf            " swapfile
++   let {a:vt}netrw_swfkeep= &l:swf            " swapfile
+   endif
+-  call s:NetrwSafeOptions()
+-  if &go =~ 'a' | silent! let w:netrw_regstar = @* | endif
+-  silent! let w:netrw_regslash= @/
++  if &go =~ 'a' | silent! let {a:vt}netrw_regstar = @* | endif
++  silent! let {a:vt}netrw_regslash= @/
+ 
+-"  call Dret("s:NetOptionSave")
+-"  call Dret("s:NetOptionSave : win#".winnr()." buf#".bufnr("."))
++"  call Dret("s:NetrwOptionSave : win#".winnr()." buf#".bufnr("."))
+ endfun
+ 
+ " ------------------------------------------------------------------------
+-" NetOptionRestore: restore options {{{2
+-fun! s:NetOptionRestore()
+-"  call Dfunc("s:NetOptionRestore() win#".winnr()." buf#".bufnr("."))
+-  if !exists("w:netrw_optionsave")
+-"   call Dret("s:NetOptionRestore : w:netrw_optionsave doesn't exist")
++" s:NetrwOptionRestore: restore options {{{2
++fun! s:NetrwOptionRestore(vt)
++"  call Dfunc("s:NetrwOptionRestore(vt<".a:vt.">) win#".winnr()." buf#".bufnr("."))
++  if !exists("{a:vt}netrw_optionsave")
++"   call Dret("s:NetrwOptionRestore : ".a:vt."netrw_optionsave doesn't exist")
+    return
+   endif
+-  unlet w:netrw_optionsave
++  unlet {a:vt}netrw_optionsave
+ 
+   if exists("&acd")
+-   if exists("w:netrw_acdkeep") |let &l:acd    = w:netrw_acdkeep     |unlet w:netrw_acdkeep  |endif
++   if exists("{a:vt}netrw_acdkeep")
++"    call Decho("g:netrw_keepdir=".g:netrw_keepdir.": getcwd<".getcwd()."> acd=".&acd)
++    let curdir = getcwd()
++    let &l:acd = {a:vt}netrw_acdkeep
++    unlet {a:vt}netrw_acdkeep
++    if &l:acd
++"     call Decho("exe cd ".escape(curdir,g:netrw_fname_escape))
++     exe "cd ".escape(curdir,g:netrw_fname_escape)
++    endif
++   endif
+   endif
+-  if exists("w:netrw_aikeep")   |let &l:ai     = w:netrw_aikeep      |unlet w:netrw_aikeep   |endif
+-  if exists("w:netrw_awkeep")   |let &l:aw     = w:netrw_awkeep      |unlet w:netrw_awkeep   |endif
+-  if exists("w:netrw_cikeep")   |let &l:ci     = w:netrw_cikeep      |unlet w:netrw_cikeep   |endif
+-  if exists("w:netrw_cinkeep")  |let &l:cin    = w:netrw_cinkeep     |unlet w:netrw_cinkeep  |endif
+-  if exists("w:netrw_cinokeep") |let &l:cino   = w:netrw_cinokeep    |unlet w:netrw_cinokeep |endif
+-  if exists("w:netrw_comkeep")  |let &l:com    = w:netrw_comkeep     |unlet w:netrw_comkeep  |endif
+-  if exists("w:netrw_cpokeep")  |let &l:cpo    = w:netrw_cpokeep     |unlet w:netrw_cpokeep  |endif
+-  if exists("w:netrw_dirkeep")  |exe "lcd ".w:netrw_dirkeep          |unlet w:netrw_dirkeep  |endif
+-  if exists("w:netrw_fokeep")   |let &l:fo     = w:netrw_fokeep      |unlet w:netrw_fokeep   |endif
+-  if exists("w:netrw_gdkeep")   |let &l:gd     = w:netrw_gdkeep      |unlet w:netrw_gdkeep   |endif
+-  if exists("w:netrw_hidkeep")  |let &l:hidden = w:netrw_hidkeep     |unlet w:netrw_hidkeep  |endif
+-  if exists("w:netrw_magic")    |let &l:magic  = w:netrw_magic       |unlet w:netrw_magic    |endif
+-  if exists("w:netrw_repkeep")  |let &l:report = w:netrw_repkeep     |unlet w:netrw_repkeep  |endif
+-  if exists("w:netrw_spellkeep")|let &l:spell  = w:netrw_spellkeep   |unlet w:netrw_spellkeep|endif
+-  if exists("w:netrw_twkeep")   |let &l:tw     = w:netrw_twkeep      |unlet w:netrw_twkeep   |endif
+-  if exists("w:netrw_wigkeep")  |let &l:wig    = w:netrw_wigkeep     |unlet w:netrw_wigkeep  |endif
+-  if exists("s:yykeep")         |let  @@       = s:yykeep            |unlet s:yykeep         |endif
+-  if exists("w:netrw_swfkeep")
++  if exists("{a:vt}netrw_aikeep")   |let &l:ai     = {a:vt}netrw_aikeep      |unlet {a:vt}netrw_aikeep   |endif
++  if exists("{a:vt}netrw_awkeep")   |let &l:aw     = {a:vt}netrw_awkeep      |unlet {a:vt}netrw_awkeep   |endif
++  if exists("{a:vt}netrw_cikeep")   |let &l:ci     = {a:vt}netrw_cikeep      |unlet {a:vt}netrw_cikeep   |endif
++  if exists("{a:vt}netrw_cinkeep")  |let &l:cin    = {a:vt}netrw_cinkeep     |unlet {a:vt}netrw_cinkeep  |endif
++  if exists("{a:vt}netrw_cinokeep") |let &l:cino   = {a:vt}netrw_cinokeep    |unlet {a:vt}netrw_cinokeep |endif
++  if exists("{a:vt}netrw_comkeep")  |let &l:com    = {a:vt}netrw_comkeep     |unlet {a:vt}netrw_comkeep  |endif
++  if exists("{a:vt}netrw_cpokeep")  |let &l:cpo    = {a:vt}netrw_cpokeep     |unlet {a:vt}netrw_cpokeep  |endif
++  if exists("{a:vt}netrw_dirkeep") && isdirectory({a:vt}netrw_dirkeep) && g:netrw_keepdir
++   let dirkeep = substitute({a:vt}netrw_dirkeep,'\\','/','g')
++   let dirkeep = escape(dirkeep,g:netrw_cd_escape)
++   if exists("{a:vt}netrw_dirkeep")  |exe "lcd ".dirkeep|unlet {a:vt}netrw_dirkeep  |endif
++  endif
++  if exists("{a:vt}netrw_fokeep")   |let &l:fo     = {a:vt}netrw_fokeep      |unlet {a:vt}netrw_fokeep   |endif
++  if exists("{a:vt}netrw_gdkeep")   |let &l:gd     = {a:vt}netrw_gdkeep      |unlet {a:vt}netrw_gdkeep   |endif
++  if exists("{a:vt}netrw_hidkeep")  |let &l:hidden = {a:vt}netrw_hidkeep     |unlet {a:vt}netrw_hidkeep  |endif
++  if exists("{a:vt}netrw_magic")    |let &l:magic  = {a:vt}netrw_magic       |unlet {a:vt}netrw_magic    |endif
++  if exists("{a:vt}netrw_repkeep")  |let &l:report = {a:vt}netrw_repkeep     |unlet {a:vt}netrw_repkeep  |endif
++  if exists("{a:vt}netrw_spellkeep")|let &l:spell  = {a:vt}netrw_spellkeep   |unlet {a:vt}netrw_spellkeep|endif
++  if exists("{a:vt}netrw_twkeep")   |let &l:tw     = {a:vt}netrw_twkeep      |unlet {a:vt}netrw_twkeep   |endif
++  if exists("{a:vt}netrw_wigkeep")  |let &l:wig    = {a:vt}netrw_wigkeep     |unlet {a:vt}netrw_wigkeep  |endif
++  if exists("s:yykeep")             |let  @@       = s:yykeep                |unlet s:yykeep             |endif
++  if exists("{a:vt}netrw_swfkeep")
+    if &directory == ""
+     " user hasn't specified a swapfile directory;
+     " netrw will temporarily set the swapfile directory
+     " to the current directory as returned by getcwd().
+     let &l:directory   = getcwd()
+-    silent! let &l:swf = w:netrw_swfkeep
++    silent! let &l:swf = {a:vt}netrw_swfkeep
+     setlocal directory=
+-    unlet w:netrw_swfkeep
+-   elseif &l:swf != w:netrw_swfkeep
+-    " following line causes a Press ENTER in windows -- can't seem to work around it!!! (COMBAK)
+-    silent! let &l:swf= w:netrw_swfkeep
+-    unlet w:netrw_swfkeep
++    unlet {a:vt}netrw_swfkeep
++   elseif &l:swf != {a:vt}netrw_swfkeep
++    " following line causes a Press ENTER in windows -- can't seem to work around it!!!
++    silent! let &l:swf= {a:vt}netrw_swfkeep
++    unlet {a:vt}netrw_swfkeep
+    endif
+   endif
+-  if exists("w:netrw_regstar") |silent! let @*= w:netrw_regstar |unlet w:netrw_regstar |endif
+-  if exists("w:netrw_regslash")|silent! let @/= w:netrw_regslash|unlet w:netrw_regslash|endif
++  if exists("{a:vt}netrw_regstar") |silent! let @*= {a:vt}netrw_regstar |unlet {a:vt}netrw_regstar |endif
++  if exists("{a:vt}netrw_regslash")|silent! let @/= {a:vt}netrw_regslash|unlet {a:vt}netrw_regslash|endif
++"  call Decho("g:netrw_keepdir=".g:netrw_keepdir.": getcwd<".getcwd()."> acd=".&acd)
+ 
+-"  call Dret("s:NetOptionRestore : win#".winnr()." buf#".bufnr("."))
++"  call Decho("fo=".&fo.(exists("&acd")? " acd=".&acd : " acd doesn't exist"))
++"  call Dret("s:NetrwOptionRestore : win#".winnr()." buf#".bufnr("."))
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetrwSafeOptions: sets options to help netrw do its job {{{2
++" s:NetrwSafeOptions: sets options to help netrw do its job {{{2
+ fun! s:NetrwSafeOptions()
+-"  call Dfunc("s:NetrwSafeOptions()")
++"  call Dfunc("s:NetrwSafeOptions() win#".winnr()." buf#".bufnr(".")."<".bufname(bufnr(".")).">")
++"  call Decho("window's ft=".&ft)
+   setlocal cino=
+   setlocal com=
+   setlocal cpo-=aA
+-  if exists("&acd")
+-   setlocal noacd nocin noai noci magic nospell nohid wig= noaw
+-   setlocal fo=nroql2
+-  else
+-   setlocal nocin noai noci magic nospell nohid wig= noaw
+-   setlocal fo=nroql2
+-  endif
++  if exists("&acd") | setlocal noacd | endif
++  setlocal nocin noai noci magic nospell nohid wig= noaw
++  setlocal fo=nroql2
+   setlocal tw=0
+   setlocal report=10000
+   if g:netrw_use_noswf && has("win32") && !has("win95")
+    setlocal noswf
+   endif
++"  call Decho("fo=".&fo.(exists("&acd")? " acd=".&acd : " acd doesn't exist"))
+ "  call Dret("s:NetrwSafeOptions")
+ endfun
+ 
++" ---------------------------------------------------------------------
++" netrw#NetrwClean: remove netrw {{{2
++" supports :NetrwClean  -- remove netrw from first directory on runtimepath
++"          :NetrwClean! -- remove netrw from all directories on runtimepath
++fun! netrw#NetrwClean(sys)
++"  call Dfunc("netrw#NetrwClean(sys=".a:sys.")")
++
++  if a:sys
++   let choice= confirm("Remove personal and system copies of netrw?","&Yes\n&No")
++  else
++   let choice= confirm("Remove personal copy of netrw?","&Yes\n&No")
++  endif
++"  call Decho("choice=".choice)
++  let diddel= 0
++  let diddir= ""
++
++  if choice == 1
++   for dir in split(&rtp,',')
++    if filereadable(dir."/plugin/netrwPlugin.vim")
++"     call Decho("removing netrw-related files from ".dir)
++     if s:System("delete",dir."/plugin/netrwPlugin.vim")        |call netrw#ErrorMsg(1,"unable to remove ".dir."/plugin/netrwPlugin.vim",55)        |endif
++     if s:System("delete",dir."/autoload/netrwFileHandlers.vim")|call netrw#ErrorMsg(1,"unable to remove ".dir."/autoload/netrwFileHandlers.vim",55)|endif
++     if s:System("delete",dir."/autoload/netrwSettings.vim")    |call netrw#ErrorMsg(1,"unable to remove ".dir."/autoload/netrwSettings.vim",55)    |endif
++     if s:System("delete",dir."/autoload/netrw.vim")            |call netrw#ErrorMsg(1,"unable to remove ".dir."/autoload/netrw.vim",55)            |endif
++     if s:System("delete",dir."/syntax/netrw.vim")              |call netrw#ErrorMsg(1,"unable to remove ".dir."/syntax/netrw.vim",55)              |endif
++     if s:System("delete",dir."/syntax/netrwlist.vim")          |call netrw#ErrorMsg(1,"unable to remove ".dir."/syntax/netrwlist.vim",55)          |endif
++     let diddir= dir
++     let diddel= diddel + 1
++     if !a:sys|break|endif
++    endif
++   endfor
++  endif
++
++   echohl WarningMsg
++  if diddel == 0
++   echomsg "netrw is either not installed or not removable"
++  elseif diddel == 1
++   echomsg "removed one copy of netrw from <".diddir.">"
++  else
++   echomsg "removed ".diddel." copies of netrw"
++  endif
++   echohl None
++
++"  call Dret("netrw#NetrwClean")
++endfun
++
+ " ------------------------------------------------------------------------
+ "  Netrw Transfer Functions: {{{1
+ " ===============================
+ 
+ " ------------------------------------------------------------------------
+-" NetRead: responsible for reading a file over the net {{{2
++" netrw#NetRead: responsible for reading a file over the net {{{2
+ "   mode: =0 read remote file and insert before current line
+ "         =1 read remote file and insert after current line
+ "         =2 replace with remote file
+@@ -513,7 +633,8 @@
+ "  call Dfunc("netrw#NetRead(mode=".a:mode.",...) a:0=".a:0." ".g:loaded_netrw)
+ 
+   " save options {{{3
+-  call s:NetOptionSave()
++  call s:NetrwOptionSave("w:")
++  call s:NetrwSafeOptions()
+ 
+   " interpret mode into a readcmd {{{3
+   if     a:mode == 0 " read remote file before current line
+@@ -572,10 +693,10 @@
+ "     call Decho("reconstructing choice")
+      if match(choice,'"$') != -1
+       " case "..."
+-      let choice=strpart(choice,1,strlen(choice)-2)
++      let choice=strpart(choice,1,s:Strlen(choice)-2)
+      else
+        "  case "... ... ..."
+-      let choice      = strpart(choice,1,strlen(choice)-1)
++      let choice      = strpart(choice,1,s:Strlen(choice)-1)
+       let wholechoice = ""
+ 
+       while match(choice,'"$') == -1
+@@ -590,7 +711,7 @@
+        endif
+        let choice= a:{ichoice}
+       endwhile
+-      let choice= strpart(wholechoice,1,strlen(wholechoice)-1) . " " . strpart(choice,0,strlen(choice)-1)
++      let choice= strpart(wholechoice,1,s:Strlen(wholechoice)-1) . " " . strpart(choice,0,s:Strlen(choice)-1)
+      endif
+     endif
+    endif
+@@ -599,14 +720,14 @@
+    let ichoice= ichoice + 1
+ 
+    " Determine method of read (ftp, rcp, etc) {{{3
+-   call s:NetMethod(choice)
++   call s:NetrwMethod(choice)
+    let tmpfile= s:GetTempfile(b:netrw_fname) " apply correct suffix
+ 
+-   " Check if NetBrowse() should be handling this request
+-"   call Decho("checking if NetBrowse() should handle choice<".choice."> with netrw_list_cmd<".g:netrw_list_cmd.">")
++   " Check if NetrwBrowse() should be handling this request
++"   call Decho("checking if NetrwBrowse() should handle choice<".choice."> with netrw_list_cmd<".g:netrw_list_cmd.">")
+    if choice =~ "^.*[\/]$" && b:netrw_method != 5 && choice !~ '^http://'
+ "    call Decho("yes, choice matches '^.*[\/]$'")
+-    keepjumps call s:NetBrowse(0,choice)
++    keepjumps call s:NetrwBrowse(0,choice)
+ "    call Dret("netrw#NetRead :3 getcwd<".getcwd().">")
+     return
+    endif
+@@ -642,7 +763,7 @@
+    endif
+ "   call Decho("executing: !".g:netrw_rcp_cmd." ".s:netrw_rcpmode." ".uid_machine.":".escape(b:netrw_fname,' ?&;')." ".tmpfile)
+    exe g:netrw_silentxfer."!".g:netrw_rcp_cmd." ".s:netrw_rcpmode." ".uid_machine.":".escape(b:netrw_fname,' ?&;')." ".tmpfile
+-   let result           = s:NetGetFile(readcmd, tmpfile, b:netrw_method)
++   let result           = s:NetrwGetFile(readcmd, tmpfile, b:netrw_method)
+    let b:netrw_lastfile = choice
+ 
+    ".........................................
+@@ -650,7 +771,7 @@
+    elseif b:netrw_method  == 2		" read with ftp + <.netrc>
+ "     call Decho("read via ftp+.netrc (method #2)")
+      let netrw_fname= b:netrw_fname
+-     new
++     call s:SaveBufVars()|new|call s:RestoreBufVars()
+      setlocal ff=unix
+      exe "put ='".g:netrw_ftpmode."'"
+ "     call Decho("filter input: ".getline("."))
+@@ -674,8 +795,8 @@
+       call netrw#ErrorMsg(s:ERROR,getline(1),4)
+       let &debug= debugkeep
+      endif
+-     bd!
+-     let result           = s:NetGetFile(readcmd, tmpfile, b:netrw_method)
++     call s:SaveBufVars()|bd!|call s:RestoreBufVars()
++     let result           = s:NetrwGetFile(readcmd, tmpfile, b:netrw_method)
+      let b:netrw_lastfile = choice
+ 
+    ".........................................
+@@ -684,7 +805,7 @@
+     " Construct execution string (four lines) which will be passed through filter
+ "    call Decho("read via ftp+mipf (method #3)")
+     let netrw_fname= escape(b:netrw_fname,g:netrw_fname_escape)
+-    new
++    call s:SaveBufVars()|new|call s:RestoreBufVars()
+     setlocal ff=unix
+     if exists("g:netrw_port") && g:netrw_port != ""
+      put ='open '.g:netrw_machine.' '.g:netrw_port
+@@ -697,10 +818,10 @@
+     if exists("g:netrw_ftp") && g:netrw_ftp == 1
+      put =g:netrw_uid
+ "     call Decho("filter input: ".getline("."))
+-     put ='\"'.g:netrw_passwd.'\"'
++     put ='\"'.s:netrw_passwd.'\"'
+ "     call Decho("filter input: ".getline("."))
+     else
+-     put ='user \"'.g:netrw_uid.'\" \"'.g:netrw_passwd.'\"'
++     put ='user \"'.g:netrw_uid.'\" \"'.s:netrw_passwd.'\"'
+ "     call Decho("filter input: ".getline("."))
+     endif
+ 
+@@ -729,8 +850,8 @@
+       call netrw#ErrorMsg(s:ERROR,getline(1),5)
+      endif
+     endif
+-    bd!
+-    let result           = s:NetGetFile(readcmd, tmpfile, b:netrw_method)
++    call s:SaveBufVars()|bd!|call s:RestoreBufVars()
++    let result           = s:NetrwGetFile(readcmd, tmpfile, b:netrw_method)
+     let b:netrw_lastfile = choice
+ 
+    ".........................................
+@@ -744,7 +865,7 @@
+     endif
+ "    call  Decho("executing: !".g:netrw_scp_cmd.useport." '".g:netrw_machine.":".escape(b:netrw_fname,g:netrw_fname_escape)."' ".tmpfile)
+     exe g:netrw_silentxfer."!".g:netrw_scp_cmd.useport." ".g:netrw_shq.g:netrw_machine.":".escape(b:netrw_fname,g:netrw_fname_escape).g:netrw_shq." ".tmpfile
+-    let result           = s:NetGetFile(readcmd, tmpfile, b:netrw_method)
++    let result           = s:NetrwGetFile(readcmd, tmpfile, b:netrw_method)
+     let b:netrw_lastfile = choice
+ 
+    ".........................................
+@@ -764,7 +885,7 @@
+      let netrw_fname= escape(b:netrw_fname,g:netrw_fname_escape)
+ "     call Decho("executing: !".g:netrw_http_cmd." ".tmpfile." http://".g:netrw_machine.netrw_fname)
+      exe g:netrw_silentxfer."!".g:netrw_http_cmd." ".tmpfile." http://".g:netrw_machine.netrw_fname
+-     let result = s:NetGetFile(readcmd, tmpfile, b:netrw_method)
++     let result = s:NetrwGetFile(readcmd, tmpfile, b:netrw_method)
+ 
+     else
+      " wget plus a jump to an in-page marker (ie. http://abc/def.html#aMarker)
+@@ -774,7 +895,7 @@
+ "     call Decho("netrw_tag <".netrw_tag.">")
+ "     call Decho("executing: !".g:netrw_http_cmd." ".tmpfile." http://".g:netrw_machine.netrw_html)
+      exe g:netrw_silentxfer."!".g:netrw_http_cmd." ".tmpfile." http://".g:netrw_machine.netrw_html
+-     let result = s:NetGetFile(readcmd, tmpfile, b:netrw_method)
++     let result = s:NetrwGetFile(readcmd, tmpfile, b:netrw_method)
+ "     call Decho('<\s*a\s*name=\s*"'.netrw_tag.'"/')
+      exe 'norm! 1G/<\s*a\s*name=\s*"'.netrw_tag.'"/'."\<CR>"
+     endif
+@@ -795,7 +916,7 @@
+     else
+      put ='open '.g:netrw_machine
+     endif
+-    put ='user '.g:netrw_uid.' '.g:netrw_passwd
++    put ='user '.g:netrw_uid.' '.s:netrw_passwd
+     put ='get '.netrw_fname.' '.tmpfile
+     put ='quit'
+ 
+@@ -804,7 +925,7 @@
+ "    call Decho("executing: %!".g:netrw_dav_cmd)
+     exe g:netrw_silentxfer."%!".g:netrw_dav_cmd
+     bd!
+-    let result           = s:NetGetFile(readcmd, tmpfile, b:netrw_method)
++    let result           = s:NetrwGetFile(readcmd, tmpfile, b:netrw_method)
+     let b:netrw_lastfile = choice
+ 
+    ".........................................
+@@ -814,7 +935,7 @@
+     let netrw_fname= escape(b:netrw_fname,g:netrw_fname_escape)
+ "    call Decho("executing: !".g:netrw_rsync_cmd." ".g:netrw_machine.":".netrw_fname." ".tmpfile)
+     exe g:netrw_silentxfer."!".g:netrw_rsync_cmd." ".g:netrw_machine.":".netrw_fname." ".tmpfile
+-    let result		= s:NetGetFile(readcmd,tmpfile, b:netrw_method)
++    let result		= s:NetrwGetFile(readcmd,tmpfile, b:netrw_method)
+     let b:netrw_lastfile = choice
+ 
+    ".........................................
+@@ -836,15 +957,15 @@
+     endif
+ "    call Decho("read via fetch for ".netrw_option)
+ 
+-    if exists("g:netrw_uid") && g:netrw_uid != "" && exists("g:netrw_passwd") && g:netrw_passwd != ""
+-"     call Decho("executing: !".g:netrw_fetch_cmd." ".tmpfile." ".netrw_option."://".g:netrw_uid.':'.g:netrw_passwd.'@'.g:netrw_machine."/".netrw_fname)
+-     exe g:netrw_silentxfer."!".g:netrw_fetch_cmd." ".tmpfile." ".netrw_option."://".g:netrw_uid.':'.g:netrw_passwd.'@'.g:netrw_machine."/".netrw_fname
++    if exists("g:netrw_uid") && g:netrw_uid != "" && exists("s:netrw_passwd") && s:netrw_passwd != ""
++"     call Decho("executing: !".g:netrw_fetch_cmd." ".tmpfile." ".netrw_option."://".g:netrw_uid.':'.s:netrw_passwd.'@'.g:netrw_machine."/".netrw_fname)
++     exe g:netrw_silentxfer."!".g:netrw_fetch_cmd." ".tmpfile." ".netrw_option."://".g:netrw_uid.':'.s:netrw_passwd.'@'.g:netrw_machine."/".netrw_fname
+     else
+ "     call Decho("executing: !".g:netrw_fetch_cmd." ".tmpfile." ".netrw_option."://".g:netrw_machine."/".netrw_fname)
+      exe g:netrw_silentxfer."!".g:netrw_fetch_cmd." ".tmpfile." ".netrw_option."://".g:netrw_machine."/".netrw_fname
+     endif
+ 
+-    let result		= s:NetGetFile(readcmd,tmpfile, b:netrw_method)
++    let result		= s:NetrwGetFile(readcmd,tmpfile, b:netrw_method)
+     let b:netrw_lastfile = choice
+     setlocal ro
+ 
+@@ -855,7 +976,7 @@
+     let netrw_fname= escape(b:netrw_fname,g:netrw_fname_escape)
+ "    call Decho("executing: !".g:netrw_sftp_cmd." ".g:netrw_machine.":".netrw_fname." ".tmpfile)
+     exe g:netrw_silentxfer."!".g:netrw_sftp_cmd." ".g:netrw_machine.":".netrw_fname." ".tmpfile
+-    let result		= s:NetGetFile(readcmd, tmpfile, b:netrw_method)
++    let result		= s:NetrwGetFile(readcmd, tmpfile, b:netrw_method)
+     let b:netrw_lastfile = choice
+ 
+    ".........................................
+@@ -875,19 +996,20 @@
+ "   call Decho("cleanup by deleting tmpfile<".tmpfile.">")
+    call s:System("delete",tmpfile)
+   endif
+-  call s:NetOptionRestore()
++  call s:NetrwOptionRestore("w:")
+ 
+ "  call Dret("netrw#NetRead :5 getcwd<".getcwd().">")
+ endfun
+ 
+ " ------------------------------------------------------------------------
+-" NetWrite: responsible for writing a file over the net {{{2
++" netrw#NetWrite: responsible for writing a file over the net {{{2
+ fun! netrw#NetWrite(...) range
+ "  call Dfunc("netrw#NetWrite(a:0=".a:0.") ".g:loaded_netrw)
+ 
+   " option handling
+   let mod= 0
+-  call s:NetOptionSave()
++  call s:NetrwOptionSave("w:")
++  call s:NetrwSafeOptions()
+ 
+   " Get Temporary Filename {{{3
+   let tmpfile= s:GetTempfile("")
+@@ -959,10 +1081,10 @@
+     elseif match(choice,"^\"") != -1
+      if match(choice,"\"$") != -1
+        " case "..."
+-      let choice=strpart(choice,1,strlen(choice)-2)
++      let choice=strpart(choice,1,s:Strlen(choice)-2)
+      else
+       "  case "... ... ..."
+-      let choice      = strpart(choice,1,strlen(choice)-1)
++      let choice      = strpart(choice,1,s:Strlen(choice)-1)
+       let wholechoice = ""
+ 
+       while match(choice,"\"$") == -1
+@@ -977,7 +1099,7 @@
+        endif
+        let choice= a:{ichoice}
+       endwhile
+-      let choice= strpart(wholechoice,1,strlen(wholechoice)-1) . " " . strpart(choice,0,strlen(choice)-1)
++      let choice= strpart(wholechoice,1,s:Strlen(wholechoice)-1) . " " . strpart(choice,0,s:Strlen(choice)-1)
+      endif
+     endif
+    endif
+@@ -985,7 +1107,7 @@
+ "   call Decho("choice<" . choice . "> ichoice=".ichoice)
+ 
+    " Determine method of write (ftp, rcp, etc) {{{4
+-   call s:NetMethod(choice)
++   call s:NetrwMethod(choice)
+ 
+    " =============
+    " Perform Protocol-Based Write {{{4
+@@ -1066,10 +1188,10 @@
+     if exists("g:netrw_ftp") && g:netrw_ftp == 1
+      put =g:netrw_uid
+ "     call Decho("filter input: ".getline("."))
+-     put ='\"'.g:netrw_passwd.'\"'
++     put ='\"'.s:netrw_passwd.'\"'
+ "     call Decho("filter input: ".getline("."))
+     else
+-     put ='user \"'.g:netrw_uid.'\" \"'.g:netrw_passwd.'\"'
++     put ='user \"'.g:netrw_uid.'\" \"'.s:netrw_passwd.'\"'
+ "     call Decho("filter input: ".getline("."))
+     endif
+     put ='put \"'.tmpfile.'\" \"'.netrw_fname.'\"'
+@@ -1129,7 +1251,7 @@
+     else
+      put ='open '.g:netrw_machine
+     endif
+-    put ='user '.g:netrw_uid.' '.g:netrw_passwd
++    put ='user '.g:netrw_uid.' '.s:netrw_passwd
+     put ='put '.tmpfile.' '.netrw_fname
+ 
+     " perform cadaver operation:
+@@ -1181,7 +1303,7 @@
+ "   call Decho("tmpfile<".tmpfile."> readable, will now delete it")
+    call s:System("delete",tmpfile)
+   endif
+-  call s:NetOptionRestore()
++  call s:NetrwOptionRestore("w:")
+ 
+   if a:firstline == 1 && a:lastline == line("$")
+    " restore modifiability; usually equivalent to set nomod
+@@ -1192,7 +1314,7 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetSource: source a remotely hosted vim script {{{2
++" netrw#NetSource: source a remotely hosted vim script {{{2
+ " uses NetRead to get a copy of the file into a temporarily file,
+ "              then sources that file,
+ "              then removes that file.
+@@ -1230,17 +1352,17 @@
+ endfun
+ 
+ " ===========================================
+-" NetGetFile: Function to read temporary file "tfile" with command "readcmd". {{{2
++" s:NetrwGetFile: Function to read temporary file "tfile" with command "readcmd". {{{2
+ "    readcmd == %r : replace buffer with newly read file
+ "            == 0r : read file at top of buffer
+ "            == r  : read file after current line
+ "            == t  : leave file in temporary form (ie. don't read into buffer)
+-fun! s:NetGetFile(readcmd, tfile, method)
+-"  call Dfunc("NetGetFile(readcmd<".a:readcmd.">,tfile<".a:tfile."> method<".a:method.">)")
++fun! s:NetrwGetFile(readcmd, tfile, method)
++"  call Dfunc("NetrwGetFile(readcmd<".a:readcmd.">,tfile<".a:tfile."> method<".a:method.">)")
+ 
+   " readcmd=='t': simply do nothing
+   if a:readcmd == 't'
+-"   call Dret("NetGetFile : skip read of <".a:tfile.">")
++"   call Dret("NetrwGetFile : skip read of <".a:tfile.">")
+    return
+   endif
+ 
+@@ -1305,7 +1427,7 @@
+    " not readable
+ "   call Decho("tfile<".a:tfile."> not readable")
+    call netrw#ErrorMsg(s:WARNING,"file <".a:tfile."> not readable",9)
+-"   call Dret("NetGetFile : tfile<".a:tfile."> not readable")
++"   call Dret("NetrwGetFile : tfile<".a:tfile."> not readable")
+    return
+   endif
+ 
+@@ -1326,11 +1448,11 @@
+ 
+  " make sure file is being displayed
+   redraw!
+-"  call Dret("NetGetFile")
++"  call Dret("NetrwGetFile")
+ endfun
+ 
+ " ------------------------------------------------------------------------
+-" NetMethod:  determine method of transfer {{{2
++" s:NetrwMethod:  determine method of transfer {{{2
+ "  method == 1: rcp
+ "	     2: ftp + <.netrc>
+ "	     3: ftp + machine, id, password, and [path]filename
+@@ -1340,8 +1462,8 @@
+ "	     7: rsync
+ "	     8: fetch
+ "	     9: sftp
+-fun! s:NetMethod(choice)  " globals: method machine id passwd fname
+-"   call Dfunc("NetMethod(a:choice<".a:choice.">)")
++fun! s:NetrwMethod(choice)  " globals: method machine id passwd fname
++"   call Dfunc("NetrwMethod(a:choice<".a:choice.">)")
+ 
+   " initialization
+   let b:netrw_method  = 0
+@@ -1352,8 +1474,8 @@
+ 
+   " Patterns:
+   " mipf     : a:machine a:id password filename	     Use ftp
+-  " mf	    : a:machine filename		     Use ftp + <.netrc> or g:netrw_uid g:netrw_passwd
+-  " ftpurm   : ftp://[user@]host[[#:]port]/filename  Use ftp + <.netrc> or g:netrw_uid g:netrw_passwd
++  " mf	    : a:machine filename		     Use ftp + <.netrc> or g:netrw_uid s:netrw_passwd
++  " ftpurm   : ftp://[user@]host[[#:]port]/filename  Use ftp + <.netrc> or g:netrw_uid s:netrw_passwd
+   " rcpurm   : rcp://[user@]host/filename	     Use rcp
+   " rcphf    : [user@]host:filename		     Use rcp
+   " scpurm   : scp://[user@]host[[#:]port]/filename  Use scp
+@@ -1430,7 +1552,7 @@
+    if userid != ""
+     let g:netrw_uid= userid
+    endif
+-   if exists("g:netrw_uid") && exists("g:netrw_passwd")
++   if exists("g:netrw_uid") && exists("s:netrw_passwd")
+     let b:netrw_method = 3
+    else
+     if s:FileReadable(expand("$HOME/.netrc")) && !g:netrw_ignorenetrc
+@@ -1438,9 +1560,9 @@
+     else
+      if !exists("g:netrw_uid") || g:netrw_uid == ""
+       call NetUserPass()
+-     elseif !exists("g:netrw_passwd") || g:netrw_passwd == ""
++     elseif !exists("s:netrw_passwd") || s:netrw_passwd == ""
+       call NetUserPass(g:netrw_uid)
+-    " else just use current g:netrw_uid and g:netrw_passwd
++    " else just use current g:netrw_uid and s:netrw_passwd
+      endif
+      let b:netrw_method= 3
+     endif
+@@ -1460,13 +1582,13 @@
+    let b:netrw_method  = 3
+    let g:netrw_machine = substitute(a:choice,mipf,'\1',"")
+    let g:netrw_uid     = substitute(a:choice,mipf,'\2',"")
+-   let g:netrw_passwd  = substitute(a:choice,mipf,'\3',"")
++   let s:netrw_passwd  = substitute(a:choice,mipf,'\3',"")
+    let b:netrw_fname   = substitute(a:choice,mipf,'\4',"")
+ 
+   " Issue an ftp: "hostname [path/]filename"
+   elseif match(a:choice,mf) == 0
+ "   call Decho("(ftp) host file")
+-   if exists("g:netrw_uid") && exists("g:netrw_passwd")
++   if exists("g:netrw_uid") && exists("s:netrw_passwd")
+     let b:netrw_method  = 3
+     let g:netrw_machine = substitute(a:choice,mf,'\1',"")
+     let b:netrw_fname   = substitute(a:choice,mf,'\2',"")
+@@ -1518,11 +1640,11 @@
+ "  if exists("g:netrw_uid")		"Decho
+ "   call Decho("g:netrw_uid    <".g:netrw_uid.">")
+ "  endif					"Decho
+-"  if exists("g:netrw_passwd")		"Decho
+-"   call Decho("g:netrw_passwd <".g:netrw_passwd.">")
++"  if exists("s:netrw_passwd")		"Decho
++"   call Decho("s:netrw_passwd <".s:netrw_passwd.">")
+ "  endif					"Decho
+ "  call Decho("b:netrw_fname  <".b:netrw_fname.">")
+-"  call Dret("NetMethod : b:netrw_method=".b:netrw_method)
++"  call Dret("NetrwMethod : b:netrw_method=".b:netrw_method)
+ endfun
+ 
+ " ------------------------------------------------------------------------
+@@ -1565,10 +1687,10 @@
+  " get password
+  if a:0 <= 1 " via prompt
+ "  call Decho("a:0=".a:0." case <=1:")
+-  let g:netrw_passwd= inputsecret("Enter Password: ")
++  let s:netrw_passwd= inputsecret("Enter Password: ")
+  else " from command line
+ "  call Decho("a:0=".a:0." case >1: a:2<".a:2.">")
+-  let g:netrw_passwd=a:2
++  let s:netrw_passwd=a:2
+  endif
+ 
+ "  call Dret("NetUserPass")
+@@ -1583,110 +1705,162 @@
+ fun! s:BrowserMaps(islocal)
+ "  call Dfunc("s:BrowserMaps(islocal=".a:islocal.") b:netrw_curdir<".b:netrw_curdir.">")
+   if a:islocal
+-   nnoremap <buffer> <silent> <cr>	:call netrw#LocalBrowseCheck(<SID>NetBrowseChgDir(1,<SID>NetGetWord()))<cr>
+-   nnoremap <buffer> <silent> <leftmouse> <leftmouse>:call netrw#LocalBrowseCheck(<SID>NetBrowseChgDir(1,<SID>NetGetWord()))<cr>
+-   nnoremap <buffer> <silent> <c-l>	:call <SID>NetRefresh(1,<SID>NetBrowseChgDir(1,'./'))<cr>
+-   nnoremap <buffer> <silent> -		:exe "norm! 0"<bar>call netrw#LocalBrowseCheck(<SID>NetBrowseChgDir(1,'../'))<cr>
+-   nnoremap <buffer> <silent> a		:call <SID>NetHide(1)<cr>
+-   nnoremap <buffer> <silent> mb	:<c-u>call <SID>NetBookmarkDir(0,b:netrw_curdir)<cr>
+-   nnoremap <buffer> <silent> gb	:<c-u>call <SID>NetBookmarkDir(1,b:netrw_curdir)<cr>
+-   nnoremap <buffer> <silent> c		:exe "cd ".b:netrw_curdir<cr>
++   nnoremap <buffer> <silent> <cr>	:call netrw#LocalBrowseCheck(<SID>NetrwBrowseChgDir(1,<SID>NetrwGetWord()))<cr>
++   nnoremap <buffer> <silent> -		:exe "norm! 0"<bar>call netrw#LocalBrowseCheck(<SID>NetrwBrowseChgDir(1,'../'))<cr>
++   nnoremap <buffer> <silent> a		:call <SID>NetrwHide(1)<cr>
++   nnoremap <buffer> <silent> mb	:<c-u>call <SID>NetrwBookmarkDir(0,b:netrw_curdir)<cr>
++   nnoremap <buffer> <silent> mc	:<c-u>call <SID>NetrwMarkFileCopy(1)<cr>
++   nnoremap <buffer> <silent> md	:<c-u>call <SID>NetrwMarkFileDiff(1)<cr>
++   nnoremap <buffer> <silent> me	:<c-u>call <SID>NetrwMarkFileEdit(1)<cr>
++   nnoremap <buffer> <silent> mf	:<c-u>call <SID>NetrwMarkFile(1,<SID>NetrwGetWord())<cr>
++   nnoremap <buffer> <silent> mm	:<c-u>call <SID>NetrwMarkFileMove(1)<cr>
++   nnoremap <buffer> <silent> mp	:<c-u>call <SID>NetrwMarkFilePrint(1)<cr>
++   nnoremap <buffer> <silent> mr	:<c-u>call <SID>NetrwMarkFileRegexp(1)<cr>
++   nnoremap <buffer> <silent> mT	:<c-u>call <SID>NetrwMarkFileTag(1)<cr>
++   nnoremap <buffer> <silent> mt	:<c-u>call <SID>NetrwMarkFileTgt(1)<cr>
++   nnoremap <buffer> <silent> mx	:<c-u>call <SID>NetrwMarkFileExe(1)<cr>
++   nnoremap <buffer> <silent> mz	:<c-u>call <SID>NetrwMarkFileCompress(1)<cr>
++   nnoremap <buffer> <silent> gb	:<c-u>call <SID>NetrwBookmarkDir(1,b:netrw_curdir)<cr>
++   nnoremap <buffer> <silent> c		:exe "cd ".escape(b:netrw_curdir,g:netrw_cd_escape)<cr>
+    nnoremap <buffer> <silent> C		:let g:netrw_chgwin= winnr()<cr>
+-   nnoremap <buffer> <silent> d		:call <SID>NetMakeDir("")<cr>
+-   nnoremap <buffer> <silent> <c-h>	:call <SID>NetHideEdit(1)<cr>
+-   nnoremap <buffer> <silent> i		:call <SID>NetListStyle(1)<cr>
+-   nnoremap <buffer> <silent> o		:call <SID>NetSplit(3)<cr>
+-   nnoremap <buffer> <silent> O		:call <SID>LocalObtain()<cr>
+-   nnoremap <buffer> <silent> p		:call <SID>NetPreview(<SID>NetBrowseChgDir(1,<SID>NetGetWord(),1))<cr>
+-   nnoremap <buffer> <silent> P		:call <SID>NetPrevWinOpen(1)<cr>
+-   nnoremap <buffer> <silent> q		:<c-u>call <SID>NetBookmarkDir(2,b:netrw_curdir)<cr>
+-   nnoremap <buffer> <silent> r		:let g:netrw_sort_direction= (g:netrw_sort_direction =~ 'n')? 'r' : 'n'<bar>exe "norm! 0"<bar>call <SID>NetRefresh(1,<SID>NetBrowseChgDir(1,'./'))<cr>
+-   nnoremap <buffer> <silent> s		:call <SID>NetSortStyle(1)<cr>
++   nnoremap <buffer> <silent> d		:call <SID>NetrwMakeDir("")<cr>
++   nnoremap <buffer> <silent> i		:call <SID>NetrwListStyle(1)<cr>
++   nnoremap <buffer> <silent> o		:call <SID>NetrwSplit(3)<cr>
++   nnoremap <buffer> <silent> O		:call <SID>NetrwObtain(0)<cr>
++   nnoremap <buffer> <silent> p		:call <SID>NetrwPreview(<SID>NetrwBrowseChgDir(1,<SID>NetrwGetWord(),1))<cr>
++   nnoremap <buffer> <silent> P		:call <SID>NetrwPrevWinOpen(1)<cr>
++   nnoremap <buffer> <silent> q		:<c-u>call <SID>NetrwBookmarkDir(2,b:netrw_curdir)<cr>
++   nnoremap <buffer> <silent> r		:let g:netrw_sort_direction= (g:netrw_sort_direction =~ 'n')? 'r' : 'n'<bar>exe "norm! 0"<bar>call <SID>NetrwRefresh(1,<SID>NetrwBrowseChgDir(1,'./'))<cr>
++   nnoremap <buffer> <silent> s		:call <SID>NetrwSortStyle(1)<cr>
+    nnoremap <buffer> <silent> S		:call <SID>NetSortSequence(1)<cr>
+-   nnoremap <buffer> <silent> t		:call <SID>NetSplit(4)<cr>
+-   nnoremap <buffer> <silent> u		:<c-u>call <SID>NetBookmarkDir(4,expand("%"))<cr>
+-   nnoremap <buffer> <silent> U		:<c-u>call <SID>NetBookmarkDir(5,expand("%"))<cr>
+-   nnoremap <buffer> <silent> v		:call <SID>NetSplit(5)<cr>
+-   nnoremap <buffer> <silent> x		:call netrw#NetBrowseX(<SID>NetBrowseChgDir(1,<SID>NetGetWord(),0),0)"<cr>
++   nnoremap <buffer> <silent> t		:call <SID>NetrwSplit(4)<cr>
++   nnoremap <buffer> <silent> u		:<c-u>call <SID>NetrwBookmarkDir(4,expand("%"))<cr>
++   nnoremap <buffer> <silent> U		:<c-u>call <SID>NetrwBookmarkDir(5,expand("%"))<cr>
++   nnoremap <buffer> <silent> v		:call <SID>NetrwSplit(5)<cr>
++   nnoremap <buffer> <silent> x		:call netrw#NetrwBrowseX(<SID>NetrwBrowseChgDir(1,<SID>NetrwGetWord(),0),0)"<cr>
++   if !hasmapto('<Plug>NetrwHideEdit')
++    nmap <buffer> <unique> <c-h> <Plug>NetrwHideEdit
++   endif
++   nnoremap <buffer> <silent> <Plug>NetrwHideEdit	:call <SID>NetrwHideEdit(1)<cr>
++   if !hasmapto('<Plug>NetrwRefresh')
++    nmap <buffer> <unique> <c-l> <Plug>NetrwRefresh
++   endif
++   nnoremap <buffer> <silent> <Plug>NetrwRefresh		:call <SID>NetrwRefresh(1,<SID>NetrwBrowseChgDir(1,'./'))<cr>
+    if s:didstarstar || !mapcheck("<s-down>","n")
+     nnoremap <buffer> <silent> <s-down>	:Nexplore<cr>
+    endif
+    if s:didstarstar || !mapcheck("<s-up>","n")
+     nnoremap <buffer> <silent> <s-up>	:Pexplore<cr>
+    endif
+-   exe 'nnoremap <buffer> <silent> <del>	:call <SID>LocalBrowseRm("'.b:netrw_curdir.'")<cr>'
+-   exe 'vnoremap <buffer> <silent> <del>	:call <SID>LocalBrowseRm("'.b:netrw_curdir.'")<cr>'
+-   exe 'nnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>LocalBrowseRm("'.b:netrw_curdir.'")<cr>'
+-   exe 'vnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>LocalBrowseRm("'.b:netrw_curdir.'")<cr>'
+-   exe 'nnoremap <buffer> <silent> D		:call <SID>LocalBrowseRm("'.b:netrw_curdir.'")<cr>'
+-   exe 'vnoremap <buffer> <silent> D		:call <SID>LocalBrowseRm("'.b:netrw_curdir.'")<cr>'
+-   exe 'nnoremap <buffer> <silent> R		:call <SID>LocalBrowseRename("'.b:netrw_curdir.'")<cr>'
+-   exe 'vnoremap <buffer> <silent> R		:call <SID>LocalBrowseRename("'.b:netrw_curdir.'")<cr>'
+-   exe 'nnoremap <buffer> <silent> <Leader>m	:call <SID>NetMakeDir("")<cr>'
++   if g:netrw_mousemaps == 1
++    nnoremap <buffer> <silent> <leftmouse>   <leftmouse>:call <SID>NetrwLeftmouse(1)<cr>
++    nnoremap <buffer> <silent> <middlemouse> <leftmouse>:call <SID>NetrwPrevWinOpen(1)<cr>
++    nnoremap <buffer> <silent> <s-leftmouse> <leftmouse>:call <SID>NetrwMarkFile(1,<SID>NetrwGetWord())<cr>
++    exe 'nnoremap <buffer> <silent> <rightmouse>  <leftmouse>:call <SID>NetrwLocalRm("'.b:netrw_curdir.'")<cr>'
++    exe 'vnoremap <buffer> <silent> <rightmouse>  <leftmouse>:call <SID>NetrwLocalRm("'.b:netrw_curdir.'")<cr>'
++   endif
++   exe 'nnoremap <buffer> <silent> <del>	:call <SID>NetrwLocalRm("'.b:netrw_curdir.'")<cr>'
++   exe 'vnoremap <buffer> <silent> <del>	:call <SID>NetrwLocalRm("'.b:netrw_curdir.'")<cr>'
++   exe 'nnoremap <buffer> <silent> D		:call <SID>NetrwLocalRm("'.b:netrw_curdir.'")<cr>'
++   exe 'vnoremap <buffer> <silent> D		:call <SID>NetrwLocalRm("'.b:netrw_curdir.'")<cr>'
++   exe 'nnoremap <buffer> <silent> R		:call <SID>NetrwLocalRename("'.b:netrw_curdir.'")<cr>'
++   exe 'vnoremap <buffer> <silent> R		:call <SID>NetrwLocalRename("'.b:netrw_curdir.'")<cr>'
++   exe 'nnoremap <buffer> <silent> <Leader>m	:call <SID>NetrwMakeDir("")<cr>'
+    nnoremap <buffer> <F1>		:he netrw-dir<cr>
+ 
+   else " remote
+    call s:RemotePathAnalysis(b:netrw_curdir)
+-   nnoremap <buffer> <silent> <cr>	:call <SID>NetBrowse(0,<SID>NetBrowseChgDir(0,<SID>NetGetWord()))<cr>
+-   nnoremap <buffer> <silent> <leftmouse> <leftmouse>:call <SID>NetBrowse(0,<SID>NetBrowseChgDir(0,<SID>NetGetWord()))<cr>
+-   nnoremap <buffer> <silent> <c-l>	:call <SID>NetRefresh(0,<SID>NetBrowseChgDir(0,'./'))<cr>
+-   nnoremap <buffer> <silent> -		:exe "norm! 0"<bar>call <SID>NetBrowse(0,<SID>NetBrowseChgDir(0,'../'))<cr>
+-   nnoremap <buffer> <silent> a		:call <SID>NetHide(0)<cr>
+-   nnoremap <buffer> <silent> mb	:<c-u>call <SID>NetBookmarkDir(0,b:netrw_curdir)<cr>
+-   nnoremap <buffer> <silent> gb	:<c-u>call <SID>NetBookmarkDir(1,b:netrw_cur)<cr>
++   nnoremap <buffer> <silent> <cr>	:call <SID>NetrwBrowse(0,<SID>NetrwBrowseChgDir(0,<SID>NetrwGetWord()))<cr>
++   nnoremap <buffer> <silent> <c-l>	:call <SID>NetrwRefresh(0,<SID>NetrwBrowseChgDir(0,'./'))<cr>
++   nnoremap <buffer> <silent> -		:exe "norm! 0"<bar>call <SID>NetrwBrowse(0,<SID>NetrwBrowseChgDir(0,'../'))<cr>
++   nnoremap <buffer> <silent> a		:call <SID>NetrwHide(0)<cr>
++   nnoremap <buffer> <silent> mb	:<c-u>call <SID>NetrwBookmarkDir(0,b:netrw_curdir)<cr>
++   nnoremap <buffer> <silent> mc	:<c-u>call <SID>NetrwMarkFileCopy(0)<cr>
++   nnoremap <buffer> <silent> md	:<c-u>call <SID>NetrwMarkFileDiff(0)<cr>
++   nnoremap <buffer> <silent> me	:<c-u>call <SID>NetrwMarkFileEdit(0)<cr>
++   nnoremap <buffer> <silent> mf	:<c-u>call <SID>NetrwMarkFile(0,<SID>NetrwGetWord())<cr>
++   nnoremap <buffer> <silent> mm	:<c-u>call <SID>NetrwMarkFileMove(0)<cr>
++   nnoremap <buffer> <silent> mp	:<c-u>call <SID>NetrwMarkFilePrint(0)<cr>
++   nnoremap <buffer> <silent> mr	:<c-u>call <SID>NetrwMarkFileRegexp(0)<cr>
++   nnoremap <buffer> <silent> mT	:<c-u>call <SID>NetrwMarkFileTag(0)<cr>
++   nnoremap <buffer> <silent> mt	:<c-u>call <SID>NetrwMarkFileTgt(0)<cr>
++   nnoremap <buffer> <silent> mx	:<c-u>call <SID>NetrwMarkFileExe(0)<cr>
++   nnoremap <buffer> <silent> mz	:<c-u>call <SID>NetrwMarkFileCompress(0)<cr>
++   nnoremap <buffer> <silent> gb	:<c-u>call <SID>NetrwBookmarkDir(1,b:netrw_cur)<cr>
+    nnoremap <buffer> <silent> C		:let g:netrw_chgwin= winnr()<cr>
+-   nnoremap <buffer> <silent> <c-h>	:call <SID>NetHideEdit(0)<cr>
+-   nnoremap <buffer> <silent> i		:call <SID>NetListStyle(0)<cr>
+-   nnoremap <buffer> <silent> o		:call <SID>NetSplit(0)<cr>
+-   nnoremap <buffer> <silent> O		:call netrw#NetObtain(0)<cr>
+-   vnoremap <buffer> <silent> O		:call netrw#NetObtain(1)<cr>
+-   nnoremap <buffer> <silent> p		:call <SID>NetPreview(<SID>NetBrowseChgDir(1,<SID>NetGetWord(),1))<cr>
+-   nnoremap <buffer> <silent> P		:call <SID>NetPrevWinOpen(0)<cr>
+-   nnoremap <buffer> <silent> q		:<c-u>call <SID>NetBookmarkDir(2,b:netrw_curdir)<cr>
+-   nnoremap <buffer> <silent> r		:let g:netrw_sort_direction= (g:netrw_sort_direction =~ 'n')? 'r' : 'n'<bar>exe "norm! 0"<bar>call <SID>NetBrowse(0,<SID>NetBrowseChgDir(0,'./'))<cr>
+-   nnoremap <buffer> <silent> s		:call <SID>NetSortStyle(0)<cr>
++   nnoremap <buffer> <silent> i		:call <SID>NetrwListStyle(0)<cr>
++   nnoremap <buffer> <silent> o		:call <SID>NetrwSplit(0)<cr>
++   nnoremap <buffer> <silent> O		:call <SID>NetrwObtain(0)<cr>
++   nnoremap <buffer> <silent> p		:call <SID>NetrwPreview(<SID>NetrwBrowseChgDir(1,<SID>NetrwGetWord(),1))<cr>
++   nnoremap <buffer> <silent> P		:call <SID>NetrwPrevWinOpen(0)<cr>
++   nnoremap <buffer> <silent> q		:<c-u>call <SID>NetrwBookmarkDir(2,b:netrw_curdir)<cr>
++   nnoremap <buffer> <silent> r		:let g:netrw_sort_direction= (g:netrw_sort_direction =~ 'n')? 'r' : 'n'<bar>exe "norm! 0"<bar>call <SID>NetrwBrowse(0,<SID>NetrwBrowseChgDir(0,'./'))<cr>
++   nnoremap <buffer> <silent> s		:call <SID>NetrwSortStyle(0)<cr>
+    nnoremap <buffer> <silent> S		:call <SID>NetSortSequence(0)<cr>
+-   nnoremap <buffer> <silent> t		:call <SID>NetSplit(1)<cr>
+-   nnoremap <buffer> <silent> u		:<c-u>call <SID>NetBookmarkDir(4,b:netrw_curdir)<cr>
+-   nnoremap <buffer> <silent> U		:<c-u>call <SID>NetBookmarkDir(5,b:netrw_curdir)<cr>
+-   nnoremap <buffer> <silent> v		:call <SID>NetSplit(2)<cr>
+-   nnoremap <buffer> <silent> x		:call netrw#NetBrowseX(<SID>NetBrowseChgDir(0,<SID>NetGetWord()),1)<cr>
+-   exe 'nnoremap <buffer> <silent> <del>	:call <SID>NetBrowseRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
+-   exe 'vnoremap <buffer> <silent> <del>	:call <SID>NetBrowseRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
+-   exe 'nnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetBrowseRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
+-   exe 'vnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetBrowseRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
+-   exe 'nnoremap <buffer> <silent> d	:call <SID>NetMakeDir("'.s:user.s:machine.'")<cr>'
+-   exe 'nnoremap <buffer> <silent> D	:call <SID>NetBrowseRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
+-   exe 'vnoremap <buffer> <silent> D	:call <SID>NetBrowseRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
+-   exe 'nnoremap <buffer> <silent> R	:call <SID>NetBrowseRename("'.s:user.s:machine.'","'.s:path.'")<cr>'
+-   exe 'vnoremap <buffer> <silent> R	:call <SID>NetBrowseRename("'.s:user.s:machine.'","'.s:path.'")<cr>'
++   nnoremap <buffer> <silent> t		:call <SID>NetrwSplit(1)<cr>
++   nnoremap <buffer> <silent> u		:<c-u>call <SID>NetrwBookmarkDir(4,b:netrw_curdir)<cr>
++   nnoremap <buffer> <silent> U		:<c-u>call <SID>NetrwBookmarkDir(5,b:netrw_curdir)<cr>
++   nnoremap <buffer> <silent> v		:call <SID>NetrwSplit(2)<cr>
++   nnoremap <buffer> <silent> x		:call netrw#NetrwBrowseX(<SID>NetrwBrowseChgDir(0,<SID>NetrwGetWord()),1)<cr>
++   if !hasmapto('<Plug>NetrwHideEdit')
++    nmap <buffer> <c-h> <Plug>NetrwHideEdit
++   endif
++   nnoremap <buffer> <silent> <Plug>NetrwHideEdit	:call <SID>NetrwHideEdit(0)<cr>
++   if !hasmapto('<Plug>NetrwRefresh')
++    nmap <buffer> <c-l> <Plug>NetrwRefresh
++   endif
++   nnoremap <buffer> <silent> <Plug>NetrwRefresh		:call <SID>NetrwRefresh(0,<SID>NetrwBrowseChgDir(0,'./'))<cr>
++   if g:netrw_mousemaps == 1
++    nnoremap <buffer> <silent> <leftmouse>   <leftmouse>:call <SID>NetrwLeftmouse(0)<cr>
++    nnoremap <buffer> <silent> <middlemouse> <leftmouse>:call <SID>NetrwPrevWinOpen(0)<cr>
++    nnoremap <buffer> <silent> <s-leftmouse> <leftmouse>:call <SID>NetrwMarkFile(0,<SID>NetrwGetWord())<cr>
++    exe 'nnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwRemoteRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
++    exe 'vnoremap <buffer> <silent> <rightmouse> <leftmouse>:call <SID>NetrwRemoteRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
++   endif
++   exe 'nnoremap <buffer> <silent> <del>	:call <SID>NetrwRemoteRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
++   exe 'vnoremap <buffer> <silent> <del>	:call <SID>NetrwRemoteRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
++   exe 'nnoremap <buffer> <silent> d	:call <SID>NetrwMakeDir("'.s:user.s:machine.'")<cr>'
++   exe 'nnoremap <buffer> <silent> D	:call <SID>NetrwRemoteRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
++   exe 'vnoremap <buffer> <silent> D	:call <SID>NetrwRemoteRm("'.s:user.s:machine.'","'.s:path.'")<cr>'
++   exe 'nnoremap <buffer> <silent> R	:call <SID>NetrwRemoteRename("'.s:user.s:machine.'","'.s:path.'")<cr>'
++   exe 'vnoremap <buffer> <silent> R	:call <SID>NetrwRemoteRename("'.s:user.s:machine.'","'.s:path.'")<cr>'
+    nnoremap <buffer> <F1>			:he netrw-browse-cmds<cr>
+   endif
++  call s:SetRexDir(a:islocal,b:netrw_curdir)
+ "  call Dret("s:BrowserMaps")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" s:NetBrowse: This function uses the command in g:netrw_list_cmd to get a list {{{2
+-"  of the contents of a remote directory.  It is assumed that the
++" s:NetrwBrowse: This function uses the command in g:netrw_list_cmd to provide a {{{2
++"  list of the contents of a local or remote directory.  It is assumed that the
+ "  g:netrw_list_cmd has a string, USEPORT HOSTNAME, that needs to be substituted
+ "  with the requested remote hostname first.
+-fun! s:NetBrowse(islocal,dirname)
++fun! s:NetrwBrowse(islocal,dirname)
+   if !exists("w:netrw_liststyle")|let w:netrw_liststyle= g:netrw_liststyle|endif
+-"  call Dfunc("NetBrowse(islocal=".a:islocal." dirname<".a:dirname.">) liststyle=".w:netrw_liststyle." ".g:loaded_netrw." buf#".bufnr("%")."<".bufname("%").">")
++"  call Dfunc("NetrwBrowse(islocal=".a:islocal." dirname<".a:dirname.">) liststyle=".w:netrw_liststyle." ".g:loaded_netrw." buf#".bufnr("%")."<".bufname("%").">")
+ "  call Dredir("ls!")
+ 
+   if exists("s:netrw_skipbrowse")
+    unlet s:netrw_skipbrowse
+-"   call Dret("NetBrowse : s:netrw_skipbrowse=".s:netrw_skipbrowse)
++"   call Dret("NetrwBrowse : s:netrw_skipbrowse=".s:netrw_skipbrowse)
+    return
+   endif
+ 
+-  call s:NetOptionSave()
++  call s:NetrwOptionSave("w:")
++  call s:NetrwSafeOptions()
++
++  " clear any marked files
++  if exists("s:netrwmarkfilelist")
++"   call Decho("clearing marked files")
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
++  endif
+ 
+   if a:islocal && exists("w:netrw_acdkeep") && w:netrw_acdkeep
+ "   call Decho("handle w:netrw_acdkeep:")
+-"   call Decho("cd ".escape(a:dirname,s:netrw_cd_escape)." (due to 'acd')")
+-   exe 'cd '.escape(a:dirname,s:netrw_cd_escape)
++"   call Decho("cd ".escape(a:dirname,g:netrw_cd_escape)." (due to w:netrw_acdkeep=".w:netrw_acdkeep." - acd=".&acd.")")
++   exe 'cd '.escape(a:dirname,g:netrw_cd_escape)
+ "   call Decho("getcwd<".getcwd().">")
+ 
+   elseif !a:islocal && a:dirname !~ '[\/]$' && a:dirname !~ '^"'
+@@ -1703,21 +1877,23 @@
+    " remote-read the requested file into current buffer {{{3
+    mark '
+    call s:NetrwEnew(a:dirname)
+-   let b:netrw_curdir= a:dirname
+-   call s:NetrwSafeOptions()
+    setlocal ma noro
+-"   call Decho("exe silent! keepalt file ".s:method."://".s:user.s:machine."/".escape(s:path,s:netrw_cd_escape)." (bt=".&bt.")")
+-   exe "silent! keepalt file ".s:method."://".s:user.s:machine."/".escape(s:path,s:netrw_cd_escape)
++   let b:netrw_curdir= a:dirname
++"   call Decho("exe silent! keepalt file ".s:method."://".s:user.s:machine."/".escape(s:path,g:netrw_cd_escape)." (bt=".&bt.")")
++   exe "silent! keepalt file ".s:method."://".s:user.s:machine."/".escape(s:path,g:netrw_cd_escape)
+    exe "silent keepalt doau BufReadPre ".s:fname
+    silent call netrw#NetRead(2,s:method."://".s:user.s:machine."/".s:path)
+-   exe "silent keepalt doau BufReadPost ".s:fname
++   if s:path !~ '.tar.bz2$' && s:path !~ '.tar.gz'
++    " netrw.vim and tar.vim have already handled decompression of the tarball; avoiding gzip.vim error
++    exe "silent keepalt doau BufReadPost ".s:fname
++   endif
+ 
+    " save certain window-oriented variables into buffer-oriented variables {{{3
+    call s:SetBufWinVars()
+-   call s:NetOptionRestore()
+-   setlocal nomod nowrap
++   call s:NetrwOptionRestore("w:")
++   setlocal noma nomod nowrap
+ 
+-"   call Dret("NetBrowse : file<".s:fname.">")
++"   call Dret("NetrwBrowse : file<".s:fname.">")
+    return
+   endif
+ 
+@@ -1729,9 +1905,11 @@
+   let dirname                = a:dirname
+   let s:last_sort_by         = g:netrw_sort_by
+ 
+-  call s:NetMenu(1)                      " set up menu {{{3
+-  if s:NetGetBuffer(a:islocal,dirname)   " set up buffer {{{3
+-"   call Dret("NetBrowse : re-using buffer")
++  call s:NetrwMenu(1)                      " set up menu {{{3
++  if s:NetrwGetBuffer(a:islocal,dirname)   " set up buffer {{{3
++   call s:NetrwOptionRestore("w:")
++   setlocal noma nomod nowrap
++"   call Dret("NetrwBrowse : re-using buffer")
+    return
+   endif
+ 
+@@ -1767,18 +1945,19 @@
+ 
+   " handle g:netrw_keepdir: set vim's current directory to netrw's notion of the current directory {{{3
+    if !g:netrw_keepdir
+-"    call Decho("handle keepdir: (g:netrw_keepdir=".g:netrw_keepdir.")")
+-"    call Decho('exe cd '.escape(b:netrw_curdir,s:netrw_cd_escape))
++"    call Decho("handle g:netrw_keepdir=".g:netrw_keepdir.": getcwd<".getcwd()."> acd=".&acd)
++"    call Decho('exe cd '.escape(b:netrw_curdir,g:netrw_cd_escape))
+     try
+-     exe 'cd '.escape(b:netrw_curdir,s:netrw_cd_escape)
++     exe 'cd '.escape(b:netrw_curdir,g:netrw_cd_escape)
+     catch /^Vim\%((\a\+)\)\=:E472/
+      call netrw#ErrorMsg(s:ERROR,"unable to change directory to <".b:netrw_curdir."> (permissions?)",33)
+      if exists("w:netrw_prvdir")
+       let b:netrw_curdir= w:netrw_prvdir
+      else
+-      call s:NetOptionRestore()
++      call s:NetrwOptionRestore("w:")
++      setlocal noma nomod nowrap
+       let b:netrw_curdir= dirname
+-"      call Dret("NetBrowse : reusing buffer#".(exists("bufnum")? bufnum : 'N/A')."<".dirname."> getcwd<".getcwd().">")
++"      call Dret("NetrwBrowse : reusing buffer#".(exists("bufnum")? bufnum : 'N/A')."<".dirname."> getcwd<".getcwd().">")
+       return
+      endif
+     endtry
+@@ -1812,8 +1991,9 @@
+     if !exists("g:netrw_quiet")
+      call netrw#ErrorMsg(s:ERROR,"netrw doesn't understand your dirname<".dirname.">",20)
+     endif
+-     call s:NetOptionRestore()
+-"    call Dret("NetBrowse : badly formatted dirname<".dirname.">")
++     call s:NetrwOptionRestore("w:")
++     setlocal noma nomod nowrap
++"    call Dret("NetrwBrowse : badly formatted dirname<".dirname.">")
+     return
+    endif
+    let b:netrw_curdir= dirname
+@@ -1823,47 +2003,68 @@
+   " -----------------------
+   " Directory Listing: {{{3
+   " -----------------------
+-  setlocal noro ma
+   call s:BrowserMaps(a:islocal)
+   call s:PerformListing(a:islocal)
+ 
+-"  call Dret("NetBrowse")
++"  call Dret("NetrwBrowse : did PerformListing")
+   return
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" s:NetGetBuffer: {{{2
++" s:NetrwGetBuffer: {{{2
+ "   returns 0=cleared buffer
+ "           1=re-used buffer
+-fun! s:NetGetBuffer(islocal,dirname)
+-"  call Dfunc("s:NetGetBuffer(islocal=".a:islocal." dirname<".a:dirname.">)")
++fun! s:NetrwGetBuffer(islocal,dirname)
++"  call Dfunc("s:NetrwGetBuffer(islocal=".a:islocal." dirname<".a:dirname.">)")
+ 
+   " re-use buffer if possible {{{3
++"  call Decho("--re-use a buffer if possible--")
+   if exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST
+    " find NetrwTreeList buffer if there is one
++"   call Decho("find NetrwTreeList buffer if there is one")
+    let dirname= "NetrwTreeListing"
+    let bufnum = bufnr('\<NetrwTreeListing\>')
+    if bufnum != -1
+-"    call Dret("s:NetGetBuffer : bufnum#".bufnum."<NetrwTreeListing>")
++"    call Dret("s:NetrwGetBuffer : bufnum#".bufnum."<NetrwTreeListing>")
+     return
+    endif
+ 
+   else
+    " find buffer number of buffer named precisely the same as dirname {{{3
++"   call Decho("--find buffer numnber of buffer named precisely the same as dirname--")
+ "   call Dredir("ls!")
+    let dirname= a:dirname
+ "   call Decho("find buffer<".dirname.">'s number ")
+    let bufnum= bufnr(escape(dirname,'\'))
+-"   call Decho("findbuf1: bufnum=bufnr('".escape(dirname,'\')."')=".bufnum." (initial)")
++"   call Decho("bufnr(dirname<".escape(dirname,'\').">)=".bufnum)
++   if bufnum < 0 && dirname !~ '/$'
++    " trying appending a trailing /
++"    call Decho("try appending a trailing / to dirname<".dirname.">")
++    let bufnum= bufnr(escape(dirname.'/','\'))
++    if bufnum > 0
++     let dirname= dirname.'/'
++    endif
++   endif
++   if bufnum < 0 && dirname =~ '/$'
++    " trying removing a trailing /
++"    call Decho("try removing a trailing / from dirname<".dirname.">")
++    let bufnum= bufnr(escape(substitute(dirname,'/$','',''),'\'))
++    if bufnum > 0
++     let dirname= substitute(dirname,'/$','','')
++    endif
++   endif
++"   call Decho("findbuf1: bufnum=bufnr('".dirname."')=".bufnum." bufname(".bufnum.")<".bufname(bufnum)."> (initial)")
+    let ibuf= 1
++   " note: !~ was used just below, but that means using ../ to go back would match (ie. abc/def/  and abc/ matches)
+    if bufnum > 0 && bufname(bufnum) != dirname
+     let buflast = bufnr("$")
+ "    call Decho("findbuf2: buflast=".buflast)
+     while ibuf <= buflast
+-     let bname= bufname(ibuf)
++     let bname= substitute(bufname(ibuf),'\\','/','g')
+ "     call Decho("findbuf3: dirname<".dirname."> bufname(".ibuf.")<".bname.">")
+      if bname != '' && bname !~ '/' && dirname =~ '/'.bname.'$' | break | endif
+-     if bname =~ '^'.dirname.'\=$' | break | endif
++     if bname =~ '^'.dirname.'/\=$' | break | endif
++     if dirname =~ '^'.bname.'/$' | break | endif
+      let ibuf= ibuf + 1
+     endwhile
+     if ibuf > buflast
+@@ -1876,19 +2077,23 @@
+   endif
+ 
+   " get enew buffer and name it -or- re-use buffer {{{3
++"  call Decho("--get enewbuffer and name it -or- re-use buffer--")
+   mark '
+   if bufnum < 0 || !bufexists(bufnum)
+ "   call Decho("get enew buffer")
+    call s:NetrwEnew(dirname)
+-   call s:NetrwSafeOptions()
+    " name the buffer
+    if exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST
+ "    call Decho('silent! keepalt file NetrwTreeListing')
+     silent! keepalt file NetrwTreeListing
++    nnoremap <silent> <buffer> [	:silent call <SID>TreeListMove('[')<cr>
++    nnoremap <silent> <buffer> ]	:silent call <SID>TreeListMove(']')<cr>
++    nnoremap <silent> <buffer> [[       :silent call <SID>TreeListMove('[')<cr>
++    nnoremap <silent> <buffer> ]]       :silent call <SID>TreeListMove(']')<cr>
+    else
+-"    call Decho('exe silent! keepalt file '.escape(dirname,s:netrw_cd_escape))
++"    call Decho('exe silent! keepalt file '.escape(dirname,g:netrw_cd_escape))
+ "    let v:errmsg= "" " Decho
+-    let escdirname= escape(dirname,s:netrw_cd_escape)
++    let escdirname= escape(dirname,g:netrw_cd_escape)
+     exe 'silent! keepalt file '.escdirname
+ "    call Decho("errmsg<".v:errmsg."> bufnr(".escdirname.")=".bufnr(escdirname)."<".bufname(bufnr(escdirname)).">")
+    endif
+@@ -1896,7 +2101,7 @@
+ 
+   else " Re-use the buffer
+ 
+-"   call Decho("re-use buffer:")
++"   call Decho("re-use buffer#".bufnum.":")
+    let eikeep= &ei
+    set ei=all
+    if getline(2) =~ '^" Netrw Directory Listing'
+@@ -1909,16 +2114,16 @@
+    let &ei= eikeep
+    if line("$") <= 1
+     call s:NetrwListSettings(a:islocal)
+-"    call Dret("s:NetGetBuffer 0 : re-using buffer#".bufnr("%").", but its empty, so refresh it")
++"    call Dret("s:NetrwGetBuffer 0 : re-using buffer#".bufnr("%").", but its empty, so refresh it")
+     return 0
+    elseif exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST
+ "    call Decho("clear buffer<".expand("%")."> with :%d")
+     silent %d
+     call s:NetrwListSettings(a:islocal)
+-"    call Dret("s:NetGetBuffer 0 : re-using buffer#".bufnr("%").", but treelist mode always needs a refresh")
++"    call Dret("s:NetrwGetBuffer 0 : re-using buffer#".bufnr("%").", but treelist mode always needs a refresh")
+     return 0
+    else
+-"    call Dret("s:NetGetBuffer 1 : buf#".bufnr("%"))
++"    call Dret("s:NetrwGetBuffer 1 : buf#".bufnr("%"))
+     return 1
+    endif
+   endif
+@@ -1928,19 +2133,110 @@
+   "  slow   0         D      D      Deleting a buffer implies it will not be re-used (slow)
+   "  med    1         D      H
+   "  fast   2         H      H
++"  call Decho("--do netrw settings: make this buffer not-a-file, modifiable, not line-numbered, etc--")
+   let fname= expand("%")
+   call s:NetrwListSettings(a:islocal)
+   exe "file ".escape(fname,' ')
+ 
+   " delete all lines from buffer {{{3
++"  call Decho("--delete all lines from buffer--")
+ "  call Decho("clear buffer<".expand("%")."> with :%d")
+   keepalt silent! %d
+ 
+-"  call Dret("s:NetGetBuffer 0 : buf#".bufnr("%"))
++"  call Dret("s:NetrwGetBuffer 0 : buf#".bufnr("%"))
+   return 0
+ endfun
+ 
+ " ---------------------------------------------------------------------
++"  s:NetrwGetWord: it gets the directory named under the cursor {{{2
++fun! s:NetrwGetWord()
++"  call Dfunc("NetrwGetWord() line#".line(".")." liststyle=".g:netrw_liststyle." virtcol=".virtcol("."))
++  call s:UseBufWinVars()
++
++  " insure that w:netrw_liststyle is set up
++  if !exists("w:netrw_liststyle")
++   if exists("g:netrw_liststyle")
++    let w:netrw_liststyle= g:netrw_liststyle
++   else
++    let w:netrw_liststyle= s:THINLIST
++   endif
++"   call Decho("w:netrw_liststyle=".w:netrw_liststyle)
++  endif
++
++  if exists("w:netrw_bannercnt") && line(".") < w:netrw_bannercnt
++   " Active Banner support
++"   call Decho("active banner handling")
++   norm! 0
++   let dirname= "./"
++   let curline= getline(".")
++
++   if curline =~ '"\s*Sorted by\s'
++    norm s
++    let s:netrw_skipbrowse= 1
++    echo 'Pressing "s" also works'
++
++   elseif curline =~ '"\s*Sort sequence:'
++    let s:netrw_skipbrowse= 1
++    echo 'Press "S" to edit sorting sequence'
++
++   elseif curline =~ '"\s*Quick Help:'
++    norm ?
++    let s:netrw_skipbrowse= 1
++    echo 'Pressing "?" also works'
++
++   elseif curline =~ '"\s*\%(Hiding\|Showing\):'
++    norm a
++    let s:netrw_skipbrowse= 1
++    echo 'Pressing "a" also works'
++
++   elseif line("$") > w:netrw_bannercnt
++    exe 'silent keepjumps '.w:netrw_bannercnt
++   endif
++
++  elseif w:netrw_liststyle == s:THINLIST
++"   call Decho("thin column handling")
++   norm! 0
++   let dirname= getline(".")
++
++  elseif w:netrw_liststyle == s:LONGLIST
++"   call Decho("long column handling")
++   norm! 0
++   let dirname= substitute(getline("."),'^\(\%(\S\+ \)*\S\+\).\{-}$','\1','e')
++
++  elseif w:netrw_liststyle == s:TREELIST
++"   call Decho("treelist handling")
++   let dirname= substitute(getline("."),'^\(| \)*','','e')
++
++  else
++"   call Decho("obtain word from wide listing")
++   let dirname= getline(".")
++
++   if !exists("b:netrw_cpf")
++    let b:netrw_cpf= 0
++    exe 'silent keepjumps '.w:netrw_bannercnt.',$g/^./if virtcol("$") > b:netrw_cpf|let b:netrw_cpf= virtcol("$")|endif'
++"    call Decho("computed cpf")
++   endif
++
++"   call Decho("buf#".bufnr("%")."<".bufname("%").">")
++   let filestart = (virtcol(".")/b:netrw_cpf)*b:netrw_cpf
++"   call Decho("filestart= ([virtcol=".virtcol(".")."]/[b:netrw_cpf=".b:netrw_cpf."])*b:netrw_cpf=".filestart."  bannercnt=".w:netrw_bannercnt)
++"   call Decho("1: dirname<".dirname.">")
++   if filestart > 0|let dirname= substitute(dirname,'^.\{'.filestart.'}','','')|endif
++"   call Decho("2: dirname<".dirname.">")
++   let dirname   = substitute(dirname,'^\(.\{'.b:netrw_cpf.'}\).*$','\1','e')
++"   call Decho("3: dirname<".dirname.">")
++   let dirname   = substitute(dirname,'\s\+$','','e')
++"   call Decho("4: dirname<".dirname.">")
++  endif
++
++  " symlinks are indicated by a trailing "@".  Remove it before further processing.
++  let dirname= substitute(dirname,"@$","","")
++
++"  call Dret("NetrwGetWord <".dirname.">")
++  return dirname
++endfun
++
++" ---------------------------------------------------------------------
+ " s:NetrwListSettings: {{{2
+ fun! s:NetrwListSettings(islocal)
+ "  call Dfunc("s:NetrwListSettings(islocal=".a:islocal.")")
+@@ -1953,6 +2249,7 @@
+ "  call Dredir("ls!")
+ "  call Decho("exe setlocal ts=".g:netrw_maxfilenamelen)
+   exe "setlocal ts=".g:netrw_maxfilenamelen
++  setlocal isk+=.,~,-
+   if g:netrw_fastbrowse > a:islocal
+    setlocal bh=hide
+   else
+@@ -1966,20 +2263,22 @@
+ fun! s:PerformListing(islocal)
+ "  call Dfunc("s:PerformListing(islocal=".a:islocal.") buf(%)=".bufnr("%")."<".bufname("%").">")
+ 
+-"   if exists("g:netrw_silent") && g:netrw_silent == 0 && &ch >= 1	" Decho
+-"    call Decho("(netrw) Processing your browsing request...")
+-"   endif								" Decho
+-
+-"   call Decho('w:netrw_liststyle='.(exists("w:netrw_liststyle")? w:netrw_liststyle : 'n/a'))
+-   if exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST && exists("w:netrw_treedict")
+-    " force a refresh for tree listings
+-"    call Decho("force refresh for treelisting: clear buffer<".expand("%")."> with :%d")
+-    setlocal ma noro
+-    keepjumps %d
+-   endif
++  call s:NetrwSafeOptions()
++  setlocal noro ma
++
++"  if exists("g:netrw_silent") && g:netrw_silent == 0 && &ch >= 1	" Decho
++"   call Decho("(netrw) Processing your browsing request...")
++"  endif								" Decho
++
++"  call Decho('w:netrw_liststyle='.(exists("w:netrw_liststyle")? w:netrw_liststyle : 'n/a'))
++  if exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST && exists("w:netrw_treedict")
++   " force a refresh for tree listings
++"   call Decho("force refresh for treelisting: clear buffer<".expand("%")."> with :%d")
++   keepjumps %d
++  endif
+ 
+   " save current directory on directory history list
+-  call s:NetBookmarkDir(3,b:netrw_curdir)
++  call s:NetrwBookmarkDir(3,b:netrw_curdir)
+ 
+   " Set up the banner {{{3
+ "  call Decho("set up banner")
+@@ -1988,7 +2287,7 @@
+   keepjumps put ='\"   '.b:netrw_curdir
+   keepjumps 1d
+   let w:netrw_bannercnt= 3
+-  exe w:netrw_bannercnt
++  exe "keepjumps ".w:netrw_bannercnt
+ 
+   let sortby= g:netrw_sort_by
+   if g:netrw_sort_direction =~ "^r"
+@@ -2009,7 +2308,19 @@
+    keepjumps put ='\"   Sorted by '.sortby
+    let w:netrw_bannercnt= w:netrw_bannercnt + 1
+   endif
+-  exe w:netrw_bannercnt
++  exe "keepjumps ".w:netrw_bannercnt
++
++  " show copy/move target, if any
++  if exists("s:netrwmftgt") && exists("s:netrwmfloc")
++"   call Decho("show copy/move target<".s:netrwmftgt."> netrwmfloc=".s:netrwmfloc)
++   if s:netrwmfloc
++    keepjumps put ='\"   Copy/Move Tgt: '.s:netrwmftgt.' (local)'
++   else
++    keepjumps put ='\"   Copy/Move Tgt: '.s:netrwmftgt.' (remote)'
++   endif
++   let w:netrw_bannercnt= w:netrw_bannercnt + 1
++  endif
++  exe "keepjumps ".w:netrw_bannercnt
+ 
+   " Hiding...  -or-  Showing... {{{3
+ "  call Decho("handle hiding/showing (g:netrw_hide=".g:netrw_list_hide." g:netrw_list_hide<".g:netrw_list_hide.">)")
+@@ -2021,14 +2332,14 @@
+    endif
+    let w:netrw_bannercnt= w:netrw_bannercnt + 1
+   endif
+-  exe w:netrw_bannercnt
++  exe "keepjumps ".w:netrw_bannercnt
+   keepjumps put ='\"   Quick Help: <F1>:help  -:go up dir  D:delete  R:rename  s:sort-by  x:exec'
+   keepjumps put ='\" ============================================================================'
+   let w:netrw_bannercnt= w:netrw_bannercnt + 2
+ 
+   " bannercnt should index the line just after the banner
+   let w:netrw_bannercnt= w:netrw_bannercnt + 1
+-  exe w:netrw_bannercnt
++  exe "keepjumps ".w:netrw_bannercnt
+ "  call Decho("bannercnt=".w:netrw_bannercnt." (should index line just after banner) line($)=".line("$"))
+ 
+   " set up syntax highlighting {{{3
+@@ -2041,10 +2352,11 @@
+   endif
+ 
+   " get list of files
++"  call Decho("Get list of files - islocal=".a:islocal)
+   if a:islocal
+    call s:LocalListing()
+   else " remote
+-   call s:RemoteListing()
++   call s:NetrwRemoteListing()
+   endif
+ "  call Decho("w:netrw_bannercnt=".w:netrw_bannercnt." (banner complete)")
+ 
+@@ -2053,7 +2365,7 @@
+ "   call Decho("manipulate directory listing (hide)")
+ "   call Decho("g:netrw_hide=".g:netrw_hide." g:netrw_list_hide<".g:netrw_list_hide.">")
+    if g:netrw_hide && g:netrw_list_hide != ""
+-    call s:NetListHide()
++    call s:NetrwListHide()
+    endif
+    if line("$") >= w:netrw_bannercnt
+ "    call Decho("manipulate directory listing (sort) : g:netrw_sort_by<".g:netrw_sort_by.">")
+@@ -2098,13 +2410,13 @@
+ 
+   " convert to wide/tree listing {{{3
+ "  call Decho("modify display if wide/tree listing style")
+-  call s:NetWideListing()
+-  call s:NetTreeListing(b:netrw_curdir)
++  call s:NetrwWideListing()
++  call s:NetrwTreeListing(b:netrw_curdir)
+ 
+   if exists("w:netrw_bannercnt") && line("$") > w:netrw_bannercnt
+    " place cursor on the top-left corner of the file listing
+ "   call Decho("place cursor on top-left corner of file listing")
+-   exe 'silent '.w:netrw_bannercnt
++   exe 'silent keepjumps '.w:netrw_bannercnt
+    norm! 0
+   endif
+ 
+@@ -2114,7 +2426,7 @@
+ 
+   " save certain window-oriented variables into buffer-oriented variables {{{3
+   call s:SetBufWinVars()
+-  call s:NetOptionRestore()
++  call s:NetrwOptionRestore("w:")
+ 
+   " set display to netrw display settings
+ "  call Decho("set display to netrw display settings (noma nomod etc)")
+@@ -2128,22 +2440,27 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-"  s:NetBrowseChgDir: constructs a new directory based on the current {{{2
+-"                     directory and a new directory name
+-fun! s:NetBrowseChgDir(islocal,newdir,...)
+-"  call Dfunc("s:NetBrowseChgDir(islocal=".a:islocal."> newdir<".a:newdir.">) a:0=".a:0." curpos<".string(getpos("."))."> b:netrw_curdir<".(exists("b:netrw_curdir")? b:netrw_curdir : "").">")
++"  s:NetrwBrowseChgDir: constructs a new directory based on the current {{{2
++"                       directory and a new directory name.  Also, if the
++"                       "new directory name" is actually a file,
++"                       NetrwBrowseChgDir() edits the file.
++fun! s:NetrwBrowseChgDir(islocal,newdir,...)
++"  call Dfunc("s:NetrwBrowseChgDir(islocal=".a:islocal."> newdir<".a:newdir.">) a:0=".a:0." curpos<".string(getpos("."))."> b:netrw_curdir<".(exists("b:netrw_curdir")? b:netrw_curdir : "").">")
+ 
+   if !exists("b:netrw_curdir")
+-"   call Decho("(NetBrowseChgDir) b:netrw_curdir doesn't exist!")
+-   echoerr "(NetBrowseChgDir) b:netrw_curdir doesn't exist!"
+-"   call Dret("s:NetBrowseChgDir")
++"   call Decho("(NetrwBrowseChgDir) b:netrw_curdir doesn't exist!")
++   echoerr "(NetrwBrowseChgDir) b:netrw_curdir doesn't exist!"
++"   call Dret("s:NetrwBrowseChgDir")
+    return
+   endif
+ 
+-  call netrw#NetSavePosn()
++  call s:NetrwOptionSave("s:")
++  call s:NetrwSafeOptions()
++  call netrw#NetrwSavePosn()
+   let nbcd_curpos = getpos('.')
+   let dirname     = substitute(b:netrw_curdir,'\\','/','ge')
+   let newdir      = a:newdir
++  let dolockout   = 0
+ 
+   " set up o/s-dependent directory recognition pattern
+   if has("amiga")
+@@ -2155,16 +2472,18 @@
+ 
+   if dirname !~ dirpat
+    " apparently vim is "recognizing" that it is in a directory and
+-   " is removing the trailing "/".  Bad idea, so I have to put it back.
++   " is removing the trailing "/".  Bad idea, so I put it back.
+    let dirname= dirname.'/'
+ "   call Decho("adjusting dirname<".dirname.">")
+   endif
+ 
+   if newdir !~ dirpat
+-   " handling a file
++   " ------------
++   " edit a file:
++   " ------------
+ "   call Decho('case "handling a file": newdir<'.newdir.'> !~ dirpat<'.dirpat.">")
+    if exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST && exists("w:netrw_treedict") && newdir !~ '^\(/\|\a:\)'
+-    let dirname= s:NetTreeDir().newdir
++    let dirname= s:NetrwTreeDir().newdir
+ "    call Decho("tree listing")
+    elseif newdir =~ '^\(/\|\a:\)'
+     let dirname= newdir
+@@ -2172,10 +2491,11 @@
+     let dirname= s:ComposePath(dirname,newdir)
+    endif
+ "   call Decho("handling a file: dirname<".dirname."> (a:0=".a:0.")")
+-   " this lets NetBrowseX avoid the edit
++   " this lets NetrwBrowseX avoid the edit
+    if a:0 < 1
+-"    call Decho("dirname<".dirname."> netrw_cd_escape<".s:netrw_cd_escape."> browse_split=".g:netrw_browse_split)
+-"    call Decho("about to edit<".escape(dirname,s:netrw_cd_escape).">  didsplit=".(exists("s:didsplit")? s:didsplit : "doesn't exist"))
++"    call Decho("dirname<".dirname."> netrw_cd_escape<".g:netrw_cd_escape."> browse_split=".g:netrw_browse_split)
++"    call Decho("set up windows for editing<".escape(dirname,g:netrw_cd_escape).">  didsplit=".(exists("s:didsplit")? s:didsplit : "doesn't exist"))
++    call s:NetrwOptionRestore("s:")
+     if !exists("s:didsplit")
+      if     g:netrw_browse_split == 1
+       new
+@@ -2185,36 +2505,53 @@
+       wincmd |
+      elseif g:netrw_browse_split == 3
+       tabnew
++     elseif g:netrw_browse_split == 4
++      if s:NetrwPrevWinOpen(2) == 3
++"       call Dret("s:NetrwBrowseChgDir")
++       return
++      endif
+      else
+       " handling a file, didn't split, so remove menu
+ "      call Decho("handling a file+didn't split, so remove menu")
+-      call s:NetMenu(0)
++      call s:NetrwMenu(0)
+       " optional change to window
+-      if g:netrw_chgwin >= 1 
++      if g:netrw_chgwin >= 1
+        exe g:netrw_chgwin."wincmd w"
+       endif
+      endif
+     endif
+-    " edit the file
+-    " its local only: LocalBrowseCheck() doesn't edit a file, but NetBrowse() will
++    " the point where netrw actually edits the (local) file
++    " if its local only: LocalBrowseCheck() doesn't edit a file, but NetrwBrowse() will
+     if a:islocal
+-"     call Decho("edit file: exe e! ".escape(dirname,s:netrw_cd_escape))
+-     exe "e! ".escape(dirname,s:netrw_cd_escape)
++"     call Decho("edit local file: exe e! ".escape(dirname,g:netrw_cd_escape))
++     exe "e! ".escape(dirname,g:netrw_cd_escape)
++     let dolockout= 1
++    else
++"     call Decho("remote file: NetrwBrowse will edit it")
++     let dolockout= 1
+     endif
+-    setlocal ma nomod noro
+    endif
+ 
+   elseif newdir =~ '^/'
++   " ---------------------------------
+    " just go to the new directory spec
++   " ---------------------------------
+ "   call Decho('case "just go to new directory spec": newdir<'.newdir.'>')
+    let dirname= newdir
++   call s:SetRexDir(a:islocal,dirname)
++   call s:NetrwOptionRestore("s:")
+ 
+   elseif newdir == './'
++   " --------------------------
+    " refresh the directory list
++   " --------------------------
+ "   call Decho('case "refresh directory listing": newdir == "./"')
++   call s:SetRexDir(a:islocal,dirname)
+ 
+   elseif newdir == '../'
++   " -------------------
+    " go up one directory
++   " -------------------
+ "   call Decho('case "go up one directory": newdir == "../"')
+ 
+    if w:netrw_liststyle == s:TREELIST && exists("w:netrw_treedict")
+@@ -2248,16 +2585,17 @@
+     endif
+ "    call Decho("unix: dirname<".dirname."> (go up one dir)")
+    endif
++   call s:SetRexDir(a:islocal,dirname)
+ 
+-  elseif w:netrw_liststyle == s:TREELIST && exists("w:netrw_treedict")
++  elseif exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST && exists("w:netrw_treedict")
+ "   call Decho('case liststyle is TREELIST and w:netrw_treedict exists')
+-   " force a refresh (for TREELIST, wait for NetTreeDir() to force the refresh)
++   " force a refresh (for TREELIST, wait for NetrwTreeDir() to force the refresh)
+    setlocal noro ma
+    if !(exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST && exists("b:netrw_curdir"))
+ "    call Decho("clear buffer<".expand("%")."> with :%d")
+     keepjumps %d
+    endif
+-   let treedir      = s:NetTreeDir()
++   let treedir      = s:NetrwTreeDir()
+    let s:treecurpos = nbcd_curpos
+    let haskey= 0
+ "   call Decho("w:netrw_treedict<".string(w:netrw_treedict).">")
+@@ -2304,491 +2642,1000 @@
+     let dirname= substitute(treedir,'/*$','/','')
+ "    call Decho("go down one dir: treedir<".treedir.">")
+    endif
++   call s:SetRexDir(a:islocal,dirname)
+ 
+   else
+    " go down one directory
+    let dirname= s:ComposePath(dirname,newdir)
+ "   call Decho("go down one dir: dirname<".dirname."> newdir<".newdir.">")
++   call s:SetRexDir(a:islocal,dirname)
++  endif
++
++  call s:NetrwOptionRestore("s:")
++  if dolockout
++"   call Decho("doing modification lockout settings: ma nomod noro")
++   setlocal ma nomod noro
+   endif
+ 
+-"  call Dret("s:NetBrowseChgDir <".dirname."> : curpos<".string(getpos(".")).">")
++"  call Dret("s:NetrwBrowseChgDir <".dirname."> : curpos<".string(getpos(".")).">")
+   return dirname
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" s:NetHide: this function is invoked by the "a" map for browsing {{{2
+-"          and switches the hiding mode
+-fun! s:NetHide(islocal)
+-"  call Dfunc("NetHide(islocal=".a:islocal.")")
++" s:NetrwHide: this function is invoked by the "a" map for browsing {{{2
++"          and switches the hiding mode.  The actual hiding is done by
++"          s:NetrwListHide().
++"             g:netrw_hide= 0: show all
++"                           1: show not-hidden files
++"                           2: show hidden files only
++fun! s:NetrwHide(islocal)
++"  call Dfunc("NetrwHide(islocal=".a:islocal.") g:netrw_hide=".g:netrw_hide)
++  let svpos= netrw#NetrwSavePosn()
++
++  if exists("s:netrwmarkfilelist")
++"   call Decho(((g:netrw_hide == 1)? "unhide" : "hide")." files in markfilelist<".string(s:netrwmarkfilelist).">")
++"   call Decho("g:netrw_list_hide<".g:netrw_list_hide.">")
++
++   " hide the files in the markfile list
++   for fname in s:netrwmarkfilelist
++"    call Decho("match(g:netrw_list_hide<".g:netrw_list_hide.'> fname<\<'.fname.'\>>)='.match(g:netrw_list_hide,'\<'.fname.'\>')." isk=".&isk)
++    if match(g:netrw_list_hide,'\<'.fname.'\>') != -1
++     " remove fname from hiding list
++     let g:netrw_list_hide= substitute(g:netrw_list_hide,'..\<'.escape(fname,g:netrw_fname_escape).'\>..','','')
++     let g:netrw_list_hide= substitute(g:netrw_list_hide,',,',',','g')
++     let g:netrw_list_hide= substitute(g:netrw_list_hide,'^,\|,$','','')
++"     call Decho("unhide: g:netrw_list_hide<".g:netrw_list_hide.">")
++    else
++     " append fname to hiding list
++     if exists("g:netrw_list_hide") && g:netrw_list_hide != ""
++      let g:netrw_list_hide= g:netrw_list_hide.',\<'.escape(fname,g:netrw_fname_escape).'\>'
++     else
++      let g:netrw_list_hide= '\<'.escape(fname,g:netrw_fname_escape).'\>'
++     endif
++"     call Decho("hide: g:netrw_list_hide<".g:netrw_list_hide.">")
++    endif
++   endfor
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
++   let g:netrw_hide= 1
++
++  else
++
++   " switch between show-all/show-not-hidden/show-hidden
+    let g:netrw_hide=(g:netrw_hide+1)%3
+    exe "norm! 0"
+    if g:netrw_hide && g:netrw_list_hide == ""
+     call netrw#ErrorMsg(s:WARNING,"your hiding list is empty!",49)
+-"    call Dret("NetHide")
++"    call Dret("NetrwHide")
+     return
+    endif
+-   call netrw#NetSavePosn()
+-   call s:NetRefresh(a:islocal,s:NetBrowseChgDir(a:islocal,'./'))
+-"  call Dret("NetHide")
++  endif
++
++  call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++  call netrw#NetrwRestorePosn(svpos)
++"  call Dret("NetrwHide")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-
+-" ===========================================
+-" s:NetPreview: {{{2
+-fun! s:NetPreview(path) range
+-"  call Dfunc("NetPreview(path<".a:path.">)")
+-  if has("quickfix")
+-   if !isdirectory(a:path)
+-    exe "pedit ".escape(a:path,g:netrw_fname_escape)
+-   elseif !exists("g:netrw_quiet")
+-    call netrw#ErrorMsg(s:WARNING,"sorry, cannot preview a directory such as <".a:path.">",38)
++" s:NetrwLeftmouse: handles the <leftmouse> when in a netrw browsing window {{{2
++fun! s:NetrwLeftmouse(islocal)
++"  call Dfunc("s:NetrwLeftmouse(islocal=".a:islocal.")")
++  if a:islocal
++   if exists("b:netrw_curdir")
++    call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,s:NetrwGetWord()))
++   endif
++  else
++   if exists("b:netrw_curdir")
++    call s:NetrwBrowse(0,s:NetrwBrowseChgDir(0,s:NetrwGetWord()))
+    endif
+-  elseif !exists("g:netrw_quiet")
+-   call netrw#ErrorMsg(s:WARNING,"sorry, to preview your vim needs the quickfix feature compiled in",39)
+   endif
+-"  call Dret("NetPreview")
++"  call Dret("s:NetrwLeftmouse")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" s:NetSortStyle: change sorting style (name - time - size) and refresh display {{{2
+-fun! s:NetSortStyle(islocal)
+-"  call Dfunc("s:NetSortStyle(islocal=".a:islocal.") netrw_sort_by<".g:netrw_sort_by.">")
+-  call s:NetSaveWordPosn()
++" s:NetrwListHide: uses [range]g~...~d to delete files that match comma {{{2
++" separated patterns given in g:netrw_list_hide
++fun! s:NetrwListHide()
++"  call Dfunc("NetrwListHide() hide=".g:netrw_hide." listhide<".g:netrw_list_hide.">")
+ 
+-  let g:netrw_sort_by= (g:netrw_sort_by =~ 'n')? 'time' : (g:netrw_sort_by =~ 't')? 'size' : 'name'
+-  norm! 0
+-  call netrw#NetSavePosn()
+-  call s:NetRefresh(a:islocal,s:NetBrowseChgDir(a:islocal,'./'))
++  " find a character not in the "hide" string to use as a separator for :g and :v commands
++  " How-it-works: take the hiding command, convert it into a range.  Duplicate
++  " characters don't matter.  Remove all such characters from the '/~...90'
++  " string.  Use the first character left as a separator character.
++  let listhide= g:netrw_list_hide
++  let sep     = strpart(substitute('/~@#$%^&*{};:,<.>?|1234567890','['.escape(listhide,'-]^\').']','','ge'),1,1)
++"  call Decho("sep=".sep)
++
++  while listhide != ""
++   if listhide =~ ','
++    let hide     = substitute(listhide,',.*$','','e')
++    let listhide = substitute(listhide,'^.\{-},\(.*\)$','\1','e')
++   else
++    let hide     = listhide
++    let listhide = ""
++   endif
++
++   " Prune the list by hiding any files which match
++   if g:netrw_hide == 1
++"    call Decho("hiding<".hide."> listhide<".listhide.">")
++    exe 'silent keepjumps '.w:netrw_bannercnt.',$g'.sep.hide.sep.'d'
++   elseif g:netrw_hide == 2
++"    call Decho("showing<".hide."> listhide<".listhide.">")
++    exe 'silent keepjumps '.w:netrw_bannercnt.',$g'.sep.hide.sep.'s@^@ /-KEEP-/ @'
++   endif
++  endwhile
++  if g:netrw_hide == 2
++   exe 'silent keepjumps '.w:netrw_bannercnt.',$v@^ /-KEEP-/ @d'
++   exe 'silent keepjumps '.w:netrw_bannercnt.',$s@^\%( /-KEEP-/ \)\+@@e'
++  endif
+ 
+-"  call Dret("s:NetSortStyle : netrw_sort_by<".g:netrw_sort_by.">")
++"  call Dret("NetrwListHide")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-"  Remote Directory Browsing Support:    {{{1
+-" ===========================================
++" NetrwHideEdit: allows user to edit the file/directory hiding list
++fun! s:NetrwHideEdit(islocal)
++"  call Dfunc("NetrwHideEdit(islocal=".a:islocal.")")
+ 
+-" ---------------------------------------------------------------------
+-" s:RemoteListing: {{{2
+-fun! s:RemoteListing()
+-"  call Dfunc("s:RemoteListing() b:netrw_curdir<".b:netrw_curdir.">)")
++  " save current cursor position
++  let svpos= netrw#NetrwSavePosn()
+ 
+-  call s:RemotePathAnalysis(b:netrw_curdir)
++  " get new hiding list from user
++  call inputsave()
++  let newhide= input("Edit Hiding List: ",g:netrw_list_hide)
++  call inputrestore()
++  let g:netrw_list_hide= newhide
++"  call Decho("new g:netrw_list_hide<".g:netrw_list_hide.">")
+ 
+-  " sanity check:
+-  if exists("b:netrw_method") && b:netrw_method =~ '[235]'
+-"   call Decho("b:netrw_method=".b:netrw_method)
+-   if !executable("ftp")
+-    if !exists("g:netrw_quiet")
+-     call netrw#ErrorMsg(s:ERROR,"this system doesn't support remote directory listing via ftp",18)
+-    endif
+-    call s:NetOptionRestore()
+-"    call Dret("s:RemoteListing")
+-    return
+-   endif
++  " refresh the listing
++  silent call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,"./"))
+ 
+-  elseif !exists("g:netrw_list_cmd") || g:netrw_list_cmd == ''
+-   if !exists("g:netrw_quiet")
+-    if g:netrw_list_cmd == ""
+-     call netrw#ErrorMsg(s:ERROR,g:netrw_ssh_cmd." is not executable on your system",47)
++  " restore cursor position
++  call netrw#NetrwRestorePosn(svpos)
++
++"  call Dret("NetrwHideEdit")
++endfun
++
++" ---------------------------------------------------------------------
++" NetSortSequence: allows user to edit the sorting sequence
++fun! s:NetSortSequence(islocal)
++"  call Dfunc("NetSortSequence(islocal=".a:islocal.")")
++
++  let svpos= netrw#NetrwSavePosn()
++  call inputsave()
++  let newsortseq= input("Edit Sorting Sequence: ",g:netrw_sort_sequence)
++  call inputrestore()
++
++  " refresh the listing
++  let g:netrw_sort_sequence= newsortseq
++  call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++  call netrw#NetrwRestorePosn(svpos)
++
++"  call Dret("NetSortSequence")
++endfun
++
++" ---------------------------------------------------------------------
++" s:NetrwMarkFile: (invoked by mf) This function is used to both {{{2
++"                  mark and unmark files.  If a markfile list exists,
++"                  then the rename and delete functions will use it instead
++"                  of whatever may happen to be under the cursor at that
++"                  moment.  When the mouse and gui are available,
++"                  shift-leftmouse may also be used to mark files.
++fun! s:NetrwMarkFile(islocal,fname)
++"  call Dfunc("s:NetrwMarkFile(islocal=".a:islocal." fname<".a:fname.">)")
++"  call Decho("b:netrw_curdir<".b:netrw_curdir.">")
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
++
++  if exists("s:netrwmarkfilelist")
++"   call Decho("starting s:netrwmarkfilelist<".string(s:netrwmarkfilelist).">")
++"   call Decho("starting s:netrwmarkfilemtch<".s:netrwmarkfilemtch.">")
++
++   if index(s:netrwmarkfilelist,a:fname) == -1
++    " append filename to list
++"    call Decho("append filename<".a:fname."> to markfilelist<".string(s:netrwmarkfilelist).">")
++    call add(s:netrwmarkfilelist,a:fname)
++    let s:netrwmarkfilemtch= s:netrwmarkfilemtch.'\|\<'.escape(a:fname,'*./[\').'\>'
++   else
++    " remove filename from list
++"    call Decho("remove filename<".a:fname."> from markfilelist<".string(s:netrwmarkfilelist).">")
++    call filter(s:netrwmarkfilelist,'v:val != a:fname')
++    if s:netrwmarkfilelist == []
++     unlet s:netrwmarkfilelist
++     unlet s:netrwmarkfilemtch
+     else
+-     call netrw#ErrorMsg(s:ERROR,"this system doesn't support remote directory listing via ".g:netrw_list_cmd,19)
++     let s:netrwmarkfilemtch= substitute(s:netrwmarkfilemtch,'\\<'.a:fname.'\\>','','')
++     let s:netrwmarkfilemtch= substitute(s:netrwmarkfilemtch,'\\|\\|','\\|','g')
++     let s:netrwmarkfilemtch= substitute(s:netrwmarkfilemtch,'^\\|\|\\|$','','')
++"     call Decho("ending s:netrwmarkfilelist<".string(s:netrwmarkfilelist).">")
++"     call Decho("ending s:netrwmarkfilemtch<".s:netrwmarkfilemtch.">")
+     endif
+    endif
+ 
+-   call s:NetOptionRestore()
+-"   call Dret("s:RemoteListing")
+-   return
+-  endif  " (remote handling sanity check)
++  else
+ 
+-  if exists("b:netrw_method")
+-"   call Decho("setting w:netrw_method<".b:netrw_method.">")
+-   let w:netrw_method= b:netrw_method
+-  endif
++"   call Decho("add fname<".a:fname."> to new markfilelist")
++   let s:netrwmarkfilelist= []
++   call add(s:netrwmarkfilelist,a:fname)
++"   call Decho("ending s:netrwmarkfilelist<".string(s:netrwmarkfilelist).">")
+ 
+-  if s:method == "ftp"
+-   " use ftp to get remote file listing
+-"   call Decho("use ftp to get remote file listing")
+-   let s:method  = "ftp"
+-   let listcmd = g:netrw_ftp_list_cmd
+-   if g:netrw_sort_by =~ '^t'
+-    let listcmd= g:netrw_ftp_timelist_cmd
+-   elseif g:netrw_sort_by =~ '^s'
+-    let listcmd= g:netrw_ftp_sizelist_cmd
++   if a:fname =~ '/$'
++    let s:netrwmarkfilemtch= '\<'.escape(a:fname,'*./[\')
++   else
++    let s:netrwmarkfilemtch= '\<'.escape(a:fname,'*./[\').'\>'
+    endif
+-"   call Decho("listcmd<".listcmd."> (using g:netrw_ftp_list_cmd)")
+-   call s:NetBrowseFtpCmd(s:path,listcmd)
+-"   exe "keepjumps ".w:netrw_bannercnt.',$g/^./call Decho("raw listing: ".getline("."))'
++"   call Decho("ending s:netrwmarkfilemtch<".s:netrwmarkfilemtch.">")
++  endif
+ 
+-   if w:netrw_liststyle == s:THINLIST || w:netrw_liststyle == s:WIDELIST || w:netrw_liststyle == s:TREELIST
+-    " shorten the listing
+-"    call Decho("generate short listing")
+-    exe "keepjumps ".w:netrw_bannercnt
++  if exists("s:netrwmarkfilemtch") && s:netrwmarkfilemtch != ""
++"   call Decho("exe 2match netrwMarkFile /".s:netrwmarkfilemtch."/")
++   exe "2match netrwMarkFile /".s:netrwmarkfilemtch."/"
++  else
++"   call Decho("2match none")
++   2match none
++  endif
++"  call Dret("s:NetrwMarkFile : netrwmarkfilelist".(exists("s:netrwmarkfilelist")? string(s:netrwmarkfilelist) : " doesn't exist"))
++endfun
+ 
+-    " cleanup
+-    if g:netrw_ftp_browse_reject != ""
+-     exe "silent! g/".g:netrw_ftp_browse_reject."/keepjumps d"
+-    endif
+-    silent! keepjumps %s/\r$//e
++" ---------------------------------------------------------------------
++" s:NetrwMarkFileCompress: (invoked by mz) This function is used to {{{2
++"                          compress/decompress files using the programs
++"                          in g:netrw_compress and g:netrw_uncompress,
++"                          using g:netrw_compress_suffix to know which to
++"                          do.  By default:
++"                            g:netrw_compress        = "gzip"
++"                            g:netrw_decompress      = { ".gz" : "gunzip" , ".bz2" : "bunzip2" , ".zip" : "unzip" , ".tar" : "tar -xf"}
++fun! s:NetrwMarkFileCompress(islocal)
++"  call Dfunc("s:NetrwMarkFileCompress(islocal=".a:islocal.")")
++  let svpos= netrw#NetrwSavePosn()
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
+ 
+-    " if there's no ../ listed, then put ./ and ../ in
+-    let line1= line(".")
+-    exe "keepjumps ".w:netrw_bannercnt
+-    let line2= search('^\.\.\/\%(\s\|$\)','cnW')
+-    if line2 == 0
+-"     call Decho("netrw is putting ./ and ../ into listing")
+-     keepjumps put='../'
+-     keepjumps put='./'
++  if exists("s:netrwmarkfilelist") && exists("g:netrw_compress") && exists("g:netrw_decompress")
++   for fname in s:netrwmarkfilelist
++    " for every filename in the marked list
++    for sfx in sort(keys(g:netrw_decompress))
++     if fname =~ '\'.sfx.'$'
++      " fname has a suffix indicating that its compressed; apply associated decompression routine
++      let exe= g:netrw_decompress[sfx]
++"      call Decho("fname<".fname."> is compressed so decompress with <".exe.">")
++      if executable(exe)
++       if a:islocal
++        call system(exe." ".fname)
++       else
++        call s:RemoteSystem(exe." ".fname)
++       endif
++      else
++       call netrw#ErrorMsg(s:WARNING,"unable to apply<".exe."> to file<".fname.">",50)
++      endif
++      break
++     endif
++    endfor
++    if exists("exe")
++     unlet exe
++    elseif a:islocal
++     " fname not a compressed file, so compress it
++     call system(g:netrw_compress." ".fname)
++    else
++     " fname not a compressed file, so compress it
++     call s:RemoteSystem(g:netrw_compress." ".fname)
+     endif
+-    exe "keepjumps ".line1
+-    keepjumps norm! 0
++   endfor
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
++   call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++   call netrw#NetrwRestorePosn(svpos)
++  endif
++"  call Dret("s:NetrwMarkFileCompress")
++endfun
+ 
+-"    call Decho("line1=".line1." line2=".line2." line(.)=".line("."))
+-    if search('^\d\{2}-\d\{2}-\d\{2}\s','n') " M$ ftp site cleanup
+-"     call Decho("M$ ftp cleanup")
+-     exe 'silent! keepjumps '.w:netrw_bannercnt.',$s/^\d\{2}-\d\{2}-\d\{2}\s\+\d\+:\d\+[AaPp][Mm]\s\+\%(<DIR>\|\d\+\)\s\+//'
+-    else " normal ftp cleanup
+-"     call Decho("normal ftp cleanup")
+-     exe 'silent! keepjumps '.w:netrw_bannercnt.',$s/^\(\%(\S\+\s\+\)\{7}\S\+\)\s\+\(\S.*\)$/\2/e'
+-     exe "silent! keepjumps ".w:netrw_bannercnt.',$g/ -> /s# -> .*/$#/#e'
+-     exe "silent! keepjumps ".w:netrw_bannercnt.',$g/ -> /s# -> .*$#/#e'
++" ---------------------------------------------------------------------
++" s:NetrwMarkFileCopy: (invoked by mc) copy marked files to target {{{2
++"                      If no marked files, then set up directory as the
++"                      target.  Currently does not support copying entire
++"                      directories.
++"                      Returns 1=success  (used by NetrwMarkFileMove())
++"                              0=failure
++fun! s:NetrwMarkFileCopy(islocal)
++"  call Dfunc("s:NetrwMarkFileCopy(islocal=".a:islocal.") target<".(exists("s:netrwmftgt")? s:netrwmftgt : '---').">")
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
++
++  " s:netrwmarkfilelist: the List of marked files
++  if exists("s:netrwmarkfilelist")
++"   call Decho("s:netrwmarkfilelist<".string(s:netrwmarkfilelist).">")
++"   call Decho("s:netrwmarkfilemtch<".string(s:netrwmarkfilemtch).">")
++   let svpos= netrw#NetrwSavePosn()
++
++   " s:netrwmftgt : name of directory to copy files to
++   " s:netrwmfloc : =0 target directory is remote
++   "                =1 target directory is local
++   if exists("s:netrwmftgt") && exists("s:netrwmfloc")
++"    call Decho("s:netrwmftgt<".s:netrwmftgt.">")
++"    call Decho("s:netrwmfloc=".s:netrwmfloc)
++
++    for fname in s:netrwmarkfilelist
++"     call Decho("s:NetrwMarkFileCopy: fname<".fname.">")
++
++     " sanity check
++     if (a:islocal && isdirectory(fname)) || (!a:islocal && fname =~ '/$')
++      call netrw#ErrorMsg(s:ERROR,"currently netrw can't copy entire directories such as <".fname.">",58)
++"      call Dret("s:NetrwMarkFileCopy 0 : currently netrw can't copy entire directories")
++      return 0
++     endif
++
++     if  a:islocal &&  s:netrwmfloc
++      " local to local copy
++"      call Decho("local to local copy: getcwd<".getcwd()."> b:netrw_curdir<".b:netrw_curdir.">")
++      if executable(g:netrw_localcopycmd)
++"       call Decho("let ret= system(".g:netrw_localcopycmd." ".fname." ".s:netrwmftgt.")")
++       let ret= system(g:netrw_localcopycmd." ".fname." ".s:netrwmftgt)
++       if v:shell_error < 0
++	call netrw#ErrorMsg(s:ERROR,"command<".g:netrw_localcopycmd."> failed, aborting",54)
++        break
++       endif
++      else
++       call netrw#ErrorMsg(s:ERROR,"command<".g:netrw_localcopycmd."> is not executable!",57)
++       break
++      endif
++
++     elseif !a:islocal &&  s:netrwmfloc
++      " remote to local copy
++"      call Decho("remote to local copy: getcwd<".getcwd()."> b:netrw_curdir<".b:netrw_curdir.">")
++      call netrw#NetrwObtain(a:islocal,fname,s:netrwmftgt)
++
++     elseif  a:islocal && !s:netrwmfloc
++      " local to remote copy
++"      call Decho("local to remote copy: getcwd<".getcwd()."> b:netrw_curdir<".b:netrw_curdir.">")
++      call s:NetrwUpload(fname,s:netrwmftgt)
++
++     else
++      " remote to remote copy
++"      call Decho("remote to remote copy")
++      call s:NetrwUpload(fname,s:netrwmftgt)
++     endif
++    endfor
++
++    " unmark marked file list (although I expect s:NetrwUpload()
++    " to do it, I'm just making sure)
++    if exists("s:netrwmarkfilelist")
++     unlet s:netrwmarkfilelist
++     unlet s:netrwmarkfilemtch
++     2match none
+     endif
++   else
++    call netrw#ErrorMsg(s:ERROR,"missing a markfile copy target! (see help for netrw-mt)",56)
+    endif
+ 
++   " refresh the listing
++   call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++   call netrw#NetrwRestorePosn(svpos)
+   else
+-   " use ssh to get remote file listing {{{3
+-"   call Decho("use ssh to get remote file listing: s:netrw_shq<".g:netrw_shq."> s:path<".s:path."> s:netrw_cd_escape<".s:netrw_cd_escape.">")
+-   let listcmd= s:MakeSshCmd(g:netrw_list_cmd)
+-"   call Decho("listcmd<".listcmd."> (using g:netrw_list_cmd)")
+-   if g:netrw_scp_cmd =~ '^pscp'
+-"    call Decho("1: exe silent r! ".listcmd.g:netrw_shq.s:path.g:netrw_shq)
+-    exe "silent r! ".listcmd.g:netrw_shq.s:path.g:netrw_shq
+-    " remove rubbish and adjust listing format of 'pscp' to 'ssh ls -FLa' like
+-    g/^Listing directory/d
+-    g/^d[-rwx][-rwx][-rwx]/s+$+/+e
+-    silent g/^l[-rwx][-rwx][-rwx]/s+$+ at +e
+-    if g:netrw_liststyle != s:LONGLIST 
+-     g/^[dlsp-][-rwx][-rwx][-rwx]/s/^.*\s\(\S\+\)$/\1/e
++   call netrw#ErrorMsg(s:ERROR,"no files marked!",59)
++  endif
++  
++"  call Dret("s:NetrwMarkFileCopy 1")
++  return 1
++endfun
++
++" ---------------------------------------------------------------------
++" s:NetrwMarkFileDiff: (invoked by md) This function is used to {{{2
++"                      invoke vim's diff mode on the marked files.
++"                      Either two or three files can be so handled.
++fun! s:NetrwMarkFileDiff(islocal)
++"  call Dfunc("s:NetrwMarkFileDiff(islocal=".a:islocal.") b:netrw_curdir<".b:netrw_curdir.">")
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
++  if exists("s:netrwmarkfilelist")
++   let curdir= b:netrw_curdir
++
++   let cnt= 0
++   for fname in s:netrwmarkfilelist
++    let cnt= cnt + 1
++    if !a:islocal
++     let fname= curdir.fname
+     endif
+-   else
+-    if s:path == ""
+-"     call Decho("2: exe silent r! ".listcmd)
+-     exe "silent r! ".listcmd
++    if cnt == 1
++"     call Decho("diffthis: ".fname)
++     exe "e ".fname
++     diffthis
++    elseif cnt == 2 || cnt == 3
++     vsplit
++     wincmd l
++"     call Decho("diffthis: ".fname)
++     exe "e ".fname
++     diffthis
+     else
+-"     call Decho("3: exe silent r! ".listcmd." ".g:netrw_shq.s:path.g:netrw_shq)
+-     exe "silent r! ".listcmd." ".g:netrw_shq.s:path.g:netrw_shq
++     break
+     endif
+-   endif
++   endfor
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
++  endif
++"  call Dret("s:NetrwMarkFileDiff")
++endfun
+ 
+-   " cleanup
+-   if g:netrw_ftp_browse_reject != ""
+-"    call Decho("(cleanup) exe silent! g/".g:netrw_ssh_browse_reject."/keepjumps d")
+-    exe "silent! g/".g:netrw_ssh_browse_reject."/keepjumps d"
+-   endif
++" ---------------------------------------------------------------------
++" s:NetrwMarkFileEdit: (invoked by me) put marked files on arg list and start editing them {{{2
++fun! s:NetrwMarkFileEdit(islocal)
++"  call Dfunc("s:NetrwMarkFileEdit(islocal=".a:islocal.")")
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
+   endif
+ 
+-  if w:netrw_liststyle == s:LONGLIST
+-   " do a long listing; these substitutions need to be done prior to sorting {{{3
+-"   call Decho("fix long listing:")
++  if exists("s:netrwmarkfilelist")
++   call s:SetRexDir(a:islocal,b:netrw_curdir)
++   let flist= substitute(escape(join(s:netrwmarkfilelist,"\t"),' '),"\t",' ','g')
++   " unmark marked file list
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
++"   call Decho("exe silent args ".flist)
++   exe "silent args ".flist
++  endif
++  
++"  call Dret("s:NetrwMarkFileEdit")
++endfun
+ 
+-   if s:method == "ftp"
+-    " cleanup
+-    exe "keepjumps ".w:netrw_bannercnt
+-    while getline(".") =~ g:netrw_ftp_browse_reject
+-     keepjumps d
+-    endwhile
+-    " if there's no ../ listed, then put ./ and ../ in
+-    let line1= line(".")
+-    keepjumps 1
+-    silent keepjumps call search('^\.\.\/\%(\s\|$\)','W')
+-    let line2= line(".")
+-    if line2 == 0
+-     exe 'keepjumps '.w:netrw_bannercnt."put='./'"
+-     if b:netrw_curdir != '/'
+-      exe 'keepjumps '.w:netrw_bannercnt."put='../'"
+-     endif
++" ---------------------------------------------------------------------
++" s:NetrwMarkFileExe: (invoked by mx) execute arbitrary command on marked files, one at a time {{{2
++fun! s:NetrwMarkFileExe(islocal)
++"  call Dfunc("s:NetrwMarkFileExe(islocal=".a:islocal.")")
++  let svpos= netrw#NetrwSavePosn()
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
++
++  if exists("s:netrwmarkfilelist")
++   " get the command
++   call inputsave()
++   let cmd= input("Enter command: ","","file")
++   call inputrestore()
++"   call Decho("cmd<".cmd.">")
++
++   " apply command to marked files.  Substitute: filename -> %
++   " If no %, then append a space and the filename to the command
++   for fname in s:netrwmarkfilelist
++    if cmd =~ '%'
++     let xcmd= substitute(cmd,'%',fname,'g')
++    else
++     let xcmd= cmd.' '.fname
+     endif
+-   exe "keepjumps ".line1
+-   keepjumps norm! 0
+-   endif
++    if a:islocal
++"     call Decho("local: xcmd<".xcmd.">")
++     let ret= system(xcmd)
++    else
++"     call Decho("remote: xcmd<".xcmd.">")
++     let ret= s:RemoteSystem(xcmd)
++    endif
++    if v:shell_error < 0
++     call netrw#ErrorMsg(s:ERROR,"command<".xcmd."> failed, aborting",54)
++     break
++    else
++     echo ret
++    endif
++   endfor
+ 
+-   if search('^\d\{2}-\d\{2}-\d\{2}\s','n') " M$ ftp site cleanup
+-"    call Decho("M$ ftp site listing cleanup")
+-    exe 'silent! keepjumps '.w:netrw_bannercnt.',$s/^\(\d\{2}-\d\{2}-\d\{2}\s\+\d\+:\d\+[AaPp][Mm]\s\+\%(<DIR>\|\d\+\)\s\+\)\(\w.*\)$/\2\t\1/'
+-   elseif exists("w:netrw_bannercnt") && w:netrw_bannercnt <= line("$")
+-"    call Decho("normal ftp site listing cleanup: bannercnt=".w:netrw_bannercnt." line($)=".line("$"))
+-    exe 'silent keepjumps '.w:netrw_bannercnt.',$s/ -> .*$//e'
+-    exe 'silent keepjumps '.w:netrw_bannercnt.',$s/^\(\%(\S\+\s\+\)\{7}\S\+\)\s\+\(\S.*\)$/\2\t\1/e'
+-    exe 'silent keepjumps '.w:netrw_bannercnt
+-   endif
++   " unmark marked file list
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
++
++   " refresh the listing
++   call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++   call netrw#NetrwRestorePosn(svpos)
++  endif
++  
++"  call Dret("s:NetrwMarkFileExe")
++endfun
++
++" ---------------------------------------------------------------------
++" s:NetrwMarkFileMove: (invoked by mm) execute arbitrary command on marked files, one at a time {{{2
++fun! s:NetrwMarkFileMove(islocal)
++"  call Dfunc("s:NetrwMarkFileMove(islocal=".a:islocal.")")
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
++
++  if exists("s:netrwmarkfilelist")
++   let svpos= netrw#NetrwSavePosn()
++   if exists("s:netrwmftgt") && exists("s:netrwmfloc")
++
++    if  a:islocal &&  s:netrwmfloc
++     " local to local move
++      if executable(g:netrw_localmovecmd)
++"       call Decho("let ret= system(".g:netrw_localmovecmd." ".fname." ".s:netrwmftgt.")")
++       let ret= system(g:netrw_localmovecmd." ".fname." ".s:netrwmftgt)
++       if v:shell_error < 0
++	call netrw#ErrorMsg(s:ERROR,"command<".g:netrw_localmovecmd."> failed, aborting",54)
++        break
++       endif
++      else
++       call netrw#ErrorMsg(s:ERROR,"command<".g:netrw_localmovecmd."> is not executable!",57)
++       break
++      endif
++    else
++      " remote to local move
++      " local to remote move
++      " remote to remote move
++      let netrwmflist = s:netrwmflist
++      let netrwmfmtch = s:netrwmfmtch
++      if s:NetrwMarkFileCopy(islocal)
++       let s:netrwmflist= netrwmflist
++       let s:netrwmfmtch= netrwmfmtch
++       if a:islocal
++        call s:NetrwLocalRm("---")
++       else
++        call s:NetrwRemoteRm("---","---")
++       endif
++      endif
++    endif
++
++   " First, do a copy, then (attempt to) do a delete
++
++   call netrw#NetrwRestorePosn(svpos)
+   endif
++  
++"  call Dret("s:NetrwMarkFileMove")
++endfun
+ 
+-"  if exists("w:netrw_bannercnt") && w:netrw_bannercnt <= line("$") " Decho
+-"   exe "keepjumps ".w:netrw_bannercnt.',$g/^./call Decho("listing: ".getline("."))'
+-"  endif " Decho
+-"  call Dret("s:RemoteListing")
++" ---------------------------------------------------------------------
++" s:NetrwMarkFilePrint: (invoked by mp) This function prints marked files {{{2
++"                       using the hardcopy command
++fun! s:NetrwMarkFilePrint(islocal)
++"  call Dfunc("s:NetrwMarkFilePrint(islocal=".a:islocal.")")
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
++  if exists("s:netrwmarkfilelist")
++   let netrwmarkfilelist= s:netrwmarkfilelist
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   for fname in netrwmarkfilelist
++    1split
++    exe "silent e ".fname
++"    call Decho("hardcopy ".fname)
++    hardcopy
++    q
++   endfor
++   2match none
++  endif
++"  call Dret("s:NetrwMarkFilePrint")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-"  NetGetWord: it gets the directory named under the cursor {{{2
+-fun! s:NetGetWord()
+-"  call Dfunc("NetGetWord() line#".line(".")." liststyle=".g:netrw_liststyle." virtcol=".virtcol("."))
+-  call s:UseBufWinVars()
+ 
+-  " insure that w:netrw_liststyle is set up
+-  if !exists("w:netrw_liststyle")
+-   if exists("g:netrw_liststyle")
+-    let w:netrw_liststyle= g:netrw_liststyle
++" ===========================================
++" s:NetrwMarkFileRegexp: (invoked by mr) This function is used to mark {{{2
++"                        files when given a regexp (for which a prompt is
++"                        issued).
++fun! s:NetrwMarkFileRegexp(islocal)
++"  call Dfunc("s:NetrwMarkFileRegexp(islocal=".a:islocal.")")
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
++
++  " get the regular expression
++  call inputsave()
++  let regexp= input("Enter regexp: ","","file")
++  call inputrestore()
++
++  if a:islocal
++   " get the matching list of files using local glob()
++   let dirname    = escape(b:netrw_curdir,s:netrw_glob_escape)
++   let filelist   = glob(s:ComposePath(dirname,regexp))
++   if filelist != ""
++    let filelist= filelist."\n"
++   endif
++
++  " mark the list of files
++  while filelist != ""
++   if filelist =~ '\n'
++    let filename = substitute(filelist,'\n.*$','','e')
++    let filelist = substitute(filelist,'^.\{-}\n\(.*\)$','\1','e')
+    else
+-    let w:netrw_liststyle= s:THINLIST
++    let filename = filelist
++    let filelist = ""
+    endif
+-"   call Decho("w:netrw_liststyle=".w:netrw_liststyle)
+-  endif
++"   call Decho("filelist<".filelist.">")
++"   call Decho("filename<".filename.">")
++   call s:NetrwMarkFile(a:islocal,substitute(filename,'^.*/','',''))
++  endwhile
+ 
+-  if exists("w:netrw_bannercnt") && line(".") < w:netrw_bannercnt
+-   " Active Banner support
+-"   call Decho("active banner handling")
+-   norm! 0
+-   let dirname= "./"
+-   let curline= getline(".")
++  else
+ 
+-   if curline =~ '"\s*Sorted by\s'
+-    norm s
+-    let s:netrw_skipbrowse= 1
+-    echo 'Pressing "s" also works'
++   " convert displayed listing into a filelist
++   let eikeep = &ei
++   let areg   = @a
++   silent %y a
++   set ei=all ma
++   1split
++   enew
++   silent norm! "ap
++   2
++   let bannercnt= search('^" =====','W')
++   exe "silent 1,".bannercnt."d"
++   set bt=nofile
++   if     g:netrw_liststyle == s:LONGLIST
++    silent %s/\s\{2,}\S.*$//e
++   elseif g:netrw_liststyle == s:WIDELIST
++    silent %s/\s\{2,}/\r/ge
++   elseif g:netrw_liststyle == s:TREELIST
++    silent %s/^| //e
++    silent! g/^ .*$/d
++   endif
++   exe "silent! v/".escape(regexp,'/')."/d"
++   let filelist= getline(1,line("$"))
++   q!
++   for filename in filelist
++    call s:NetrwMarkFile(a:islocal,substitute(filename,'^.*/','',''))
++   endfor
++   unlet filelist
++   let @a  = areg
++   let &ei = eikeep
++  endif
+ 
+-   elseif curline =~ '"\s*Sort sequence:'
+-    let s:netrw_skipbrowse= 1
+-    echo 'Press "S" to edit sorting sequence'
++"  call Dret("s:NetrwMarkFileRegexp")
++endfun
+ 
+-   elseif curline =~ '"\s*Quick Help:'
+-    norm ?
+-    let s:netrw_skipbrowse= 1
+-    echo 'Pressing "?" also works'
++" ---------------------------------------------------------------------
++" s:NetrwMarkFileTag: (invoked by mt) This function applies {{{2
++"                     g:netrw_ctags to marked files
++fun! s:NetrwMarkFileTag(islocal)
++"  call Dfunc("s:NetrwMarkFileTag(islocal=".a:islocal.")")
++  let svpos= netrw#NetrwSavePosn()
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
+ 
+-   elseif curline =~ '"\s*\%(Hiding\|Showing\):'
+-    norm a
+-    let s:netrw_skipbrowse= 1
+-    echo 'Pressing "a" also works'
++  if exists("s:netrwmarkfilelist")
++"   call Decho("s:netrwmarkfilelist<".string(s:netrwmarkfilelist).">")
++   let netrwmarkfilelist= string(s:netrwmarkfilelist)
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   let netrwmarkfilelist= substitute(netrwmarkfilelist,'[[\],]','','g')
++"   call Decho("netrwmarkfilelist<".netrwmarkfilelist.">")
+ 
+-   elseif line("$") > w:netrw_bannercnt
+-    exe 'silent keepjumps '.w:netrw_bannercnt
++   if a:islocal
++    if executable(g:netrw_ctags)
++     if g:netrw_shq != "'"
++      let netrwmarkfilelist= substitute(netrwmarkfilelist,"'",g:netrw_shq,'g')
++     endif
++"     call Decho("call system(".g:netrw_ctags." ".netrwmarkfilelist.")")
++     call system(g:netrw_ctags." ".netrwmarkfilelist)
++    else
++     call netrw#ErrorMsg(s:ERROR,"g:netrw_ctags<".g:netrw_ctags."> is not executable!",51)
++    endif
++   else
++    let cmd= s:RemoteSystem(g:netrw_ctags." ".netrwmarkfilelist)
++    call netrw#NetrwObtain(a:islocal,"tags")
++    let curdir= b:netrw_curdir
++    1split
++    e tags
++    let path= substitute(curdir,'^\(.*\)/[^/]*$','\1/','')
++"    call Decho("curdir<".curdir."> path<".path.">")
++    exe '%s/\t\(\S\+\)\t/\t'.escape(path,'/').'\1\t/e'
++    wq!
+    endif
++   2match none
++   call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++   call netrw#NetrwRestorePosn(svpos)
++  endif
+ 
+-  elseif w:netrw_liststyle == s:THINLIST
+-"   call Decho("thin column handling")
+-   norm! 0
+-   let dirname= getline(".")
+-
+-  elseif w:netrw_liststyle == s:LONGLIST
+-"   call Decho("long column handling")
+-   norm! 0
+-   let dirname= substitute(getline("."),'^\(\%(\S\+ \)*\S\+\).\{-}$','\1','e')
++"  call Dret("s:NetrwMarkFileTag")
++endfun
+ 
+-  elseif w:netrw_liststyle == s:TREELIST
+-"   call Decho("treelist handling")
+-   let dirname= substitute(getline("."),'^\(| \)*','','e')
++" ---------------------------------------------------------------------
++" s:NetrwMarkFileTgt:  (invoked by mt) This function sets up a marked file target {{{2
++"   Sets up two variables, 
++"     s:netrwmftgt : holds the target directory
++"     s:netrwmfloc : 0=target directory is remote
++"                    1=target directory is local
++fun! s:NetrwMarkFileTgt(islocal)
++"  call Dfunc("s:NetrwMarkFileTgt(islocal=".a:islocal.")")
++  let svpos= netrw#NetrwSavePosn()
++  if a:islocal && exists("b:netrw_curdir")
++   exe "cd ".b:netrw_curdir
++  endif
+ 
++  if exists("s:netrwmftgt") || exists("s:netrwmfloc")
++"   call Decho("s:netrwmftgt<".s:netrwmftgt."> exists; removing it")
++   silent! unlet s:netrwmftgt s:netrwmfloc
+   else
+-"   call Decho("obtain word from wide listing")
+-   let dirname= getline(".")
+-
+-   if !exists("b:netrw_cpf")
+-    let b:netrw_cpf= 0
+-    exe 'silent keepjumps '.w:netrw_bannercnt.',$g/^./if virtcol("$") > b:netrw_cpf|let b:netrw_cpf= virtcol("$")|endif'
+-"    call Decho("computed cpf")
++"   call Decho("s:netrwmftgt doesn't exist; setting it to <".b:netrw_curdir.">")
++   let s:netrwmftgt = b:netrw_curdir
++   let s:netrwmfloc = a:islocal
++   if g:netrw_cygwin
++    let s:netrwmftgt= substitute(system("cygpath ".b:netrw_curdir),'\n$','','')
+    endif
++  endif
+ 
+-"   call Decho("buf#".bufnr("%")."<".bufname("%").">")
+-   let filestart = (virtcol(".")/b:netrw_cpf)*b:netrw_cpf
+-"   call Decho("filestart= ([virtcol=".virtcol(".")."]/[b:netrw_cpf=".b:netrw_cpf."])*b:netrw_cpf=".filestart."  bannercnt=".w:netrw_bannercnt)
+-"   call Decho("1: dirname<".dirname.">")
+-   if filestart > 0|let dirname= substitute(dirname,'^.\{'.filestart.'}','','')|endif
+-"   call Decho("2: dirname<".dirname.">")
+-   let dirname   = substitute(dirname,'^\(.\{'.b:netrw_cpf.'}\).*$','\1','e')
+-"   call Decho("3: dirname<".dirname.">")
+-   let dirname   = substitute(dirname,'\s\+$','','e')
+-"   call Decho("4: dirname<".dirname.">")
++  call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++  call netrw#NetrwRestorePosn(svpos)
++"  call Dret("s:NetrwMarkFileTgt")
++endfun
++
++" ===========================================
++" s:NetrwObtain: obtain file under cursor or from markfile list {{{2
++fun! s:NetrwObtain(islocal)
++"  call Dfunc("NetrwObtain(islocal=".a:islocal.")")
++
++  if exists("s:netrwmarkfilelist")
++   for fname in s:netrwmarkfilelist
++    call netrw#NetrwObtain(a:islocal,fname)
++   endfor
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
++  else
++   call netrw#NetrwObtain(a:islocal,expand("<cWORD>"))
+   endif
+ 
+-"  call Dret("NetGetWord <".dirname.">")
+-  return dirname
++"  call Dret("NetrwObtain")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetBrowseRm: remove/delete a remote file or directory {{{2
+-fun! s:NetBrowseRm(usrhost,path) range
+-"  call Dfunc("NetBrowseRm(usrhost<".a:usrhost."> path<".a:path.">) virtcol=".virtcol("."))
+-"  call Decho("firstline=".a:firstline." lastline=".a:lastline)
++" netrw#NetrwObtain: {{{2
++fun! netrw#NetrwObtain(islocal,fname,...)
++"  call Dfunc("netrw#NetrwObtain(islocal=".a:islocal." fname<".a:fname.">) a:0=".a:0)
++  " NetrwStatusLine support - for obtaining support
+ 
+-  " preparation for removing multiple files/directories
+-  let ctr= a:firstline
+-  let all= 0
++  if a:islocal
+ 
+-  " remove multiple files and directories
+-  while ctr <= a:lastline
+-   exe ctr
+-
+-   let rmfile= s:NetGetWord()
+-"   call Decho("rmfile<".rmfile.">")
+-
+-   if rmfile !~ '^"' && (rmfile =~ '@$' || rmfile !~ '[\/]$')
+-    " attempt to remove file
+-"    call Decho("attempt to remove file")
+-    if !all
+-     echohl Statement
+-     call inputsave()
+-     let ok= input("Confirm deletion of file<".rmfile."> ","[{y(es)},n(o),a(ll),q(uit)] ")
+-     call inputrestore()
+-     echohl NONE
+-     if ok == ""
+-      let ok="no"
+-     endif
+-     let ok= substitute(ok,'\[{y(es)},n(o),a(ll),q(uit)]\s*','','e')
+-     if ok =~ 'a\%[ll]'
+-      let all= 1
++   " obtain local file from getcwd() to b:netrw_curdir
++   if exists("b:netrw_curdir") && getcwd() != b:netrw_curdir
++    let fname= expand("<cWORD>")
++    let fcopy= readfile(b:netrw_curdir."/".fname,"b")
++    call writefile(fcopy,getcwd()."/".fname,"b")
++   elseif !exists("b:netrw_curdir")
++    call netrw#ErrorMsg(s:ERROR,"local browsing directory doesn't exist!",36)
++   else
++    call netrw#ErrorMsg(s:WARNING,"local browsing directory and current directory are identical",37)
++   endif
++
++  else
++
++   " obtain a remote file to local directory (see tgtdir below)
++   call s:SetupNetrwStatusLine('%f %h%m%r%=%9*Obtaining '.a:fname)
++   
++   " set up target directory (default is vim's idea of the current directory)
++   if a:0 > 0
++    let tgtdir= a:1
++   else
++    let tgtdir= '.'
++   endif
++"   call Decho("tgtdir<".tgtdir.">")
++   if exists("w:netrw_method") && w:netrw_method =~ '[235]'
++"   call Decho("method=".w:netrw_method)
++    if executable("ftp")
++"    call Decho("ftp is executable, method=".w:netrw_method)
++     let curdir = b:netrw_curdir
++     let path   = substitute(curdir,'ftp://[^/]\+/','','e')
++     let curline= line(".")
++     let endline= line("$")+1
++     setlocal ma noro
++     keepjumps $
++"    call Decho("getcwd<".getcwd().">")
++"    call Decho("curdir<".curdir.">")
++"    call Decho("path<".path.">")
++"    call Decho("curline=".curline)
++"    call Decho("endline=".endline)
++
++     ".........................................
++     if w:netrw_method == 2
++      " ftp + <.netrc>: Method #2
++      setlocal ff=unix
++      if path != ""
++       put ='cd '.path
++"      call Decho("ftp:  cd ".path)
++      endif
++      if tgtdir != '.'
++       put ='lcd '.tgtdir
++      endif
++      put ='get '.a:fname
++"     call Decho("ftp:  get ".a:fname)
++      put ='quit'
++"     call Decho("ftp:  quit")
++      if exists("g:netrw_port") && g:netrw_port != ""
++"      call Decho("exe ".g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine." ".g:netrw_port)
++       exe g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine." ".g:netrw_port
++      else
++"      call Decho("exe ".g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine)
++       exe g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine
++      endif
++
++    ".........................................
++   elseif w:netrw_method == 3
++    " ftp + machine,id,passwd,filename: Method #3
++     setlocal ff=unix
++     if exists("g:netrw_port") && g:netrw_port != ""
++      put ='open '.g:netrw_machine.' '.g:netrw_port
++"     call Decho('ftp:  open '.g:netrw_machine.' '.g:netrw_port)
++     else
++      put ='open '.g:netrw_machine
++"     call Decho('ftp:  open '.g:netrw_machine)
+      endif
+-    endif
+ 
+-    if all || ok =~ 'y\%[es]' || ok == ""
+-     if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
+-      silent! keepjumps .,$d
+-      call s:NetBrowseFtpCmd(a:path,"delete ".rmfile)
++     if exists("g:netrw_ftp") && g:netrw_ftp == 1
++      put =g:netrw_uid
++      put ='\"'.s:netrw_passwd.'\"'
++"     call Decho('ftp:  g:netrw_uid')
++"     call Decho('ftp:  s:netrw_passwd')
+      else
+-      let netrw_rm_cmd= s:MakeSshCmd(g:netrw_rm_cmd)
+-"      call Decho("attempt to remove file: system(".netrw_rm_cmd.")")
+-      let ret= s:System("system",netrw_rm_cmd)
+-"      call Decho("returned=".ret." errcode=".v:shell_error)
++      put ='user \"'.g:netrw_uid.'\" \"'.s:netrw_passwd.'\"'
++"     call Decho('user '.g:netrw_uid.' '.s:netrw_passwd)
+      endif
+-    elseif ok =~ 'q\%[uit]'
+-     break
++
++    if path != ""
++     put ='cd '.path
++"    call Decho('cd '.a:path)
++    endif
++    if tgtdir != '.'
++     put ='lcd '.tgtdir
+     endif
++    put ='get '.a:fname
++"   call Decho("ftp:  get ".a:fname)
++    put ='quit'
++"   call Decho("ftp:  quit")
+ 
+-   else
+-    " attempt to remove directory
+-"    call Decho("attempt to remove directory")
+-    if !all
+-     call inputsave()
+-     let ok= input("Confirm deletion of directory<".rmfile."> ","[{y(es)},n(o),a(ll),q(uit)] ")
+-     call inputrestore()
+-     if ok == ""
+-      let ok="no"
++     " perform ftp:
++     " -i       : turns off interactive prompting from ftp
++     " -n  unix : DON'T use <.netrc>, even though it exists
++     " -n  win32: quit being obnoxious about password
++"    call Decho("exe ".g:netrw_silentxfer.curline.",$!".g:netrw_ftp_cmd." -i -n")
++     exe g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i -n"
++
++     ".........................................
++     else
++      call netrw#ErrorMsg(s:WARNING,"unable to comply with your request<" . choice . ">",28)
+      endif
+-     let ok= substitute(ok,'\[{y(es)},n(o),a(ll),q(uit)]\s*','','e')
+-     if ok =~ 'a\%[ll]'
+-      let all= 1
++     " restore
++     exe "silent! ".endline.",$d"
++     exe "keepjumps ".curline
++     setlocal noma nomod ro
++    else
++"    call Decho("ftp not executable")
++     if !exists("g:netrw_quiet")
++      call netrw#ErrorMsg(s:ERROR,"this system doesn't support ftp",29)
+      endif
++     " restore status line
++     let &stl        = s:netrw_users_stl
++     let &laststatus = s:netrw_users_ls
++     " restore NetrwMethod
++     if exists("keep_netrw_method")
++      call s:NetrwMethod(keep_netrw_choice)
++      let w:netrw_method  = keep_netrw_wmethod
++     endif
++"    call Dret("NetrwObtain")
++     return
+     endif
+ 
+-    if all || ok =~ 'y\%[es]' || ok == ""
+-     if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
+-      call s:NetBrowseFtpCmd(a:path,"rmdir ".rmfile)
+-     else
+-      let rmfile          = substitute(a:path.rmfile,'/$','','')
+-      let netrw_rmdir_cmd = s:MakeSshCmd(g:netrw_rmdir_cmd).' '.rmfile
+-"      call Decho("attempt to remove dir: system(".netrw_rmdir_cmd.")")
+-      let ret= s:System("system",netrw_rmdir_cmd)
+-"      call Decho("returned=".ret." errcode=".v:shell_error)
+-
+-      if v:shell_error != 0
+-"       call Decho("v:shell_error not 0")
+-       let netrw_rmf_cmd= s:MakeSshCmd(g:netrw_rmf_cmd).' '.substitute(rmfile,'[\/]$','','e')
+-"       call Decho("2nd attempt to remove dir: system(".netrw_rmf_cmd.")")
+-       let ret= s:System("system",netrw_rmf_cmd)
+-"       call Decho("returned=".ret." errcode=".v:shell_error)
++   ".........................................
++   else
++    " scp: Method#4
++"    call Decho("using scp")
++    let curdir = b:netrw_curdir
++    let path   = substitute(curdir,'scp://[^/]\+/','','e')
++"    call Decho("path<".path.">")
++    if exists("g:netrw_port") && g:netrw_port != ""
++     let useport= " ".g:netrw_scpport." ".g:netrw_port
++    else
++     let useport= ""
++    endif
++"    call Decho("pwd<".getcwd().">")
++"    call Decho("executing: !".g:netrw_scp_cmd.useport." ".g:netrw_machine.":".path.escape(a:fname,' ?&')." ".tgtdir)
++    exe g:netrw_silentxfer."!".g:netrw_scp_cmd.useport." ".g:netrw_machine.":".path.escape(a:fname,' ?&')." ".tgtdir
++    endif
+ 
+-       if v:shell_error != 0 && !exists("g:netrw_quiet")
+-       	call netrw#ErrorMsg(s:ERROR,"unable to remove directory<".rmfile."> -- is it empty?",22)
+-       endif
+-      endif
+-     endif
++    " restore status line
++    let &stl        = s:netrw_users_stl
++    let &laststatus = s:netrw_users_ls
++    redraw!
+ 
+-    elseif ok =~ 'q\%[uit]'
+-     break
++    " restore NetrwMethod
++    if exists("keep_netrw_method")
++     call s:NetrwMethod(keep_netrw_choice)
++     let w:netrw_method  = keep_netrw_wmethod
+     endif
+    endif
+ 
+-   let ctr= ctr + 1
+-  endwhile
+-
+-  " refresh the (remote) directory listing
+-"  call Decho("refresh remote directory listing")
+-  call netrw#NetSavePosn()
+-  call s:NetRefresh(0,s:NetBrowseChgDir(0,'./'))
+-
+-"  call Dret("NetBrowseRm")
++"  call Dret("netrw#NetrwObtain")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetBrowseRename: rename a remote file or directory {{{2
+-fun! s:NetBrowseRename(usrhost,path) range
+-"  call Dfunc("NetBrowseRename(usrhost<".a:usrhost."> path<".a:path.">)")
++" s:NetrwUpload: load fname to tgt (used by NetrwMarkFileCopy()) {{{2
++"                    fname may itself be a remote or local file
++"                    tgt is assumed to be remote, so NetWrite will be used
++"                    (indirectly an autocmd)
++fun! s:NetrwUpload(fname,tgt)
++"  call Dfunc("s:NetrwUpload(fname<".a:fname."> tgt<".a:tgt.">)")
+ 
+-  " preparation for removing multiple files/directories
+-  let ctr        = a:firstline
+-  let rename_cmd = s:MakeSshCmd(g:netrw_rename_cmd)
+-
+-  " attempt to rename files/directories
+-  while ctr <= a:lastline
+-   exe "keepjumps ".ctr
+-
+-   norm! 0
+-   let oldname= s:NetGetWord()
+-"   call Decho("oldname<".oldname.">")
++  1split
++"  call Decho("exe e ".a:fname)
++  exe "e ".escape(a:fname,g:netrw_fname_escape)
++  if a:tgt =~ '/$'
++"   call Decho("exe w ".a:tgt.a:fname)
++   exe "w ".escape(a:tgt.a:fname,g:netrw_fname_escape)
++  else
++"   call Decho("exe w ".a:tgt)
++   exe "w ".escape(a:tgt,g:netrw_fname_escape)
++  endif
++  q!
+ 
+-   call inputsave()
+-   let newname= input("Moving ".oldname." to : ",oldname)
+-   call inputrestore()
++"  call Dret("s:NetrwUpload")
++endfun
+ 
+-   if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
+-    call s:NetBrowseFtpCmd(a:path,"rename ".oldname." ".newname)
+-   else
+-    let oldname= a:path.oldname
+-    let newname= a:path.newname
+-"    call Decho("system(rename_cmd".' "'.escape(oldname," ").'" "'.escape(newname,s:netrw_cd_escape).'"')
+-    let ret= s:System("system",rename_cmd.' "'.escape(oldname,s:netrw_cd_escape).'" "'.escape(newname,s:netrw_cd_escape).'"')
++" ---------------------------------------------------------------------
++" s:NetrwPreview: {{{2
++fun! s:NetrwPreview(path) range
++"  call Dfunc("NetrwPreview(path<".a:path.">)")
++  call s:NetrwOptionSave("s:")
++  call s:NetrwSafeOptions()
++  if has("quickfix")
++   if !isdirectory(a:path)
++    exe (g:netrw_preview? "vert " : "")."pedit ".escape(a:path,g:netrw_fname_escape)
++   elseif !exists("g:netrw_quiet")
++    call netrw#ErrorMsg(s:WARNING,"sorry, cannot preview a directory such as <".a:path.">",38)
+    endif
+-
+-   let ctr= ctr + 1
+-  endwhile
+-
+-  " refresh the directory
+-  let curline= line(".")
+-  call s:NetBrowse(0,s:NetBrowseChgDir(0,'./'))
+-  exe "keepjumps ".curline
+-"  call Dret("NetBrowseRename")
++  elseif !exists("g:netrw_quiet")
++   call netrw#ErrorMsg(s:WARNING,"sorry, to preview your vim needs the quickfix feature compiled in",39)
++  endif
++  call s:NetrwOptionRestore("s:")
++"  call Dret("NetrwPreview")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetRefresh: {{{2
+-fun! s:NetRefresh(islocal,dirname)
+-"  call Dfunc("NetRefresh(islocal<".a:islocal.">,dirname=".a:dirname.") hide=".g:netrw_hide." sortdir=".g:netrw_sort_direction)
+-  " at the current time (Mar 19, 2007) all calls to NetRefresh() call NetBrowseChgDir() first.
+-  " NetBrowseChgDir() may clear the display; hence a NetSavePosn() may not work if its placed here.
+-  " Also, NetBrowseChgDir() now does a NetSavePosn() itself.
++" s:NetrwRefresh: {{{2
++fun! s:NetrwRefresh(islocal,dirname)
++"  call Dfunc("NetrwRefresh(islocal<".a:islocal.">,dirname=".a:dirname.") hide=".g:netrw_hide." sortdir=".g:netrw_sort_direction)
++  " at the current time (Mar 19, 2007) all calls to NetrwRefresh() call NetrwBrowseChgDir() first.
++  " NetrwBrowseChgDir() may clear the display; hence a NetrwSavePosn() may not work if its placed here.
++  " Also, NetrwBrowseChgDir() now does a NetrwSavePosn() itself.
+   setlocal ma noro
+ "  call Decho("clear buffer<".expand("%")."> with :%d")
+   %d
+   if a:islocal
+    call netrw#LocalBrowseCheck(a:dirname)
+   else
+-   call s:NetBrowse(a:islocal,a:dirname)
++   call s:NetrwBrowse(a:islocal,a:dirname)
+   endif
+-  call netrw#NetRestorePosn()
++  call netrw#NetrwRestorePosn()
+   redraw!
+-"  call Dret("NetRefresh")
++"  call Dret("NetrwRefresh")
++endfun
++
++" ---------------------------------------------------------------------
++" s:NetrwSortStyle: change sorting style (name - time - size) and refresh display {{{2
++fun! s:NetrwSortStyle(islocal)
++"  call Dfunc("s:NetrwSortStyle(islocal=".a:islocal.") netrw_sort_by<".g:netrw_sort_by.">")
++  call s:NetrwSaveWordPosn()
++  let svpos= netrw#NetrwSavePosn()
++
++  let g:netrw_sort_by= (g:netrw_sort_by =~ 'n')? 'time' : (g:netrw_sort_by =~ 't')? 'size' : 'name'
++  norm! 0
++  call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++  call netrw#NetrwRestorePosn(svpos)
++
++"  call Dret("s:NetrwSortStyle : netrw_sort_by<".g:netrw_sort_by.">")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetSplit: mode {{{2
++" s:NetrwSplit: mode {{{2
+ "           =0 : net   and o
+ "           =1 : net   and t
+ "           =2 : net   and v
+ "           =3 : local and o
+ "           =4 : local and t
+ "           =5 : local and v
+-fun! s:NetSplit(mode)
+-"  call Dfunc("NetSplit(mode=".a:mode.") alto=".g:netrw_alto." altv=".g:netrw_altv)
++fun! s:NetrwSplit(mode)
++"  call Dfunc("NetrwSplit(mode=".a:mode.") alto=".g:netrw_alto." altv=".g:netrw_altv)
+ 
+   call s:SaveWinVars()
+ 
+@@ -2797,176 +3644,528 @@
+    exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"
+    let s:didsplit= 1
+    call s:RestoreWinVars()
+-   call s:NetBrowse(0,s:NetBrowseChgDir(0,s:NetGetWord()))
++   call s:NetrwBrowse(0,s:NetrwBrowseChgDir(0,s:NetrwGetWord()))
+    unlet s:didsplit
+ 
+   elseif a:mode == 1
+    " remote and t
+-   let cursorword  = s:NetGetWord()
++   let cursorword  = s:NetrwGetWord()
++   tabnew
++   let s:didsplit= 1
++   call s:RestoreWinVars()
++   call s:NetrwBrowse(0,s:NetrwBrowseChgDir(0,cursorword))
++   unlet s:didsplit
++
++  elseif a:mode == 2
++   " remote and v
++   exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v"
++   let s:didsplit= 1
++   call s:RestoreWinVars()
++   call s:NetrwBrowse(0,s:NetrwBrowseChgDir(0,s:NetrwGetWord()))
++   unlet s:didsplit
++
++  elseif a:mode == 3
++   " local and o
++   exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"
++   let s:didsplit= 1
++   call s:RestoreWinVars()
++   call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,s:NetrwGetWord()))
++   unlet s:didsplit
++
++  elseif a:mode == 4
++   " local and t
++   let netrw_curdir= b:netrw_curdir
++   let cursorword  = s:NetrwGetWord()
+    tabnew
++   let b:netrw_curdir= netrw_curdir
++   let s:didsplit= 1
++   call s:RestoreWinVars()
++   call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,cursorword))
++   unlet s:didsplit
++
++  elseif a:mode == 5
++   " local and v
++   exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v"
+    let s:didsplit= 1
+    call s:RestoreWinVars()
+-   call s:NetBrowse(0,s:NetBrowseChgDir(0,cursorword))
++   call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,s:NetrwGetWord()))
+    unlet s:didsplit
+ 
+-  elseif a:mode == 2
+-   " remote and v
+-   exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v"
+-   let s:didsplit= 1
+-   call s:RestoreWinVars()
+-   call s:NetBrowse(0,s:NetBrowseChgDir(0,s:NetGetWord()))
+-   unlet s:didsplit
++  else
++   call netrw#ErrorMsg(s:ERROR,"(NetrwSplit) unsupported mode=".a:mode,45)
++  endif
++
++"  call Dret("NetrwSplit")
++endfun
++
++" ---------------------------------------------------------------------
++" s:NetrwBrowseX:  allows users to write custom functions to operate on {{{2
++"              files given their extension.  Passes 0=local, 1=remote
++fun! netrw#NetrwBrowseX(fname,remote)
++"  call Dfunc("NetrwBrowseX(fname<".a:fname."> remote=".a:remote.")")
++
++  " set up the filename
++  " (lower case the extension, make a local copy of a remote file)
++  let exten= substitute(a:fname,'.*\.\(.\{-}\)','\1','e')
++  if has("win32") || has("win95") || has("win64") || has("win16")
++   let exten= substitute(exten,'^.*$','\L&\E','')
++  endif
++  let fname= escape(a:fname,"%#")
++"  call Decho("fname<".fname."> after escape()")
++
++  " seems kde systems often have gnome-open due to dependencies, even though
++  " gnome-open's subsidiary display tools are largely absent.  Kde systems
++  " usually have "kdeinit" running, though...  (tnx Mikolaj Machowski)
++  if !exists("s:haskdeinit")
++   if has("unix")
++    let s:haskdeinit= s:System("system",'ps -e') =~ 'kdeinit'
++    if v:shell_error
++     let s:haskdeinit = 0
++    endif
++   else
++    let s:haskdeinit= 0
++   endif
++"   call Decho("setting s:haskdeinit=".s:haskdeinit)
++  endif
++
++  if a:remote == 1
++   " create a local copy
++   let fname= fnamemodify(tempname(),":t:r").".".exten
++"   call Decho("a:remote=".a:remote.": create a local copy of <".a:fname."> as <".fname.">")
++   exe "silent keepjumps bot 1new ".a:fname
++   setlocal bh=delete
++"   call Decho("exe w! ".fname)
++   exe "w! ".fname
++   q
++  endif
++"  call Decho("exten<".exten."> "."netrwFileHandlers#NFH_".exten."():exists=".exists("*netrwFileHandlers#NFH_".exten))
++
++  " set up redirection
++  if &srr =~ "%s"
++   if (has("win32") || has("win95") || has("win64") || has("win16"))
++    let redir= substitute(&srr,"%s","nul","")
++   else
++    let redir= substitute(&srr,"%s","/dev/null","")
++   endif
++  elseif (has("win32") || has("win95") || has("win64") || has("win16"))
++   let redir= &srr . "nul"
++  else
++   let redir= &srr . "/dev/null"
++  endif
++"  call Decho("redir{".redir."} srr{".&srr."}")
++
++  " extract any viewing options.  Assumes that they're set apart by quotes.
++  if exists("g:netrw_browsex_viewer")
++   if g:netrw_browsex_viewer =~ '\s'
++    let viewer  = substitute(g:netrw_browsex_viewer,'\s.*$','','')
++    let viewopt = substitute(g:netrw_browsex_viewer,'^\S\+\s*','','')." "
++    let oviewer = ''
++    let cnt     = 1
++    while !executable(viewer) && viewer != oviewer
++     let viewer  = substitute(g:netrw_browsex_viewer,'^\(\(^\S\+\s\+\)\{'.cnt.'}\S\+\)\(.*\)$','\1','')
++     let viewopt = substitute(g:netrw_browsex_viewer,'^\(\(^\S\+\s\+\)\{'.cnt.'}\S\+\)\(.*\)$','\3','')." "
++     let cnt     = cnt + 1
++     let oviewer = viewer
++"     call Decho("!exe: viewer<".viewer.">  viewopt<".viewopt.">")
++    endwhile
++   else
++    let viewer  = g:netrw_browsex_viewer
++    let viewopt = ""
++   endif
++"   call Decho("viewer<".viewer.">  viewopt<".viewopt.">")
++  endif
++
++  " execute the file handler
++  if exists("g:netrw_browsex_viewer") && g:netrw_browsex_viewer == '-'
++"  call Decho("g:netrw_browsex_viewer<".g:netrw_browsex_viewer.">")
++   let ret= netrwFileHandlers#Invoke(exten,fname)
++
++  elseif exists("g:netrw_browsex_viewer") && executable(viewer)
++"   call Decho("g:netrw_browsex_viewer<".g:netrw_browsex_viewer.">")
++"   call Decho("exe silent !".viewer." ".viewopt.g:netrw_shq.escape(fname,'%#').g:netrw_shq.redir)
++   exe "silent !".viewer." ".viewopt.g:netrw_shq.escape(fname,'%#').g:netrw_shq.redir
++   let ret= v:shell_error
++
++  elseif has("win32") || has("win64")
++"   call Decho('exe silent !start rundll32 url.dll,FileProtocolHandler '.g:netrw_shq.escape(fname, '%#').g:netrw_shq)
++   exe 'silent !start rundll32 url.dll,FileProtocolHandler '.g:netrw_shq.escape(fname, '%#').g:netrw_shq
++   call inputsave()|call input("Press <cr> to continue")|call inputrestore()
++   let ret= v:shell_error
++
++  elseif has("unix") && executable("gnome-open") && !s:haskdeinit
++"   call Decho("exe silent !gnome-open ".g:netrw_shq.escape(fname,'%#').g:netrw_shq." ".redir)
++   exe "silent !gnome-open ".g:netrw_shq.escape(fname,'%#').g:netrw_shq.redir
++   let ret= v:shell_error
++
++  elseif has("unix") && executable("kfmclient") && s:haskdeinit
++"   call Decho("exe silent !kfmclient exec ".g:netrw_shq.escape(fname,'%#').g:netrw_shq." ".redir)
++   exe "silent !kfmclient exec ".g:netrw_shq.escape(fname,'%#').g:netrw_shq." ".redir
++   let ret= v:shell_error
++
++  elseif has("macunix") && executable("open")
++"   call Decho("exe silent !open '".escape(fname,'%#')."' ".redir)
++   exe silent !open '".escape(fname,'%#')."' ".redir
++   let ret= v:shell_error
++
++  else
++   " netrwFileHandlers#Invoke() always returns 0
++   let ret= netrwFileHandlers#Invoke(exten,fname)
++  endif
++
++  " if unsuccessful, attempt netrwFileHandlers#Invoke()
++  if ret
++   let ret= netrwFileHandlers#Invoke(exten,fname)
++  endif
++
++  redraw!
++
++  " cleanup: remove temporary file,
++  "          delete current buffer if success with handler,
++  "          return to prior buffer (directory listing)
++  if a:remote == 1 && fname != a:fname
++"   call Decho("deleting temporary file<".fname.">")
++   call s:System("delete",fname)
++  endif
++
++  if a:remote == 1
++   setlocal bh=delete bt=nofile
++   if g:netrw_use_noswf
++    setlocal noswf
++   endif
++   exe "norm! \<c-o>"
++   redraw!
++  endif
++
++"  call Dret("NetrwBrowseX")
++endfun
++
++" ---------------------------------------------------------------------
++"  Remote Directory Browsing Support:    {{{1
++" ===========================================
++
++" ---------------------------------------------------------------------
++" s:NetrwRemoteListing: {{{2
++fun! s:NetrwRemoteListing()
++"  call Dfunc("s:NetrwRemoteListing() b:netrw_curdir<".b:netrw_curdir.">)")
++
++  call s:RemotePathAnalysis(b:netrw_curdir)
++
++  " sanity check:
++  if exists("b:netrw_method") && b:netrw_method =~ '[235]'
++"   call Decho("b:netrw_method=".b:netrw_method)
++   if !executable("ftp")
++    if !exists("g:netrw_quiet")
++     call netrw#ErrorMsg(s:ERROR,"this system doesn't support remote directory listing via ftp",18)
++    endif
++    call s:NetrwOptionRestore("w:")
++"    call Dret("s:NetrwRemoteListing")
++    return
++   endif
++
++  elseif !exists("g:netrw_list_cmd") || g:netrw_list_cmd == ''
++   if !exists("g:netrw_quiet")
++    if g:netrw_list_cmd == ""
++     call netrw#ErrorMsg(s:ERROR,g:netrw_ssh_cmd." is not executable on your system",47)
++    else
++     call netrw#ErrorMsg(s:ERROR,"this system doesn't support remote directory listing via ".g:netrw_list_cmd,19)
++    endif
++   endif
++
++   call s:NetrwOptionRestore("w:")
++"   call Dret("s:NetrwRemoteListing")
++   return
++  endif  " (remote handling sanity check)
++
++  if exists("b:netrw_method")
++"   call Decho("setting w:netrw_method<".b:netrw_method.">")
++   let w:netrw_method= b:netrw_method
++  endif
++
++  if s:method == "ftp"
++   " use ftp to get remote file listing
++"   call Decho("use ftp to get remote file listing")
++   let s:method  = "ftp"
++   let listcmd = g:netrw_ftp_list_cmd
++   if g:netrw_sort_by =~ '^t'
++    let listcmd= g:netrw_ftp_timelist_cmd
++   elseif g:netrw_sort_by =~ '^s'
++    let listcmd= g:netrw_ftp_sizelist_cmd
++   endif
++"   call Decho("listcmd<".listcmd."> (using g:netrw_ftp_list_cmd)")
++   call s:NetrwRemoteFtpCmd(s:path,listcmd)
++"   exe "keepjumps ".w:netrw_bannercnt.',$g/^./call Decho("raw listing: ".getline("."))'
++
++   if w:netrw_liststyle == s:THINLIST || w:netrw_liststyle == s:WIDELIST || w:netrw_liststyle == s:TREELIST
++    " shorten the listing
++"    call Decho("generate short listing")
++    exe "keepjumps ".w:netrw_bannercnt
++
++    " cleanup
++    if g:netrw_ftp_browse_reject != ""
++     exe "silent! g/".g:netrw_ftp_browse_reject."/keepjumps d"
++    endif
++    silent! keepjumps %s/\r$//e
++
++    " if there's no ../ listed, then put ./ and ../ in
++    let line1= line(".")
++    exe "keepjumps ".w:netrw_bannercnt
++    let line2= search('^\.\.\/\%(\s\|$\)','cnW')
++    if line2 == 0
++"     call Decho("netrw is putting ./ and ../ into listing")
++     keepjumps put='../'
++     keepjumps put='./'
++    endif
++    exe "keepjumps ".line1
++    keepjumps norm! 0
++
++"    call Decho("line1=".line1." line2=".line2." line(.)=".line("."))
++    if search('^\d\{2}-\d\{2}-\d\{2}\s','n') " M$ ftp site cleanup
++"     call Decho("M$ ftp cleanup")
++     exe 'silent! keepjumps '.w:netrw_bannercnt.',$s/^\d\{2}-\d\{2}-\d\{2}\s\+\d\+:\d\+[AaPp][Mm]\s\+\%(<DIR>\|\d\+\)\s\+//'
++    else " normal ftp cleanup
++"     call Decho("normal ftp cleanup")
++     exe 'silent! keepjumps '.w:netrw_bannercnt.',$s/^\(\%(\S\+\s\+\)\{7}\S\+\)\s\+\(\S.*\)$/\2/e'
++     exe "silent! keepjumps ".w:netrw_bannercnt.',$g/ -> /s# -> .*/$#/#e'
++     exe "silent! keepjumps ".w:netrw_bannercnt.',$g/ -> /s# -> .*$#/#e'
++    endif
++   endif
++
++  else
++   " use ssh to get remote file listing {{{3
++"   call Decho("use ssh to get remote file listing: s:netrw_shq<".g:netrw_shq."> s:path<".s:path."> g:netrw_cd_escape<".g:netrw_cd_escape.">")
++   let listcmd= s:MakeSshCmd(g:netrw_list_cmd)
++"   call Decho("listcmd<".listcmd."> (using g:netrw_list_cmd)")
++   if g:netrw_scp_cmd =~ '^pscp'
++"    call Decho("1: exe silent r! ".listcmd.g:netrw_shq.s:path.g:netrw_shq)
++    exe "silent r! ".listcmd.g:netrw_shq.s:path.g:netrw_shq
++    " remove rubbish and adjust listing format of 'pscp' to 'ssh ls -FLa' like
++    g/^Listing directory/d
++    g/^d[-rwx][-rwx][-rwx]/s+$+/+e
++    silent g/^l[-rwx][-rwx][-rwx]/s+$+ at +e
++    if g:netrw_liststyle != s:LONGLIST
++     g/^[dlsp-][-rwx][-rwx][-rwx]/s/^.*\s\(\S\+\)$/\1/e
++    endif
++   else
++    if s:path == ""
++"     call Decho("2: exe silent r! ".listcmd)
++     exe "silent r! ".listcmd
++    else
++"     call Decho("3: exe silent r! ".listcmd." ".g:netrw_shq.s:path.g:netrw_shq)
++     exe "silent r! ".listcmd." ".g:netrw_shq.s:path.g:netrw_shq
++    endif
++   endif
+ 
+-  elseif a:mode == 3
+-   " local and o
+-   exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"
+-   let s:didsplit= 1
+-   call s:RestoreWinVars()
+-   call netrw#LocalBrowseCheck(s:NetBrowseChgDir(1,s:NetGetWord()))
+-   unlet s:didsplit
++   " cleanup
++   if g:netrw_ftp_browse_reject != ""
++"    call Decho("(cleanup) exe silent! g/".g:netrw_ssh_browse_reject."/keepjumps d")
++    exe "silent! g/".g:netrw_ssh_browse_reject."/keepjumps d"
++   endif
++  endif
+ 
+-  elseif a:mode == 4
+-   " local and t
+-   let netrw_curdir= b:netrw_curdir
+-   let cursorword  = s:NetGetWord()
+-   tabnew
+-   let b:netrw_curdir= netrw_curdir
+-   let s:didsplit= 1
+-   call s:RestoreWinVars()
+-   call netrw#LocalBrowseCheck(s:NetBrowseChgDir(1,cursorword))
+-   unlet s:didsplit
++  if w:netrw_liststyle == s:LONGLIST
++   " do a long listing; these substitutions need to be done prior to sorting {{{3
++"   call Decho("fix long listing:")
+ 
+-  elseif a:mode == 5
+-   " local and v
+-   exe (g:netrw_altv? "rightb " : "lefta ").g:netrw_winsize."wincmd v"
+-   let s:didsplit= 1
+-   call s:RestoreWinVars()
+-   call netrw#LocalBrowseCheck(s:NetBrowseChgDir(1,s:NetGetWord()))
+-   unlet s:didsplit
++   if s:method == "ftp"
++    " cleanup
++    exe "keepjumps ".w:netrw_bannercnt
++    while getline(".") =~ g:netrw_ftp_browse_reject
++     keepjumps d
++    endwhile
++    " if there's no ../ listed, then put ./ and ../ in
++    let line1= line(".")
++    keepjumps 1
++    silent keepjumps call search('^\.\.\/\%(\s\|$\)','W')
++    let line2= line(".")
++    if line2 == 0
++     exe 'keepjumps '.w:netrw_bannercnt."put='./'"
++     if b:netrw_curdir != '/'
++      exe 'keepjumps '.w:netrw_bannercnt."put='../'"
++     endif
++    endif
++   exe "keepjumps ".line1
++   keepjumps norm! 0
++   endif
+ 
+-  else
+-   call netrw#ErrorMsg(s:ERROR,"(NetSplit) unsupported mode=".a:mode,45)
++   if search('^\d\{2}-\d\{2}-\d\{2}\s','n') " M$ ftp site cleanup
++"    call Decho("M$ ftp site listing cleanup")
++    exe 'silent! keepjumps '.w:netrw_bannercnt.',$s/^\(\d\{2}-\d\{2}-\d\{2}\s\+\d\+:\d\+[AaPp][Mm]\s\+\%(<DIR>\|\d\+\)\s\+\)\(\w.*\)$/\2\t\1/'
++   elseif exists("w:netrw_bannercnt") && w:netrw_bannercnt <= line("$")
++"    call Decho("normal ftp site listing cleanup: bannercnt=".w:netrw_bannercnt." line($)=".line("$"))
++    exe 'silent keepjumps '.w:netrw_bannercnt.',$s/ -> .*$//e'
++    exe 'silent keepjumps '.w:netrw_bannercnt.',$s/^\(\%(\S\+\s\+\)\{7}\S\+\)\s\+\(\S.*\)$/\2\t\1/e'
++    exe 'silent keepjumps '.w:netrw_bannercnt
++   endif
+   endif
+ 
+-"  call Dret("NetSplit")
++"  if exists("w:netrw_bannercnt") && w:netrw_bannercnt <= line("$") " Decho
++"   exe "keepjumps ".w:netrw_bannercnt.',$g/^./call Decho("listing: ".getline("."))'
++"  endif " Decho
++"  call Dret("s:NetrwRemoteListing")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetBrowseX:  allows users to write custom functions to operate on {{{2
+-"              files given their extension.  Passes 0=local, 1=remote
+-fun! netrw#NetBrowseX(fname,remote)
+-"  call Dfunc("NetBrowseX(fname<".a:fname."> remote=".a:remote.")")
+-
+-  " set up the filename
+-  " (lower case the extension, make a local copy of a remote file)
+-  let exten= substitute(a:fname,'.*\.\(.\{-}\)','\1','e')
+-  if has("win32") || has("win95") || has("win64") || has("win16")
+-   let exten= substitute(exten,'^.*$','\L&\E','')
+-  endif
+-  let fname= escape(a:fname,"%#")
+-"  call Decho("fname<".fname."> after escape()")
++" s:NetrwRemoteRm: remove/delete a remote file or directory {{{2
++fun! s:NetrwRemoteRm(usrhost,path) range
++"  call Dfunc("s:NetrwRemoteRm(usrhost<".a:usrhost."> path<".a:path.">) virtcol=".virtcol("."))
++"  call Decho("firstline=".a:firstline." lastline=".a:lastline)
++  let svpos= netrw#NetrwSavePosn()
+ 
+-  " seems kde systems often have gnome-open due to dependencies, even though
+-  " gnome-open's subsidiary display tools are largely absent.  Kde systems
+-  " usually have "kdeinit" running, though...  (tnx Mikolaj Machowski)
+-  if !exists("s:haskdeinit")
+-   if has("unix")
+-    let s:haskdeinit= s:System("system",'ps -e') =~ 'kdeinit'
+-    if v:shell_error
+-     let s:haskdeinit = 0
++  let all= 0
++  if exists("s:netrwmarkfilelist")
++   " remove all marked files
++   for fname in s:netrwmarkfilelist
++    let ok= s:NetrwRemoteRmFile(a:path,fname,all)
++    if ok =~ 'q\%[uit]'
++     break
++    elseif ok =~ 'a\%[ll]'
++     let all= 1
+     endif
+-   else
+-    let s:haskdeinit= 0
+-   endif
+-"   call Decho("setting s:haskdeinit=".s:haskdeinit)
+-  endif
+-
+-  if a:remote == 1
+-   " create a local copy
+-   let fname= fnamemodify(tempname(),":t:r").".".exten
+-"   call Decho("a:remote=".a:remote.": create a local copy of <".a:fname."> as <".fname.">")
+-   exe "silent keepjumps bot 1new ".a:fname
+-   setlocal bh=delete
+-"   call Decho("exe w! ".fname)
+-   exe "w! ".fname
+-   q
+-  endif
+-"  call Decho("exten<".exten."> "."netrwFileHandlers#NFH_".exten."():exists=".exists("*netrwFileHandlers#NFH_".exten))
++   endfor
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
+ 
+-  " set up redirection
+-  if &srr =~ "%s"
+-   let redir= substitute(&srr,"%s","/dev/null","")
+   else
+-   let redir= &srr . "/dev/null"
++   " remove files specified by range
++
++   " preparation for removing multiple files/directories
++   let ctr= a:firstline
++
++   " remove multiple files and directories
++   while ctr <= a:lastline
++    exe ctr
++    let ok= s:NetrwRemoteRmFile(a:path,s:NetrwGetWord(),all)
++    if ok =~ 'q\%[uit]'
++     break
++    elseif ok =~ 'a\%[ll]'
++     let all= 1
++    endif
++    let ctr= ctr + 1
++   endwhile
+   endif
+-"  call Decho("redir{".redir."} srr{".&srr."}")
+ 
+-  " execute the file handler
+-  if exists("g:netrw_browsex_viewer") && g:netrw_browsex_viewer == '-'
+-"  call Decho("g:netrw_browsex_viewer<".g:netrw_browsex_viewer.">")
+-   let ret= netrwFileHandlers#Invoke(exten,fname)
++  " refresh the (remote) directory listing
++"  call Decho("refresh remote directory listing")
++  call s:NetrwRefresh(0,s:NetrwBrowseChgDir(0,'./'))
++  call netrw#NetrwRestorePosn(svpos)
+ 
+-  elseif exists("g:netrw_browsex_viewer") && executable(g:netrw_browsex_viewer)
+-"   call Decho("g:netrw_browsex_viewer<".g:netrw_browsex_viewer.">")
+-"   call Decho("exe silent !".g:netrw_browsex_viewer." '".escape(fname,'%#')."' ".redir)
+-   exe "silent !".g:netrw_browsex_viewer." '".escape(fname,'%#')."'".redir
+-   let ret= v:shell_error
++"  call Dret("s:NetrwRemoteRm")
++endfun
+ 
+-  elseif has("win32") || has("win64")
+-"   call Decho('exe silent !start rundll32 url.dll,FileProtocolHandler "'.escape(fname, '%#').'"')
+-   exe 'silent !start rundll32 url.dll,FileProtocolHandler "'.escape(fname, '%#').'"'
+-   call inputsave()|call input("Press <cr> to continue")|call inputrestore()
+-   let ret= v:shell_error
++" ---------------------------------------------------------------------
++" s:NetrwRemoteRmFile: {{{2
++fun! s:NetrwRemoteRmFile(path,rmfile,all)
++"  call Dfunc("s:NetrwRemoteRmFile(path<".a:path."> rmfile<".a:rmfile.">) all=".a:all)
+ 
+-  elseif has("unix") && executable("gnome-open") && !s:haskdeinit
+-"   call Decho("exe silent !gnome-open '".escape(fname,'%#')."' ".redir)
+-   exe "silent !gnome-open '".escape(fname,'%#')."'".redir
+-   let ret= v:shell_error
++  let all= a:all
++  let ok = ""
+ 
+-  elseif has("unix") && executable("kfmclient") && s:haskdeinit
+-"   call Decho("exe silent !kfmclient exec '".escape(fname,'%#')."' ".redir)
+-   exe "silent !kfmclient exec '".escape(fname,'%#')."' ".redir
+-   let ret= v:shell_error
++  if a:rmfile !~ '^"' && (a:rmfile =~ '@$' || a:rmfile !~ '[\/]$')
++   " attempt to remove file
++"    call Decho("attempt to remove file (all=".all.")")
++   if !all
++    echohl Statement
++    call inputsave()
++    let ok= input("Confirm deletion of file<".a:rmfile."> ","[{y(es)},n(o),a(ll),q(uit)] ")
++    call inputrestore()
++    echohl NONE
++    if ok == ""
++     let ok="no"
++    endif
++    let ok= substitute(ok,'\[{y(es)},n(o),a(ll),q(uit)]\s*','','e')
++    if ok =~ 'a\%[ll]'
++     let all= 1
++    endif
++   endif
++
++   if all || ok =~ 'y\%[es]' || ok == ""
++    if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
++     silent! keepjumps .,$d
++     call s:NetrwRemoteFtpCmd(a:path,"delete ".a:rmfile)
++    else
++     let netrw_rm_cmd= s:MakeSshCmd(g:netrw_rm_cmd)
++"     call Decho("netrw_rm_cmd<".netrw_rm_cmd.">")
++     if !exists("b:netrw_curdir")
++      call netrw#ErrorMsg(s:ERROR,"for some reason b:netrw_curdir doesn't exist!",53)
++      let ok="q"
++     else
++      let remotedir= substitute(b:netrw_curdir,'^.*//[^/]\+/\(.*\)$','\1','')
++"      call Decho("netrw_rm_cmd<".netrw_rm_cmd.">")
++"      call Decho("remotedir<".remotedir.">")
++"      call Decho("rmfile<".a:rmfile.">")
++      if remotedir != ""
++       let netrw_rm_cmd= netrw_rm_cmd." ".remotedir.escape(a:rmfile,g:netrw_cd_escape)
++      else
++       let netrw_rm_cmd= netrw_rm_cmd." ".escape(a:rmfile,g:netrw_cd_escape)
++      endif
++"      call Decho("call system(".netrw_rm_cmd.")")
++      let ret= system(netrw_rm_cmd)
++      if ret != 0
++       call netrw#ErrorMsg(s:WARNING,"cmd<".netrw_rm_cmd."> failed",60)
++      endif
++"      call Decho("returned=".ret." errcode=".v:shell_error)
++     endif
++    endif
++   elseif ok =~ 'q\%[uit]'
++    break
++   endif
+ 
+   else
+-   " netrwFileHandlers#Invoke() always returns 0
+-   let ret= netrwFileHandlers#Invoke(exten,fname)
+-  endif
++   " attempt to remove directory
++"    call Decho("attempt to remove directory")
++   if !all
++    call inputsave()
++    let ok= input("Confirm deletion of directory<".a:rmfile."> ","[{y(es)},n(o),a(ll),q(uit)] ")
++    call inputrestore()
++    if ok == ""
++     let ok="no"
++    endif
++    let ok= substitute(ok,'\[{y(es)},n(o),a(ll),q(uit)]\s*','','e')
++    if ok =~ 'a\%[ll]'
++     let all= 1
++    endif
++   endif
+ 
+-  " if unsuccessful, attempt netrwFileHandlers#Invoke()
+-  if ret
+-   let ret= netrwFileHandlers#Invoke(exten,fname)
+-  endif
++   if all || ok =~ 'y\%[es]' || ok == ""
++    if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
++     call s:NetrwRemoteFtpCmd(a:path,"rmdir ".a:rmfile)
++    else
++     let rmfile          = substitute(a:path.a:rmfile,'/$','','')
++     let netrw_rmdir_cmd = s:MakeSshCmd(g:netrw_rmdir_cmd).' '.rmfile
++"      call Decho("attempt to remove dir: system(".netrw_rmdir_cmd.")")
++     let ret= s:System("system",netrw_rmdir_cmd)
++"      call Decho("returned=".ret." errcode=".v:shell_error)
+ 
+-  redraw!
++     if v:shell_error != 0
++"       call Decho("v:shell_error not 0")
++      let netrw_rmf_cmd= s:MakeSshCmd(g:netrw_rmf_cmd).' '.substitute(rmfile,'[\/]$','','e')
++"       call Decho("2nd attempt to remove dir: system(".netrw_rmf_cmd.")")
++      let ret= s:System("system",netrw_rmf_cmd)
++"       call Decho("returned=".ret." errcode=".v:shell_error)
+ 
+-  " cleanup: remove temporary file,
+-  "          delete current buffer if success with handler,
+-  "          return to prior buffer (directory listing)
+-  if a:remote == 1 && fname != a:fname
+-"   call Decho("deleting temporary file<".fname.">")
+-   call s:System("delete",fname)
+-  endif
++      if v:shell_error != 0 && !exists("g:netrw_quiet")
++      	call netrw#ErrorMsg(s:ERROR,"unable to remove directory<".rmfile."> -- is it empty?",22)
++      endif
++     endif
++    endif
+ 
+-  if a:remote == 1
+-   setlocal bh=delete bt=nofile
+-   if g:netrw_use_noswf
+-    setlocal noswf
++   elseif ok =~ 'q\%[uit]'
++    break
+    endif
+-   exe "norm! \<c-o>"
+-   redraw!
+   endif
+ 
+-"  call Dret("NetBrowseX")
++"  call Dret("s:NetrwRemoteRmFile ".ok)
++  return ok
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetBrowseFtpCmd: unfortunately, not all ftp servers honor options for ls {{{2
++" s:NetrwRemoteFtpCmd: unfortunately, not all ftp servers honor options for ls {{{2
+ "  This function assumes that a long listing will be received.  Size, time,
+ "  and reverse sorts will be requested of the server but not otherwise
+ "  enforced here.
+-fun! s:NetBrowseFtpCmd(path,listcmd)
+-"  call Dfunc("NetBrowseFtpCmd(path<".a:path."> listcmd<".a:listcmd.">) netrw_method=".w:netrw_method)
++fun! s:NetrwRemoteFtpCmd(path,listcmd)
++"  call Dfunc("NetrwRemoteFtpCmd(path<".a:path."> listcmd<".a:listcmd.">) netrw_method=".w:netrw_method)
+ "  call Decho("line($)=".line("$")." bannercnt=".w:netrw_bannercnt)
+ 
+   " because WinXX ftp uses unix style input
+@@ -2979,7 +4178,7 @@
+   exe "silent! keepjumps ".w:netrw_bannercnt.",$d"
+ 
+   ".........................................
+-  if w:netrw_method == 2 || w:netrw_method == 5 
++  if w:netrw_method == 2 || w:netrw_method == 5
+    " ftp + <.netrc>:  Method #2
+    if a:path != ""
+     put ='cd \"'.a:path.'\"'
+@@ -2989,13 +4188,13 @@
+ "    call Decho("filter input: ".getline("."))
+    endif
+    exe "put ='".a:listcmd."'"
+-"   exe w:netrw_bannercnt.',$g/^./call Decho("ftp#".line(".").": ".getline("."))'
++"   exe "keepjumps ".w:netrw_bannercnt.',$g/^./call Decho("ftp#".line(".").": ".getline("."))'
+    if exists("g:netrw_port") && g:netrw_port != ""
+ "    call Decho("exe ".g:netrw_silentxfer.w:netrw_bannercnt.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine." ".g:netrw_port)
+-    exe g:netrw_silentxfer.w:netrw_bannercnt.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine." ".g:netrw_port
++    exe g:netrw_silentxfer." keepjumps ".w:netrw_bannercnt.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine." ".g:netrw_port
+    else
+ "    call Decho("exe ".g:netrw_silentxfer.w:netrw_bannercnt.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine)
+-    exe g:netrw_silentxfer.w:netrw_bannercnt.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine
++    exe g:netrw_silentxfer." keepjumps ".w:netrw_bannercnt.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine
+    endif
+ 
+    ".........................................
+@@ -3010,9 +4209,9 @@
+ 
+     if exists("g:netrw_ftp") && g:netrw_ftp == 1
+      put =g:netrw_uid
+-     put ='\"'.g:netrw_passwd.'\"'
++     put ='\"'.s:netrw_passwd.'\"'
+     else
+-     put ='user \"'.g:netrw_uid.'\" \"'.g:netrw_passwd.'\"'
++     put ='user \"'.g:netrw_uid.'\" \"'.s:netrw_passwd.'\"'
+     endif
+ 
+    if a:path != ""
+@@ -3062,98 +4261,92 @@
+ 
+   " restore settings
+   let &ff= ffkeep
+-"  call Dret("NetBrowseFtpCmd")
++"  call Dret("NetrwRemoteFtpCmd")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetListHide: uses [range]g~...~d to delete files that match comma {{{2
+-" separated patterns given in g:netrw_list_hide
+-fun! s:NetListHide()
+-"  call Dfunc("NetListHide() hide=".g:netrw_hide." listhide<".g:netrw_list_hide.">")
+-
+-  " find a character not in the "hide" string to use as a separator for :g and :v commands
+-  " How-it-works: take the hiding command, convert it into a range.  Duplicate
+-  " characters don't matter.  Remove all such characters from the '/~...90'
+-  " string.  Use the first character left as a separator character.
+-  let listhide= g:netrw_list_hide
+-  let sep     = strpart(substitute('/~@#$%^&*{};:,<.>?|1234567890','['.escape(listhide,'-]^\').']','','ge'),1,1)
+-"  call Decho("sep=".sep)
+-
+-  while listhide != ""
+-   if listhide =~ ','
+-    let hide     = substitute(listhide,',.*$','','e')
+-    let listhide = substitute(listhide,'^.\{-},\(.*\)$','\1','e')
+-   else
+-    let hide     = listhide
+-    let listhide= ""
+-   endif
+-
+-   " Prune the list by hiding any files which match
+-   if g:netrw_hide == 1
+-"    call Decho("hiding<".hide."> listhide<".listhide.">")
+-    exe 'silent keepjumps '.w:netrw_bannercnt.',$g'.sep.hide.sep.'d'
+-   elseif g:netrw_hide == 2
+-"    call Decho("showing<".hide."> listhide<".listhide.">")
+-    exe 'silent keepjumps '.w:netrw_bannercnt.',$g'.sep.hide.sep.'s@^@ /-KEEP-/ @'
+-   endif
+-  endwhile
+-  if g:netrw_hide == 2
+-   exe 'silent keepjumps '.w:netrw_bannercnt.',$v@^ /-KEEP-/ @d'
+-   exe 'silent keepjumps '.w:netrw_bannercnt.',$s@^\%( /-KEEP-/ \)\+@@e'
+-  endif
+-
+-"  call Dret("NetListHide")
+-endfun
++" s:NetrwRemoteRename: rename a remote file or directory {{{2
++fun! s:NetrwRemoteRename(usrhost,path) range
++"  call Dfunc("NetrwRemoteRename(usrhost<".a:usrhost."> path<".a:path.">)")
+ 
+-" ---------------------------------------------------------------------
+-" NetHideEdit: allows user to edit the file/directory hiding list
+-fun! s:NetHideEdit(islocal)
+-"  call Dfunc("NetHideEdit(islocal=".a:islocal.")")
++  " preparation for removing multiple files/directories
++  let svpos      = netrw#NetrwSavePosn()
++  let ctr        = a:firstline
++  let rename_cmd = s:MakeSshCmd(g:netrw_rename_cmd)
+ 
+-  " save current cursor position
+-  let s:nhe_curpos= getpos(".")
++  " rename files given by the markfilelist
++  if exists("s:netrwmarkfilelist")
++   for oldname in s:netrwmarkfilelist
++"    call Decho("oldname<".oldname.">")
++    if exists("subfrom")
++     let newname= substitute(oldname,subfrom,subto,'')
++"     call Decho("subfrom<".subfrom."> subto<".subto."> newname<".newname.">")
++    else
++     call inputsave()
++     let newname= input("Moving ".oldname." to : ",oldname)
++     call inputrestore()
++     if newname =~ '^s/'
++      let subfrom = substitute(newname,'^s/\([^/]*\)/.*/$','\1','')
++      let subto   = substitute(newname,'^s/[^/]*/\(.*\)/$','\1','')
++      let newname = substitute(oldname,subfrom,subto,'')
++"      call Decho("subfrom<".subfrom."> subto<".subto."> newname<".newname.">")
++     endif
++    endif
++   
++    if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
++     call s:NetrwRemoteFtpCmd(a:path,"rename ".oldname." ".newname)
++    else
++     let oldname= a:path.oldname
++     let newname= a:path.newname
++"     call Decho("system(rename_cmd".' "'.escape(oldname," ").'" "'.escape(newname,g:netrw_cd_escape).'"')
++     let ret= s:System("system",rename_cmd.' "'.escape(oldname,g:netrw_cd_escape).'" "'.escape(newname,g:netrw_cd_escape).'"')
++    endif
+ 
+-  " get new hiding list from user
+-  call inputsave()
+-  let newhide= input("Edit Hiding List: ",g:netrw_list_hide)
+-  call inputrestore()
+-  let g:netrw_list_hide= newhide
+-"  call Decho("new g:netrw_list_hide<".g:netrw_list_hide.">")
++   endfor
++   2match none
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
+ 
+-  " refresh the listing
+-  silent call s:NetRefresh(a:islocal,s:NetBrowseChgDir(a:islocal,"./"))
++  else
+ 
+-  " restore cursor position
+-  call setpos('.',s:nhe_curpos)
+-  unlet s:nhe_curpos
++  " attempt to rename files/directories
++   while ctr <= a:lastline
++    exe "keepjumps ".ctr
+ 
+-"  call Dret("NetHideEdit")
+-endfun
++    let oldname= s:NetrwGetWord()
++"   call Decho("oldname<".oldname.">")
+ 
+-" ---------------------------------------------------------------------
+-" NetSortSequence: allows user to edit the sorting sequence
+-fun! s:NetSortSequence(islocal)
+-"  call Dfunc("NetSortSequence(islocal=".a:islocal.")")
++    call inputsave()
++    let newname= input("Moving ".oldname." to : ",oldname)
++    call inputrestore()
+ 
+-  call inputsave()
+-  let newsortseq= input("Edit Sorting Sequence: ",g:netrw_sort_sequence)
+-  call inputrestore()
++    if exists("w:netrw_method") && (w:netrw_method == 2 || w:netrw_method == 3)
++     call s:NetrwRemoteFtpCmd(a:path,"rename ".oldname." ".newname)
++    else
++     let oldname= a:path.oldname
++     let newname= a:path.newname
++"    call Decho("system(rename_cmd".' "'.escape(oldname," ").'" "'.escape(newname,g:netrw_cd_escape).'"')
++     let ret= s:System("system",rename_cmd.' "'.escape(oldname,g:netrw_cd_escape).'" "'.escape(newname,g:netrw_cd_escape).'"')
++    endif
+ 
+-  " refresh the listing
+-  let g:netrw_sort_sequence= newsortseq
+-  call netrw#NetSavePosn()
+-  call s:NetRefresh(a:islocal,s:NetBrowseChgDir(a:islocal,'./'))
++    let ctr= ctr + 1
++   endwhile
++  endif
+ 
+-"  call Dret("NetSortSequence")
++  " refresh the directory
++  call s:NetrwRefresh(0,s:NetrwBrowseChgDir(0,'./'))
++  call netrw#NetrwRestorePosn(svpos)
++
++"  call Dret("NetrwRemoteRename")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-"  NetListStyle: {{{2
++"  s:NetrwListStyle: {{{2
+ "  islocal=0: remote browsing
+ "         =1: local browsing
+-fun! s:NetListStyle(islocal)
+-"  call Dfunc("NetListStyle(islocal=".a:islocal.") w:netrw_liststyle=".w:netrw_liststyle)
+-  let fname             = s:NetGetWord()
++fun! s:NetrwListStyle(islocal)
++"  call Dfunc("NetrwListStyle(islocal=".a:islocal.") w:netrw_liststyle=".w:netrw_liststyle)
++  let fname             = s:NetrwGetWord()
+   if !exists("w:netrw_liststyle")|let w:netrw_liststyle= g:netrw_liststyle|endif
+   let w:netrw_liststyle = (w:netrw_liststyle + 1) % s:MAXLIST
+ "  call Decho("fname<".fname.">")
+@@ -3187,31 +4380,32 @@
+   endif
+   setlocal ma noro
+ 
+-  " clear buffer - this will cause NetBrowse/LocalBrowseCheck to do a refresh
++  " clear buffer - this will cause NetrwBrowse/LocalBrowseCheck to do a refresh
+ "  call Decho("clear buffer<".expand("%")."> with :%d")
+   %d
+ 
+   " refresh the listing
+-  call netrw#NetSavePosn()
+-  call s:NetRefresh(a:islocal,s:NetBrowseChgDir(a:islocal,'./'))
++  let svpos= netrw#NetrwSavePosn()
++  call s:NetrwRefresh(a:islocal,s:NetrwBrowseChgDir(a:islocal,'./'))
++  call netrw#NetrwRestorePosn(svpos)
+ 
+   " keep cursor on the filename
+   silent keepjumps $
+   let result= search('\%(^\%(|\+\s\)\=\|\s\{2,}\)\zs'.escape(fname,'.\[]*$^').'\%(\s\{2,}\|$\)','bc')
+ "  call Decho("search result=".result." w:netrw_bannercnt=".(exists("w:netrw_bannercnt")? w:netrw_bannercnt : 'N/A'))
+   if result <= 0 && exists("w:netrw_bannercnt")
+-   exe w:netrw_bannercnt
++   exe "keepjumps ".w:netrw_bannercnt
+   endif
+ 
+-"  call Dret("NetListStyle".(exists("w:netrw_liststyle")? ' : w:netrw_liststyle='.w:netrw_liststyle : ""))
++"  call Dret("NetrwListStyle".(exists("w:netrw_liststyle")? ' : w:netrw_liststyle='.w:netrw_liststyle : ""))
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetWideListing: {{{2
+-fun! s:NetWideListing()
++" s:NetrwWideListing: {{{2
++fun! s:NetrwWideListing()
+ 
+   if w:netrw_liststyle == s:WIDELIST
+-"   call Dfunc("NetWideListing() w:netrw_liststyle=".w:netrw_liststyle.' fo='.&fo.' l:fo='.&l:fo)
++"   call Dfunc("NetrwWideListing() w:netrw_liststyle=".w:netrw_liststyle.' fo='.&fo.' l:fo='.&l:fo)
+    " look for longest filename (cpf=characters per filename)
+    " cpf: characters per file
+    " fpl: files per line
+@@ -3221,7 +4415,7 @@
+    if line("$") >= w:netrw_bannercnt
+     exe 'silent keepjumps '.w:netrw_bannercnt.',$g/^./if virtcol("$") > b:netrw_cpf|let b:netrw_cpf= virtcol("$")|endif'
+    else
+-"    call Dret("NetWideListing")
++"    call Dret("NetrwWideListing")
+     return
+    endif
+ "   call Decho("max file strlen+1=".b:netrw_cpf)
+@@ -3256,16 +4450,16 @@
+    silent! let @*= keepregstar
+    exe "silent keepjumps ".w:netrw_bannercnt.',$s/\s\+$//e'
+    setlocal noma nomod ro
+-"   call Dret("NetWideListing")
++"   call Dret("NetrwWideListing")
+   endif
+ 
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetTreeDir: determine tree directory given current cursor position {{{2
++" s:NetrwTreeDir: determine tree directory given current cursor position {{{2
+ " (full path directory with trailing slash returned)
+-fun! s:NetTreeDir()
+-"  call Dfunc("NetTreeDir() curline#".line(".")."<".getline(".")."> b:netrw_curdir<".b:netrw_curdir."> tab#".tabpagenr()." win#".winnr()." buf#".bufnr("%")."<".bufname("%").">")
++fun! s:NetrwTreeDir()
++"  call Dfunc("NetrwTreeDir() curline#".line(".")."<".getline(".")."> b:netrw_curdir<".b:netrw_curdir."> tab#".tabpagenr()." win#".winnr()." buf#".bufnr("%")."<".bufname("%").">")
+ 
+   let treedir= b:netrw_curdir
+ "  call Decho("set initial treedir<".treedir.">")
+@@ -3288,7 +4482,7 @@
+     " now force a refresh
+ "    call Decho("clear buffer<".expand("%")."> with :%d")
+     keepjumps %d
+-"    call Dret("NetTreeDir <".treedir."> : (side effect) s:treecurpos<".string(s:treecurpos).">")
++"    call Dret("NetrwTreeDir <".treedir."> : (side effect) s:treecurpos<".string(s:treecurpos).">")
+     return b:netrw_curdir
+    endif
+ 
+@@ -3322,14 +4516,14 @@
+ "  setlocal ma noro
+ "  keepjumps %d
+ 
+-"  call Dret("NetTreeDir <".treedir."> : (side effect) s:treecurpos<".string(s:treecurpos).">")
++"  call Dret("NetrwTreeDir <".treedir."> : (side effect) s:treecurpos<".string(s:treecurpos).">")
+   return treedir
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetTreeDisplay: recursive tree display {{{2
+-fun! s:NetTreeDisplay(dir,depth)
+-"  call Dfunc("NetTreeDisplay(dir<".a:dir."> depth<".a:depth.">)")
++" s:NetrwTreeDisplay: recursive tree display {{{2
++fun! s:NetrwTreeDisplay(dir,depth)
++"  call Dfunc("NetrwTreeDisplay(dir<".a:dir."> depth<".a:depth.">)")
+ 
+   " insure that there are no folds
+   setlocal nofen
+@@ -3366,23 +4560,23 @@
+ "   call Decho("dir<".dir."> entry<".entry."> direntry<".direntry.">")
+    if entry =~ '/$' && has_key(w:netrw_treedict,direntry)
+ "    call Decho("<".direntry."> is a key in treedict - display subtree for it")
+-    call s:NetTreeDisplay(direntry,depth)
++    call s:NetrwTreeDisplay(direntry,depth)
+    elseif entry =~ '/$' && has_key(w:netrw_treedict,direntry.'/')
+ "    call Decho("<".direntry."/> is a key in treedict - display subtree for it")
+-    call s:NetTreeDisplay(direntry.'/',depth)
++    call s:NetrwTreeDisplay(direntry.'/',depth)
+    else
+ "    call Decho("<".entry."> is not a key in treedict (no subtree)")
+     call setline(line("$")+1,depth.entry)
+    endif
+   endfor
+-"  call Dret("NetTreeDisplay")
++"  call Dret("NetrwTreeDisplay")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetTreeListing: displays tree listing from treetop on down, using NetTreeDisplay() {{{2
+-fun! s:NetTreeListing(dirname)
++" s:NetrwTreeListing: displays tree listing from treetop on down, using NetrwTreeDisplay() {{{2
++fun! s:NetrwTreeListing(dirname)
+   if w:netrw_liststyle == s:TREELIST
+-"   call Dfunc("NetTreeListing() bufname<".expand("%").">")
++"   call Dfunc("NetrwTreeListing() bufname<".expand("%").">")
+ "   call Decho("curdir<".a:dirname.">")
+ 
+    " update the treetop
+@@ -3390,7 +4584,7 @@
+    if !exists("w:netrw_treetop")
+     let w:netrw_treetop= a:dirname
+ "    call Decho("w:netrw_treetop<".w:netrw_treetop."> (reusing)")
+-   elseif (w:netrw_treetop =~ ('^'.a:dirname) && strlen(a:dirname) < strlen(w:netrw_treetop)) || a:dirname !~ ('^'.w:netrw_treetop)
++   elseif (w:netrw_treetop =~ ('^'.a:dirname) && s:Strlen(a:dirname) < s:Strlen(w:netrw_treetop)) || a:dirname !~ ('^'.w:netrw_treetop)
+     let w:netrw_treetop= a:dirname
+ "    call Decho("w:netrw_treetop<".w:netrw_treetop."> (went up)")
+    endif
+@@ -3416,45 +4610,45 @@
+    endif
+ 
+    " display from treetop on down
+-   call s:NetTreeDisplay(w:netrw_treetop,"")
++   call s:NetrwTreeDisplay(w:netrw_treetop,"")
+ 
+    " place cursor
+    if !exists("s:nbcd_curpos")
+     if fname != ""
+-"     call Decho("(NetTreeListing) place cursor <".fname.">")
++"     call Decho("(NetrwTreeListing) place cursor <".fname.">")
+      call search('\<'.fname.'\>','cw')
+     elseif exists("w:netrw_bannercnt")
+-     exe (w:netrw_bannercnt+1)
+-"     call Decho("(NetTreeListing) place cursor line#".(w:netrw_bannercnt+1))
++     exe "keepjumps ".(w:netrw_bannercnt+1)
++"     call Decho("(NetrwTreeListing) place cursor line#".(w:netrw_bannercnt+1))
+     endif
+    endif
+ 
+-"   call Dret("NetTreeListing : bufname<".expand("%").">")
++"   call Dret("NetrwTreeListing : bufname<".expand("%").">")
+   endif
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetSaveWordPosn: used by the "s" command in both remote and local {{{2
+-" browsing.  Along with NetRestoreWordPosn(), it keeps the cursor on
++" s:NetrwSaveWordPosn: used by the "s" command in both remote and local {{{2
++" browsing.  Along with NetrwRestoreWordPosn(), it keeps the cursor on
+ " the same word even though the sorting has changed its order of appearance.
+-fun! s:NetSaveWordPosn()
+-"  call Dfunc("NetSaveWordPosn()")
+-  let s:netrw_saveword= '^'.escape(getline("."),s:netrw_cd_escape).'$'
+-"  call Dret("NetSaveWordPosn : saveword<".s:netrw_saveword.">")
++fun! s:NetrwSaveWordPosn()
++"  call Dfunc("NetrwSaveWordPosn()")
++  let s:netrw_saveword= '^'.escape(getline("."),g:netrw_cd_escape).'$'
++"  call Dret("NetrwSaveWordPosn : saveword<".s:netrw_saveword.">")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetRestoreWordPosn: used by the "s" command; see NetSaveWordPosn() above {{{2
+-fun! s:NetRestoreWordPosn()
+-"  call Dfunc("NetRestoreWordPosn()")
++" s:NetrwRestoreWordPosn: used by the "s" command; see NetrwSaveWordPosn() above {{{2
++fun! s:NetrwRestoreWordPosn()
++"  call Dfunc("NetrwRestoreWordPosn()")
+   silent! call search(s:netrw_saveword,'w')
+-"  call Dret("NetRestoreWordPosn")
++"  call Dret("NetrwRestoreWordPosn")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetMakeDir: this function makes a directory (both local and remote) {{{2
+-fun! s:NetMakeDir(usrhost)
+-"  call Dfunc("NetMakeDir(usrhost<".a:usrhost.">)")
++" s:NetrwMakeDir: this function makes a directory (both local and remote) {{{2
++fun! s:NetrwMakeDir(usrhost)
++"  call Dfunc("NetrwMakeDir(usrhost<".a:usrhost.">)")
+ 
+   " get name of new directory from user.  A bare <CR> will skip.
+   " if its currently a directory, also request will be skipped, but with
+@@ -3465,7 +4659,7 @@
+ "  call Decho("newdirname<".newdirname.">")
+ 
+   if newdirname == ""
+-"   call Dret("NetMakeDir : user aborted with bare <cr>")
++"   call Dret("NetrwMakeDir : user aborted with bare <cr>")
+    return
+   endif
+ 
+@@ -3479,14 +4673,14 @@
+     if !exists("g:netrw_quiet")
+      call netrw#ErrorMsg(s:WARNING,"<".newdirname."> is already a directory!",24)
+     endif
+-"    call Dret("NetMakeDir : directory<".newdirname."> exists previously")
++"    call Dret("NetrwMakeDir : directory<".newdirname."> exists previously")
+     return
+    endif
+    if s:FileReadable(fullnewdir)
+     if !exists("g:netrw_quiet")
+      call netrw#ErrorMsg(s:WARNING,"<".newdirname."> is already a file!",25)
+     endif
+-"    call Dret("NetMakeDir : file<".newdirname."> exists previously")
++"    call Dret("NetrwMakeDir : file<".newdirname."> exists previously")
+     return
+    endif
+ 
+@@ -3495,23 +4689,23 @@
+    if exists("*mkdir")
+     call mkdir(fullnewdir,"p")
+    else
+-    let netrw_origdir= s:NetGetcwd(1)
++    let netrw_origdir= s:NetrwGetcwd(1)
+     exe 'keepjumps cd '.b:netrw_curdir
+ "    call Decho("netrw_origdir<".netrw_origdir.">: cd b:netrw_curdir<".b:netrw_curdir.">")
+ "    call Decho("exe silent! !".g:netrw_local_mkdir.' '.g:netrw_shq.newdirname.g:netrw_shq)
+     exe "silent! !".g:netrw_local_mkdir.' '.g:netrw_shq.newdirname.g:netrw_shq
+-    if !g:netrw_keepdir | exe 'keepjumps cd '.netrw_origdir | endif
+     if !g:netrw_keepdir
+      exe 'keepjumps cd '.netrw_origdir
+-"     call Decho("netrw_keepdir=".g:netrw_keepdir.": cd ".netrw_origdir)
++"     call Decho("netrw_keepdir=".g:netrw_keepdir.": cd ".netrw_origdir." getcwd<".getcwd().">")
+     endif
+    endif
+ 
+    if v:shell_error == 0
+     " refresh listing
+ "    call Decho("refresh listing")
+-    call netrw#NetSavePosn()
+-    call s:NetRefresh(1,s:NetBrowseChgDir(1,'./'))
++    let svpos= netrw#NetrwSavePosn()
++    call s:NetrwRefresh(1,s:NetrwBrowseChgDir(1,'./'))
++    call netrw#NetrwRestorePosn(svpos)
+    elseif !exists("g:netrw_quiet")
+     call netrw#ErrorMsg(s:ERROR,"unable to make directory<".newdirname.">",26)
+    endif
+@@ -3525,27 +4719,28 @@
+    exe "silent! !".mkdircmd." ".g:netrw_shq.newdirname.g:netrw_shq
+    if v:shell_error == 0
+     " refresh listing
+-    call netrw#NetSavePosn()
+-    call s:NetRefresh(0,s:NetBrowseChgDir(0,'./'))
++    let svpos= netrw#NetrwSavePosn()
++    call s:NetrwRefresh(0,s:NetrwBrowseChgDir(0,'./'))
++    call netrw#NetrwRestorePosn(svpos)
+    elseif !exists("g:netrw_quiet")
+     call netrw#ErrorMsg(s:ERROR,"unable to make directory<".newdirname.">",27)
+    endif
+    redraw!
+   endif
+ 
+-"  call Dret("NetMakeDir")
++"  call Dret("NetrwMakeDir")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-"  NetBookmarkDir: {{{2
++"  s:NetrwBookmarkDir: {{{2
+ "    0: (user: <b>)   bookmark current directory
+ "    1: (user: <B>)   change to the bookmarked directory
+ "    2: (user: <q>)   list bookmarks
+ "    3: (browsing)    record current directory history
+ "    4: (user: <u>)   go up   (previous) bookmark
+ "    5: (user: <U>)   go down (next)     bookmark
+-fun! s:NetBookmarkDir(chg,curdir)
+-"  call Dfunc("NetBookmarkDir(chg=".a:chg." curdir<".a:curdir.">) cnt=".v:count." bookmarkcnt=".g:NETRW_BOOKMARKMAX." histcnt=".g:NETRW_DIRHIST_CNT." bookmax=".g:NETRW_BOOKMARKMAX." histmax=".g:netrw_dirhistmax)
++fun! s:NetrwBookmarkDir(chg,curdir)
++"  call Dfunc("NetrwBookmarkDir(chg=".a:chg." curdir<".a:curdir.">) cnt=".v:count." bookmarkcnt=".g:NETRW_BOOKMARKMAX." histcnt=".g:NETRW_DIRHIST_CNT." bookmax=".g:NETRW_BOOKMARKMAX." histmax=".g:netrw_dirhistmax)
+ 
+   if a:chg == 0
+    " bookmark the current directory
+@@ -3666,17 +4861,20 @@
+     echo "Sorry, no successor directory exists yet"
+    endif
+   endif
+-  call s:NetBookmarkMenu()
+-"  call Dret("NetBookmarkDir")
++  call s:NetrwBookmarkMenu()
++"  call Dret("NetrwBookmarkDir")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetBookmarkMenu: {{{2
+-fun! s:NetBookmarkMenu()
++" s:NetrwBookmarkMenu: Uses menu priorities {{{2
++"                      .2.[cnt] for bookmarks, and
++"                      .3.[cnt] for history
++"                      (see s:NetrwMenu())
++fun! s:NetrwBookmarkMenu()
+   if !exists("s:netrw_menucnt")
+    return
+   endif
+-"  call Dfunc("NetBookmarkMenu() bookmarkcnt=".g:NETRW_BOOKMARKMAX." histcnt=".g:NETRW_DIRHIST_CNT." menucnt=".s:netrw_menucnt)
++"  call Dfunc("NetrwBookmarkMenu() bookmarkcnt=".g:NETRW_BOOKMARKMAX." histcnt=".g:NETRW_DIRHIST_CNT." menucnt=".s:netrw_menucnt)
+   if has("menu") && has("gui_running") && &go =~ 'm'
+    if exists("g:NetrwTopLvlMenu")
+     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Bookmark'
+@@ -3712,213 +4910,64 @@
+     endif
+    endwhile
+   endif
+-"  call Dret("NetBookmarkMenu")
+-endfun
+-
+-" ---------------------------------------------------------------------
+-" NetObtain: obtain file under cursor (for remote browsing support) {{{2
+-fun! netrw#NetObtain(vismode,...) range
+-"  call Dfunc("NetObtain(vismode=".a:vismode.") a:0=".a:0)
+-
+-  if a:vismode == 0
+-   " normal mode
+-   let fname= expand("<cWORD>")
+-"   call Decho("no arguments, use <".fname.">")
+-  elseif a:vismode == 1
+-   " visual mode
+-   let keeprega = @a
+-   norm! gv"ay
+-   if g:netrw_liststyle == s:THINLIST
+-    " thin listing
+-    let filelist= split(@a,'\n')
+-   elseif g:netrw_liststyle == s:LONGLIST
+-    " long listing
+-    let filelist= split(substitute(@a,'\t.\{-}\n','\n','g'),'\n')
+-   else
+-    " wide listing
+-	let filelist = split(substitute(@a,'\s\{2,}','\n','g'),'\n')
+-	let filelist = map(filelist,'substitute(v:val,"^\\s\\+","","")')
+-	let filelist = map(filelist,'substitute(v:val,"\\s\\+$","","")')
+-   endif
+-"   call Decho("filelist<".string(filelist).">")
+-   let @a= keeprega
+-   for f in filelist
+-    if f != ""
+-     call netrw#NetObtain(2,f)
+-    endif
+-   endfor
+-"   call Dret("NetObtain : visual mode handler")
+-   return
+-  elseif a:vismode == 2
+-   " multiple file mode
+-   let fname= a:1
+-"   call Decho("visual mode handling: <".fname.">")
+-  endif
+-
+-  " NetrwStatusLine support - for obtaining support
+-  call s:SetupNetrwStatusLine('%f %h%m%r%=%9*Obtaining '.fname)
+-
+-  if exists("w:netrw_method") && w:netrw_method =~ '[235]'
+-"   call Decho("method=".w:netrw_method)
+-   if executable("ftp")
+-"    call Decho("ftp is executable, method=".w:netrw_method)
+-    let curdir = b:netrw_curdir
+-    let path   = substitute(curdir,'ftp://[^/]\+/','','e')
+-    let curline= line(".")
+-    let endline= line("$")+1
+-    setlocal ma noro
+-    keepjumps $
+-"    call Decho("getcwd<".getcwd().">")
+-"    call Decho("curdir<".curdir.">")
+-"    call Decho("path<".path.">")
+-"    call Decho("curline=".curline)
+-"    call Decho("endline=".endline)
+-
+-    ".........................................
+-    if w:netrw_method == 2
+-     " ftp + <.netrc>: Method #2
+-     setlocal ff=unix
+-     if path != ""
+-      put ='cd '.path
+-"      call Decho("ftp:  cd ".path)
+-     endif
+-     put ='get '.fname
+-"     call Decho("ftp:  get ".fname)
+-     put ='quit'
+-"     call Decho("ftp:  quit")
+-     if exists("g:netrw_port") && g:netrw_port != ""
+-"      call Decho("exe ".g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine." ".g:netrw_port)
+-      exe g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine." ".g:netrw_port
+-     else
+-"      call Decho("exe ".g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine)
+-      exe g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i ".g:netrw_machine
+-     endif
+-
+-   ".........................................
+-  elseif w:netrw_method == 3
+-   " ftp + machine,id,passwd,filename: Method #3
+-    setlocal ff=unix
+-    if exists("g:netrw_port") && g:netrw_port != ""
+-     put ='open '.g:netrw_machine.' '.g:netrw_port
+-"     call Decho('ftp:  open '.g:netrw_machine.' '.g:netrw_port)
+-    else
+-     put ='open '.g:netrw_machine
+-"     call Decho('ftp:  open '.g:netrw_machine)
+-    endif
+-
+-    if exists("g:netrw_ftp") && g:netrw_ftp == 1
+-     put =g:netrw_uid
+-     put ='\"'.g:netrw_passwd.'\"'
+-"     call Decho('ftp:  g:netrw_uid')
+-"     call Decho('ftp:  g:netrw_passwd')
+-    else
+-     put ='user \"'.g:netrw_uid.'\" \"'.g:netrw_passwd.'\"'
+-"     call Decho('user '.g:netrw_uid.' '.g:netrw_passwd)
+-    endif
+-
+-   if path != ""
+-    put ='cd '.path
+-"    call Decho('cd '.a:path)
+-   endif
+-   put ='get '.fname
+-"   call Decho("ftp:  get ".fname)
+-   put ='quit'
+-"   call Decho("ftp:  quit")
+-
+-    " perform ftp:
+-    " -i       : turns off interactive prompting from ftp
+-    " -n  unix : DON'T use <.netrc>, even though it exists
+-    " -n  win32: quit being obnoxious about password
+-"    call Decho("exe ".g:netrw_silentxfer.curline.",$!".g:netrw_ftp_cmd." -i -n")
+-    exe g:netrw_silentxfer.endline.",$!".g:netrw_ftp_cmd." -i -n"
+-
+-    ".........................................
+-    else
+-     call netrw#ErrorMsg(s:WARNING,"unable to comply with your request<" . choice . ">",28)
+-    endif
+-    " restore
+-    exe "silent! ".endline.",$d"
+-    exe "keepjumps ".curline
+-    setlocal noma nomod ro
+-   else
+-"    call Decho("ftp not executable")
+-    if !exists("g:netrw_quiet")
+-     call netrw#ErrorMsg(s:ERROR,"this system doesn't support ftp",29)
+-    endif
+-    " restore status line
+-    let &stl        = s:netrw_users_stl
+-    let &laststatus = s:netrw_users_ls
+-    " restore NetMethod
+-    if exists("keep_netrw_method")
+-     call s:NetMethod(keep_netrw_choice)
+-     let w:netrw_method  = keep_netrw_wmethod
+-    endif
+-"    call Dret("NetObtain")
+-    return
+-   endif
+-
+-  ".........................................
+-  else
+-   " scp: Method#4
+-"   call Decho("using scp")
+-   let curdir = b:netrw_curdir
+-   let path   = substitute(curdir,'scp://[^/]\+/','','e')
+-"   call Decho("path<".path.">")
+-   if exists("g:netrw_port") && g:netrw_port != ""
+-    let useport= " ".g:netrw_scpport." ".g:netrw_port
+-   else
+-    let useport= ""
+-   endif
+-"   call Decho("executing: !".g:netrw_scp_cmd.useport." ".g:netrw_machine.":".path.escape(fname,' ?&')." .")
+-   exe g:netrw_silentxfer."!".g:netrw_scp_cmd.useport." ".g:netrw_machine.":".path.escape(fname,' ?&')." ."
+-   endif
+-  endif
+-
+-  " restore status line
+-  let &stl        = s:netrw_users_stl
+-  let &laststatus = s:netrw_users_ls
+-  redraw!
+-
+-  " restore NetMethod
+-  if exists("keep_netrw_method")
+-   call s:NetMethod(keep_netrw_choice)
+-   let w:netrw_method  = keep_netrw_wmethod
+-  endif
+-
+-"  call Dret("NetObtain")
++"  call Dret("NetrwBookmarkMenu")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetPrevWinOpen: open file/directory in previous window.  {{{2
++" s:NetrwPrevWinOpen: open file/directory in previous window.  {{{2
+ "   If there's only one window, then the window will first be split.
+-fun! s:NetPrevWinOpen(islocal)
+-"  call Dfunc("NetPrevWinOpen(islocal=".a:islocal.")")
++"   Returns:
++"     choice = 0 : didn't have to choose
++"     choice = 1 : saved modified file in window first
++"     choice = 2 : didn't save modified file, opened window
++"     choice = 3 : cancel open
++fun! s:NetrwPrevWinOpen(islocal)
++"  call Dfunc("NetrwPrevWinOpen(islocal=".a:islocal.")")
++
++  " grab a copy of the b:netrw_curdir to pass it along to newly split windows
++  let curdir    = b:netrw_curdir
+ 
+   " get last window number and the word currently under the cursor
+   let lastwinnr = winnr("$")
+-  let curword   = s:NetGetWord()
++  let curword   = s:NetrwGetWord()
++  let choice    = 0
+ "  call Decho("lastwinnr=".lastwinnr." curword<".curword.">")
+ 
+   let didsplit  = 0
+   if lastwinnr == 1
+    " if only one window, open a new one first
+ "   call Decho("only one window, so open a new one (g:netrw_alto=".g:netrw_alto.")")
+-   exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"
++   if g:netrw_preview
++"    call Decho("exe ".(g:netrw_alto? "top " : "bot ")."vert ".g:netrw_winsize."wincmd s")
++    exe (g:netrw_alto? "top " : "bot ")."vert ".g:netrw_winsize."wincmd s"
++   else
++"    call Decho("exe ".(g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s")
++    exe (g:netrw_alto? "bel " : "abo ").g:netrw_winsize."wincmd s"
++   endif
+    let didsplit  = 1
+ 
+   else
++   call s:SaveBufVars()
++"   call Decho("wincmd p")
+    wincmd p
++   call s:RestoreBufVars()
+    " if the previous window's buffer has been changed (is modified),
+    " and it doesn't appear in any other extant window, then ask the
+    " user if s/he wants to abandon modifications therein.
+    let bnr    = winbufnr(0)
+    let bnrcnt = 0
+    if &mod
++"    call Decho("detected: prev window's buffer has been modified: bnr=".bnr." winnr#".winnr())
++    let eikeep= &ei
++    set ei=all
+     windo if winbufnr(0) == bnr | let bnrcnt=bnrcnt+1 | endif
+-"    call Decho("bnr=".bnr." bnrcnt=".bnrcnt)
++    exe bnr."wincmd p"
++    let &ei= eikeep
++"    call Decho("bnr=".bnr." bnrcnt=".bnrcnt." buftype=".&bt." winnr#".winnr())
+     if bnrcnt == 1
+      let bufname= bufname(winbufnr(winnr()))
+      let choice= confirm("Save modified file<".bufname.">?","&Yes\n&No\n&Cancel")
++"     call Decho("bufname<".bufname."> choice=".choice." winnr#".winnr())
+ 
+      if choice == 1
+       " Yes -- write file & then browse
+@@ -3931,14 +4980,15 @@
+        else
+        	wincmd p
+        endif
+-"       call Dret("NetPrevWinOpen : unable to write <".bufname.">")
+-       return
++"       call Dret("NetrwPrevWinOpen ".choice." : unable to write <".bufname.">")
++       return choice
+       endif
+ 
+      elseif choice == 2
+       " No -- don't worry about changed file, just browse anyway
+       setlocal nomod
+-      call netrw#ErrorMsg(s:WARNING,bufname." changes abandoned",31)
++      call netrw#ErrorMsg(s:WARNING,bufname." changes to ".bufname." abandoned",31)
++      wincmd p
+ 
+      else
+       " Cancel -- don't do this
+@@ -3947,62 +4997,83 @@
+       else
+        wincmd p
+       endif
+-"      call Dret("NetPrevWinOpen : cancelled")
+-      return
++"      call Dret("NetrwPrevWinOpen ".choice." : cancelled")
++      return choice
+      endif
+     endif
+    endif
+   endif
+ 
+-  if a:islocal
+-   call netrw#LocalBrowseCheck(s:NetBrowseChgDir(a:islocal,curword))
+-  else
+-   call s:NetBrowse(a:islocal,s:NetBrowseChgDir(a:islocal,curword))
++  " restore b:netrw_curdir (window split/enew may have lost it)
++  let b:netrw_curdir= curdir
++  if a:islocal < 2
++   if a:islocal
++    call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(a:islocal,curword))
++   else
++    call s:NetrwBrowse(a:islocal,s:NetrwBrowseChgDir(a:islocal,curword))
++   endif
+   endif
+-"  call Dret("NetPrevWinOpen")
++"  call Dret("NetrwPrevWinOpen ".choice)
++  return choice
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetMenu: generates the menu for gvim and netrw {{{2
+-fun! s:NetMenu(domenu)
++" s:NetrwMenu: generates the menu for gvim and netrw {{{2
++fun! s:NetrwMenu(domenu)
+ 
+   if !exists("g:NetrwMenuPriority")
+    let g:NetrwMenuPriority= 80
+   endif
+ 
+   if has("menu") && has("gui_running") && &go =~ 'm' && g:netrw_menu
+-"   call Dfunc("NetMenu(domenu=".a:domenu.")")
++"   call Dfunc("NetrwMenu(domenu=".a:domenu.")")
+ 
+    if !exists("s:netrw_menu_enabled") && a:domenu
+ "    call Decho("initialize menu")
+     let s:netrw_menu_enabled= 1
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.1 '.g:NetrwTopLvlMenu.'Help<tab><F1>	<F1>'
+-    call s:NetBookmarkMenu() " provide some history!
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.4 '.g:NetrwTopLvlMenu.'Go\ Up\ Directory<tab>-	-'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.5 '.g:NetrwTopLvlMenu.'Apply\ Special\ Viewer<tab>x	x'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.6 '.g:NetrwTopLvlMenu.'Bookmark\ Current\ Directory<tab>mb	mb'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.7 '.g:NetrwTopLvlMenu.'Goto\ Bookmarked\ Directory<tab>gb	gb'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.8 '.g:NetrwTopLvlMenu.'Change\ To\ Recently\ Used\ Directory<tab>u	u'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.9 '.g:NetrwTopLvlMenu.'Change\ To\ Subsequently\ Used\ Directory<tab>U	U'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.10 '.g:NetrwTopLvlMenu.'Delete\ File/Directory<tab>D	D'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.11 '.g:NetrwTopLvlMenu.'Edit\ File\ Hiding\ List<tab>'."<ctrl-h>	\<c-h>"
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.12 '.g:NetrwTopLvlMenu.'Edit\ File/Directory<tab><cr>	'."\<cr>"
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.13 '.g:NetrwTopLvlMenu.'Edit\ File/Directory,\ New\ Window<tab>o	o'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.14 '.g:NetrwTopLvlMenu.'Edit\ File/Directory,\ New\ Vertical\ Window<tab>v	v'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.15 '.g:NetrwTopLvlMenu.'List\ Bookmarks\ and\ History<tab>q	q'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.16 '.g:NetrwTopLvlMenu.'Listing\ Style\ (thin-long-wide)<tab>i	i'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.17 '.g:NetrwTopLvlMenu.'Make\ Subdirectory<tab>d	d'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.18 '.g:NetrwTopLvlMenu.'Normal-Hide-Show<tab>a	a'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.19 '.g:NetrwTopLvlMenu.'Obtain\ File<tab>O	O'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.20 '.g:NetrwTopLvlMenu.'Preview\ File/Directory<tab>p	p'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.21 '.g:NetrwTopLvlMenu.'Previous\ Window\ Browser<tab>P	P'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.22 '.g:NetrwTopLvlMenu.'Refresh\ Listing<tab>'."<ctrl-l>	\<c-l>"
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.23 '.g:NetrwTopLvlMenu.'Rename\ File/Directory<tab>R	R'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.24 '.g:NetrwTopLvlMenu.'Reverse\ Sorting\ Order<tab>'."r	r"
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.25 '.g:NetrwTopLvlMenu.'Select\ Sorting\ Style<tab>s	s'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.26 '.g:NetrwTopLvlMenu.'Sorting\ Sequence\ Edit<tab>S	S'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.27 '.g:NetrwTopLvlMenu.'Set\ Current\ Directory<tab>c	c'
+-    exe 'silent! menu '.g:NetrwMenuPriority.'.28 '.g:NetrwTopLvlMenu.'Settings/Options<tab>:NetrwSettings	'.":NetrwSettings\<cr>"
++    exe 'silent! menu '.g:NetrwMenuPriority.'.1     '.g:NetrwTopLvlMenu.'Help<tab><F1>	<F1>'
++    call s:NetrwBookmarkMenu() " provide some history!  uses priorities 2,3, reserves 4
++    exe 'silent! menu '.g:NetrwMenuPriority.'.5     '.g:NetrwTopLvlMenu.'-Sep1-	:'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.6     '.g:NetrwTopLvlMenu.'Go\ Up\ Directory<tab>-	-'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.7     '.g:NetrwTopLvlMenu.'Apply\ Special\ Viewer<tab>x	x'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.8.1   '.g:NetrwTopLvlMenu.'Bookmarks\ and\ History.Bookmark\ Current\ Directory<tab>mb	mb'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.8.2   '.g:NetrwTopLvlMenu.'Bookmarks\ and\ History.Goto\ Bookmark<tab>gb	gb'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.8.3   '.g:NetrwTopLvlMenu.'Bookmarks\ and\ History.List<tab>q	q'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.8.4   '.g:NetrwTopLvlMenu.'Bookmarks\ and\ History.Goto\ Prev\ Dir<tab>u	u'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.8.5   '.g:NetrwTopLvlMenu.'Bookmarks\ and\ History.Goto\ Next\ Dir<tab>U	U'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.9.1   '.g:NetrwTopLvlMenu.'Browsing\ Control.Edit\ File\ Hiding\ List<tab>'."<ctrl-h>	\<Plug>NetrwHideEdit"
++    exe 'silent! menu '.g:NetrwMenuPriority.'.9.2   '.g:NetrwTopLvlMenu.'Browsing\ Control.Edit\ Sorting\ Sequence<tab>S	S'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.9.3   '.g:NetrwTopLvlMenu.'Browsing\ Control.Refresh\ Listing<tab>'."<ctrl-l>	\<Plug>NetrwRefresh"
++    exe 'silent! menu '.g:NetrwMenuPriority.'.9.4   '.g:NetrwTopLvlMenu.'Browsing\ Control.Settings/Options<tab>:NetrwSettings	'.":NetrwSettings\<cr>"
++    exe 'silent! menu '.g:NetrwMenuPriority.'.10    '.g:NetrwTopLvlMenu.'Delete\ File/Directory<tab>D	D'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.11.1  '.g:NetrwTopLvlMenu.'Edit\ File/Dir.In\ Current\ Window<tab><cr>	'."\<cr>"
++    exe 'silent! menu '.g:NetrwMenuPriority.'.11.2  '.g:NetrwTopLvlMenu.'Edit\ File/Dir.Preview\ File/Directory<tab>p	p'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.11.3  '.g:NetrwTopLvlMenu.'Edit\ File/Dir.In\ Previous\ Window<tab>P	P'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.11.4  '.g:NetrwTopLvlMenu.'Edit\ File/Dir.In\ New\ Window<tab>o	o'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.11.5  '.g:NetrwTopLvlMenu.'Edit\ File/Dir.In\ New\ Vertical\ Window<tab>v	v'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.12    '.g:NetrwTopLvlMenu.'Make\ Subdirectory<tab>d	d'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.1  '.g:NetrwTopLvlMenu.'Marked\ Files.Mark\ File<tab>mf	mf'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.2  '.g:NetrwTopLvlMenu.'Marked\ Files.Mark\ Files\ by\ Regexp<tab>mr	mr'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.3  '.g:NetrwTopLvlMenu.'Marked\ Files.Hide-Show-List\ Control<tab>a	a'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.4  '.g:NetrwTopLvlMenu.'Marked\ Files.Copy\ To\ Target<tab>mc	mc'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.5  '.g:NetrwTopLvlMenu.'Marked\ Files.Delete<tab>D	D'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.6  '.g:NetrwTopLvlMenu.'Marked\ Files.Diff<tab>md	md'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.7  '.g:NetrwTopLvlMenu.'Marked\ Files.Edit<tab>me	me'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.8  '.g:NetrwTopLvlMenu.'Marked\ Files.Exe\ Cmd<tab>mx	mx'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.9  '.g:NetrwTopLvlMenu.'Marked\ Files.Move\ To\ Target<tab>mm	mm'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.10 '.g:NetrwTopLvlMenu.'Marked\ Files.Obtain<tab>O	O'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.11 '.g:NetrwTopLvlMenu.'Marked\ Files.Print<tab>mp	mp'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.12 '.g:NetrwTopLvlMenu.'Marked\ Files.Replace<tab>R	R'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.13 '.g:NetrwTopLvlMenu.'Marked\ Files.Set\ Target<tab>mt	mt'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.14 '.g:NetrwTopLvlMenu.'Marked\ Files.Tag<tab>mT	mT'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.13.15 '.g:NetrwTopLvlMenu.'Marked\ Files.Zip/Unzip/Compress/Uncompress<tab>mz	mz'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.14    '.g:NetrwTopLvlMenu.'Obtain\ File<tab>O	O'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.16.1  '.g:NetrwTopLvlMenu.'Style.Listing\ Style\ (thin-long-wide-tree)<tab>i	i'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.16.2  '.g:NetrwTopLvlMenu.'Style.Normal-Hide-Show<tab>a	a'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.16.3  '.g:NetrwTopLvlMenu.'Style.Reverse\ Sorting\ Order<tab>'."r	r"
++    exe 'silent! menu '.g:NetrwMenuPriority.'.16.4  '.g:NetrwTopLvlMenu.'Style.Sorting\ Method\ (name-time-size)<tab>s	s'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.17    '.g:NetrwTopLvlMenu.'Rename\ File/Directory<tab>R	R'
++    exe 'silent! menu '.g:NetrwMenuPriority.'.18    '.g:NetrwTopLvlMenu.'Set\ Current\ Directory<tab>c	c'
+     let s:netrw_menucnt= 28
+ 
+    elseif !a:domenu
+@@ -4010,43 +5081,15 @@
+     let curwin     = winnr()
+     windo if getline(2) =~ "Netrw" | let s:netrwcnt= s:netrwcnt + 1 | endif
+     exe curwin."wincmd w"
+-    
++
+     if s:netrwcnt <= 1
+ "     call Decho("clear menus")
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Help'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Apply\ Special\ Viewer'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Bookmark\ Current\ Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Go\ Up\ Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Goto\ Bookmarked\ Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Change\ To\ Recently\ Used\ Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Change\ To\ Subsequently\ Used\ Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Delete\ File/Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Edit\ File/Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Edit\ File/Directory,\ New\ Window'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Edit\ File/Directory,\ New\ Vertical\ Window'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Edit\ File\ Hiding\ List'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Edit\ File'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Enter\ File/Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Enter\ File/Directory\ (vertical\ split)'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'List\ Bookmarks\ and\ History'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Listing\ Style\ (thin-long-wide)'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Make\ Subdirectory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Normal-Hide-Show'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Obtain\ File'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Preview\ File/Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Previous\ Window\ Browser'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Refresh\ Listing'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Rename\ File/Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Reverse\ Sorting\ Order'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Select\ Sorting\ Style'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Sorting\ Sequence\ Edit'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Set\ Current\ Directory'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Settings/Options'
+-     exe 'silent! unmenu '.g:NetrwTopLvlMenu.'Bookmarks'
++     exe 'silent! unmenu '.g:NetrwTopLvlMenu
++"     call Decho('exe silent! unmenu '.g:NetrwTopLvlMenu.'*')
+      silent! unlet s:netrw_menu_enabled
+     endif
+    endif
+-"   call Dret("NetMenu")
++"   call Dret("NetrwMenu")
+   endif
+ 
+ endfun
+@@ -4056,30 +5099,44 @@
+ " ==========================================
+ 
+ " ---------------------------------------------------------------------
+-" LocalBrowseCheck: {{{2
++" netrw#LocalBrowseCheck: {{{2
+ fun! netrw#LocalBrowseCheck(dirname)
+   " unfortunate interaction -- split window debugging can't be
+-"  " used here, must use DechoRemOn or DechoTabOn -- the BufEnter
++  " used here, must use D-echoRemOn or D-echoTabOn -- the BufEnter
+   " event triggers another call to LocalBrowseCheck() when attempts
+   " to write to the DBG buffer are made.
+-"  call Dfunc("LocalBrowseCheck(dirname<".a:dirname.">")
++  " The &ft == "netrw" test was installed because the BufEnter event
++  " would hit when re-entering netrw windows, creating unexpected
++  " refreshes (and would do so in the middle of NetrwSaveOptions(), too)
++"  call Dfunc("netrw#LocalBrowseCheck(dirname<".a:dirname.">")
++"  call Decho("isdir=".isdirectory(a:dirname))
+   if isdirectory(a:dirname)
+-   silent! call s:NetBrowse(1,a:dirname)
++"   call Decho(" ft=".&ft." b:netrw_curdir<".(exists("b:netrw_curdir")? b:netrw_curdir : " doesn't exist")."> dirname<".a:dirname.">"." line($)=".line("$"))
++   if &ft != "netrw" || (exists("b:netrw_curdir") && b:netrw_curdir != a:dirname)
++    silent! call s:NetrwBrowse(1,a:dirname)
++   elseif &ft == "netrw" && line("$") == 1
++    silent! call s:NetrwBrowse(1,a:dirname)
++   endif
+   endif
+-"  call Dret("LocalBrowseCheck")
++"  call Dret("netrw#LocalBrowseCheck")
+   " not a directory, ignore it
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-"  LocalListing: does the job of "ls" for local directories {{{2
++"  s:LocalListing: does the job of "ls" for local directories {{{2
+ fun! s:LocalListing()
+-"  call Dfunc("LocalListing() &ma=".&ma." &mod=".&mod." &ro=".&ro." buf(%)=".buf("%"))
++"  call Dfunc("s:LocalListing()")
++"  call Decho("&ma=".&ma)
++"  call Decho("&mod=".&mod)
++"  call Decho("&ro=".&ro)
++"  call Decho("bufname(%)<".bufname("%").">")
++
+ "  if exists("b:netrw_curdir") |call Decho('b:netrw_curdir<'.b:netrw_curdir.">")  |else|call Decho("b:netrw_curdir doesn't exist") |endif
+ "  if exists("g:netrw_sort_by")|call Decho('g:netrw_sort_by<'.g:netrw_sort_by.">")|else|call Decho("g:netrw_sort_by doesn't exist")|endif
+ 
+   " get the list of files contained in the current directory
+   let dirname    = escape(b:netrw_curdir,s:netrw_glob_escape)
+-  let dirnamelen = strlen(b:netrw_curdir)
++  let dirnamelen = s:Strlen(b:netrw_curdir)
+   let filelist   = glob(s:ComposePath(dirname,"*"))
+ "  call Decho("glob(dirname<".dirname."/*>)=".filelist)
+   if filelist != ""
+@@ -4110,10 +5167,12 @@
+ "   call Decho("remove .. from filelist")
+   endif
+   let filelist= substitute(filelist,'\n\{2,}','\n','ge')
+-  if (has("win32") || has("win95") || has("win64") || has("win16"))
+-   let filelist= substitute(filelist,'\','/','ge')
++  if !g:netrw_cygwin && (has("win32") || has("win95") || has("win64") || has("win16"))
++   " change all \s to /s
++   let filelist= substitute(filelist,'\','/','g')
+   else
+-   let filelist= substitute(filelist,'\','\\','ge')
++   " escape all \s to \\
++   let filelist= substitute(filelist,'\','\\','g')
+   endif
+ 
+ "  call Decho("dirname<".dirname.">")
+@@ -4131,6 +5190,8 @@
+    let pfile= filename
+    if isdirectory(filename)
+     let pfile= filename."/"
++   elseif fnamemodify(filename,":p") != resolve(filename)
++    let pfile= filename."@"
+    endif
+    if pfile =~ '//$'
+     let pfile= substitute(pfile,'//$','/','e')
+@@ -4143,7 +5204,7 @@
+ 
+    if w:netrw_liststyle == s:LONGLIST
+     let sz   = getfsize(filename)
+-    let fsz  = strpart("               ",1,15-strlen(sz)).sz
++    let fsz  = strpart("               ",1,15-s:Strlen(sz)).sz
+     let pfile= pfile."\t".fsz." ".strftime(g:netrw_timefmt,getftime(filename))
+ "    call Decho("sz=".sz." fsz=".fsz)
+    endif
+@@ -4152,7 +5213,7 @@
+     " sort by time (handles time up to 1 quintillion seconds, US)
+ "    call Decho("getftime(".filename.")=".getftime(filename))
+     let t  = getftime(filename)
+-    let ft = strpart("000000000000000000",1,18-strlen(t)).t
++    let ft = strpart("000000000000000000",1,18-s:Strlen(t)).t
+ "    call Decho("exe keepjumps put ='".ft.'/'.filename."'")
+     let ftpfile= ft.'/'.pfile
+     keepjumps silent! put=ftpfile
+@@ -4161,12 +5222,12 @@
+     " sort by size (handles file sizes up to 1 quintillion bytes, US)
+ "    call Decho("getfsize(".filename.")=".getfsize(filename))
+     let sz   = getfsize(filename)
+-    let fsz  = strpart("000000000000000000",1,18-strlen(sz)).sz
++    let fsz  = strpart("000000000000000000",1,18-s:Strlen(sz)).sz
+ "    call Decho("exe keepjumps put ='".fsz.'/'.filename."'")
+     let fszpfile= fsz.'/'.pfile
+     keepjumps silent! put =fszpfile
+ 
+-   else 
++   else
+     " sort by name
+ "    call Decho("exe keepjumps put ='".pfile."'")
+     keepjumps silent! put=pfile
+@@ -4178,11 +5239,11 @@
+   setlocal ts=32
+ "  call Decho("setlocal ts=32")
+ 
+-"  call Dret("LocalListing")
++"  call Dret("s:LocalListing")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" LocalBrowseShellCmdRefresh: this function is called after a user has {{{2
++" s:LocalBrowseShellCmdRefresh: this function is called after a user has {{{2
+ " performed any shell command.  The idea is to cause all local-browsing
+ " buffers to be refreshed after a user has executed some shell command,
+ " on the chance that s/he removed/created a file/directory with it.
+@@ -4213,7 +5274,7 @@
+    elseif index(tabpagebuflist(),ibuf) != -1
+ "    call Decho("refresh buf#".ibuf.'-> win#'.bufwinnr(ibuf))
+     exe bufwinnr(ibuf)."wincmd w"
+-    call s:NetRefresh(1,s:NetBrowseChgDir(1,'./'))
++    call s:NetrwRefresh(1,s:NetrwBrowseChgDir(1,'./'))
+    endif
+    let ibl= ibl + 1
+   endfor
+@@ -4223,169 +5284,229 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" LocalBrowseRm: {{{2
+-fun! s:LocalBrowseRm(path) range
+-"  call Dfunc("LocalBrowseRm(path<".a:path.">)")
++" s:NetrwLocalRm: {{{2
++fun! s:NetrwLocalRm(path) range
++"  call Dfunc("NetrwLocalRm(path<".a:path.">)")
+ "  call Decho("firstline=".a:firstline." lastline=".a:lastline)
+ 
+   " preparation for removing multiple files/directories
+-  let ctr           = a:firstline
+-  let ret           = 0
+-  let all= 0
++  let ret   = 0
++  let all   = 0
++  let svpos = netrw#NetrwSavePosn()
++
++  if exists("s:netrwmarkfilelist")
++   " remove all marked files
++"   call Decho("remove all marked files")
++   for fname in s:netrwmarkfilelist
++    let ok= s:NetrwLocalRmFile(a:path,fname,all)
++    if ok =~ 'q\%[uit]'
++     break
++    elseif ok =~ 'a\%[ll]'
++     let all= 1
++    endif
++   endfor
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++   2match none
++
++  else
++  " remove (multiple) files and directories
++"   call Decho("remove files in range [".a:firstline.",".a:lastline."]")
++
++   let ctr = a:firstline
++   while ctr <= a:lastline
++    exe "keepjumps ".ctr
++
++    " sanity checks
++    if line(".") < w:netrw_bannercnt
++     let ctr= ctr + 1
++     continue
++    endif
++    let curword= s:NetrwGetWord()
++    if curword == "./" || curword == "../"
++     let ctr= ctr + 1
++     continue
++    endif
++    let ok= s:NetrwLocalRmFile(a:path,curword,all)
++    if ok =~ 'q\%[uit]'
++     break
++    elseif ok =~ 'a\%[ll]'
++     let all= 1
++    endif
++    let ctr= ctr + 1
++   endwhile
++  endif
+ 
+-  " remove multiple files and directories
+-  while ctr <= a:lastline
+-   exe "keepjumps ".ctr
++  " refresh the directory
++  call s:NetrwRefresh(1,s:NetrwBrowseChgDir(1,'./'))
++  call netrw#NetrwRestorePosn(svpos)
+ 
+-   " sanity checks
+-   if line(".") < w:netrw_bannercnt
+-    let ctr= ctr + 1
+-    continue
+-   endif
+-   let curword= s:NetGetWord()
+-   if curword == "./" || curword == "../"
+-    let ctr= ctr + 1
+-    continue
+-   endif
++"  call Dret("NetrwLocalRm")
++endfun
+ 
+-   norm! 0
+-   let rmfile= s:ComposePath(a:path,curword)
+-"   call Decho("rmfile<".rmfile.">")
++" ---------------------------------------------------------------------
++" s:NetrwLocalRmFile: remove file fname given the path {{{2
++"                     Give confirmation prompt unless all==1
++fun! s:NetrwLocalRmFile(path,fname,all)
++"  call Dfunc("s:NetrwLocalRmFile(path<".a:path."> fname<".a:fname."> all=".a:all)
++  
++  let all= a:all
++  let ok = ""
++  norm! 0
++  let rmfile= s:ComposePath(a:path,a:fname)
++"  call Decho("rmfile<".rmfile.">")
+ 
+-   if rmfile !~ '^"' && (rmfile =~ '@$' || rmfile !~ '[\/]$')
+-    " attempt to remove file
+-    if !all
+-     echohl Statement
+-     call inputsave()
+-     let ok= input("Confirm deletion of file<".rmfile."> ","[{y(es)},n(o),a(ll),q(uit)] ")
+-     call inputrestore()
+-     echohl NONE
+-     if ok == ""
+-      let ok="no"
+-     endif
++  if rmfile !~ '^"' && (rmfile =~ '@$' || rmfile !~ '[\/]$')
++   " attempt to remove file
++   if !all
++    echohl Statement
++    call inputsave()
++    let ok= input("Confirm deletion of file<".rmfile."> ","[{y(es)},n(o),a(ll),q(uit)] ")
++    call inputrestore()
++    echohl NONE
++    if ok == ""
++     let ok="no"
++    endif
+ "     call Decho("response: ok<".ok.">")
+-     let ok= substitute(ok,'\[{y(es)},n(o),a(ll),q(uit)]\s*','','e')
++    let ok= substitute(ok,'\[{y(es)},n(o),a(ll),q(uit)]\s*','','e')
+ "     call Decho("response: ok<".ok."> (after sub)")
+-     if ok =~ 'a\%[ll]'
+-      let all= 1
+-     endif
++    if ok =~ 'a\%[ll]'
++     let all= 1
+     endif
++   endif
+ 
+-    if all || ok =~ 'y\%[es]' || ok == ""
+-     let ret= s:System("delete",rmfile)
++   if all || ok =~ 'y\%[es]' || ok == ""
++    let ret= s:System("delete",rmfile)
+ "     call Decho("errcode=".v:shell_error." ret=".ret)
+-    elseif ok =~ 'q\%[uit]'
+-     break
+-    endif
++   endif
+ 
+-   else
+-    " attempt to remove directory
+-    if !all
+-     echohl Statement
+-     call inputsave()
+-     let ok= input("Confirm deletion of directory<".rmfile."> ","[{y(es)},n(o),a(ll),q(uit)] ")
+-     call inputrestore()
+-     let ok= substitute(ok,'\[{y(es)},n(o),a(ll),q(uit)]\s*','','e')
+-     if ok == ""
+-      let ok="no"
+-     endif
+-     if ok =~ 'a\%[ll]'
+-      let all= 1
+-     endif
++  else
++   " attempt to remove directory
++   if !all
++    echohl Statement
++    call inputsave()
++    let ok= input("Confirm deletion of directory<".rmfile."> ","[{y(es)},n(o),a(ll),q(uit)] ")
++    call inputrestore()
++    let ok= substitute(ok,'\[{y(es)},n(o),a(ll),q(uit)]\s*','','e')
++    if ok == ""
++     let ok="no"
++    endif
++    if ok =~ 'a\%[ll]'
++     let all= 1
+     endif
+-    let rmfile= substitute(rmfile,'[\/]$','','e')
++   endif
++   let rmfile= substitute(rmfile,'[\/]$','','e')
+ 
+-    if all || ok =~ 'y\%[es]' || ok == ""
++   if all || ok =~ 'y\%[es]' || ok == ""
+ "     call Decho("1st attempt: system(".g:netrw_local_rmdir.' "'.rmfile.'")')
+-     call s:System("system",g:netrw_local_rmdir.' "'.rmfile.'"')
++    call s:System("system",g:netrw_local_rmdir.' "'.rmfile.'"')
+ "     call Decho("v:shell_error=".v:shell_error)
+ 
+-     if v:shell_error != 0
++    if v:shell_error != 0
+ "      call Decho("2nd attempt to remove directory<".rmfile.">")
+-      let errcode= s:System("delete",rmfile)
++     let errcode= s:System("delete",rmfile)
+ "      call Decho("errcode=".errcode)
+ 
+-      if errcode != 0
+-       if has("unix")
++     if errcode != 0
++      if has("unix")
+ "        call Decho("3rd attempt to remove directory<".rmfile.">")
+-        call s:System("system","rm ".rmfile)
+-        if v:shell_error != 0 && !exists("g:netrw_quiet")
++       call s:System("system","rm ".rmfile)
++       if v:shell_error != 0 && !exists("g:netrw_quiet")
+ 	 call netrw#ErrorMsg(s:ERROR,"unable to remove directory<".rmfile."> -- is it empty?",34)
+-endif
+-       elseif !exists("g:netrw_quiet")
+-       	call netrw#ErrorMsg(s:ERROR,"unable to remove directory<".rmfile."> -- is it empty?",35)
+        endif
++      elseif !exists("g:netrw_quiet")
++      	call netrw#ErrorMsg(s:ERROR,"unable to remove directory<".rmfile."> -- is it empty?",35)
+       endif
+      endif
+-
+-    elseif ok =~ 'q\%[uit]'
+-     break
+     endif
+    endif
++  endif
+ 
+-   let ctr= ctr + 1
+-  endwhile
+-
+-  " refresh the directory
+-  let curline= line(".")
+-"  call Decho("refresh the directory")
+-  call s:NetRefresh(1,s:NetBrowseChgDir(1,'./'))
+-  exe curline
+-
+-"  call Dret("LocalBrowseRm")
++"  call Dret("s:NetrwLocalRmFile ".ok)
++  return ok
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" LocalBrowseRename: rename a remote file or directory {{{2
+-fun! s:LocalBrowseRename(path) range
+-"  call Dfunc("LocalBrowseRename(path<".a:path.">)")
++" s:NetrwLocalRename: rename a remote file or directory {{{2
++fun! s:NetrwLocalRename(path) range
++"  call Dfunc("NetrwLocalRename(path<".a:path.">)")
+ 
+   " preparation for removing multiple files/directories
+-  let ctr= a:firstline
++  let ctr  = a:firstline
++  let svpos= netrw#NetrwSavePosn()
+ 
+-  " attempt to rename files/directories
+-  while ctr <= a:lastline
+-   exe "keepjumps ".ctr
++  " rename files given by the markfilelist
++  if exists("s:netrwmarkfilelist")
++   for oldname in s:netrwmarkfilelist
++"    call Decho("oldname<".oldname.">")
++    if exists("subfrom")
++     let newname= substitute(oldname,subfrom,subto,'')
++"     call Decho("subfrom<".subfrom."> subto<".subto."> newname<".newname.">")
++    else
++     call inputsave()
++     let newname= input("Moving ".oldname." to : ",oldname)
++     call inputrestore()
++     if newname =~ '^s/'
++      let subfrom = substitute(newname,'^s/\([^/]*\)/.*/$','\1','')
++      let subto   = substitute(newname,'^s/[^/]*/\(.*\)/$','\1','')
++"      call Decho("subfrom<".subfrom."> subto<".subto."> newname<".newname.">")
++      let newname = substitute(oldname,subfrom,subto,'')
++     endif
++    endif
++    let ret= rename(oldname,newname)
++   endfor
++   2match none
++   unlet s:netrwmarkfilelist
++   unlet s:netrwmarkfilemtch
++  
++  else
+ 
+-   " sanity checks
+-   if line(".") < w:netrw_bannercnt
+-    let ctr= ctr + 1
+-    continue
+-   endif
+-   let curword= s:NetGetWord()
+-   if curword == "./" || curword == "../"
+-    let ctr= ctr + 1
+-    continue
+-   endif
++   " attempt to rename files/directories
++   while ctr <= a:lastline
++    exe "keepjumps ".ctr
+ 
+-   norm! 0
+-   let oldname= s:ComposePath(a:path,curword)
++    " sanity checks
++    if line(".") < w:netrw_bannercnt
++     let ctr= ctr + 1
++     continue
++    endif
++    let curword= s:NetrwGetWord()
++    if curword == "./" || curword == "../"
++     let ctr= ctr + 1
++     continue
++    endif
++
++    norm! 0
++    let oldname= s:ComposePath(a:path,curword)
+ "   call Decho("oldname<".oldname.">")
+ 
+-   call inputsave()
+-   let newname= input("Moving ".oldname." to : ",substitute(oldname,'/*$','','e'))
+-   call inputrestore()
++    call inputsave()
++    let newname= input("Moving ".oldname." to : ",substitute(oldname,'/*$','','e'))
++    call inputrestore()
+ 
+-   let ret= rename(oldname,newname)
++    let ret= rename(oldname,newname)
+ "   call Decho("renaming <".oldname."> to <".newname.">")
+ 
+-   let ctr= ctr + 1
+-  endwhile
++    let ctr= ctr + 1
++   endwhile
++  endif
+ 
+   " refresh the directory
+ "  call Decho("refresh the directory listing")
+-  call netrw#NetSavePosn()
+-  call s:NetRefresh(1,s:NetBrowseChgDir(1,'./'))
+-"  call Dret("LocalBrowseRename")
++  call s:NetrwRefresh(1,s:NetrwBrowseChgDir(1,'./'))
++  call netrw#NetrwRestorePosn(svpos)
++
++"  call Dret("NetrwLocalRename")
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" LocalFastBrowser: handles setting up/taking down fast browsing for the {{{2
+-"                   local browser
+-"     fastbrowse  Local  Remote   Hiding a buffer implies it may be re-used (fast)
+-"  slow   0         D      D      Deleting a buffer implies it will not be re-used (slow)
+-"  med    1         D      H
+-"  fast   2         H      H
++" s:LocalFastBrowser: handles setting up/taking down fast browsing for the local browser {{{2
++"
++"                 Directory Is
++"     fastbrowse  Local  Remote   
++"  slow   0         D      D      D=Deleting a buffer implies it will not be re-used (slow)
++"  med    1         D      H      H=Hiding a buffer implies it may be re-used        (fast)
++"  fast   2         H      H      
+ fun! s:LocalFastBrowser()
+ "  call Dfunc("LocalFastBrowser() g:netrw_fastbrowse=".g:netrw_fastbrowse)
+ 
+@@ -4411,9 +5532,9 @@
+    augroup AuNetrwShellCmd
+     au!
+     if (has("win32") || has("win95") || has("win64") || has("win16"))
+-     au ShellCmdPost *	call s:LocalBrowseShellCmdRefresh()
++     au ShellCmdPost			*	call s:LocalBrowseShellCmdRefresh()
+     else
+-     au ShellCmdPost,FocusGained *	call s:LocalBrowseShellCmdRefresh()
++     au ShellCmdPost,FocusGained	*	call s:LocalBrowseShellCmdRefresh()
+     endif
+    augroup END
+   endif
+@@ -4433,22 +5554,6 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" LocalObtain: copy selected file to current working directory {{{2
+-fun! s:LocalObtain()
+-"  call Dfunc("LocalObtain()")
+-  if exists("b:netrw_curdir") && getcwd() != b:netrw_curdir
+-   let fname= expand("<cWORD>")
+-   let fcopy= readfile(b:netrw_curdir."/".fname,"b")
+-   call writefile(fcopy,getcwd()."/".fname,"b")
+-  elseif !exists("b:netrw_curdir")
+-   call netrw#ErrorMsg(s:ERROR,"local browsing directory doesn't exist!",36)
+-  else
+-   call netrw#ErrorMsg(s:ERROR,"local browsing directory and current directory are identical",37)
+-  endif
+-"  call Dret("LocalObtain")
+-endfun
+-
+-" ---------------------------------------------------------------------
+ " netrw#Explore: launch the local browser in the directory of the current file {{{2
+ "          dosplit==0: the window will be split iff the current file has
+ "                      been modified
+@@ -4526,6 +5631,19 @@
+    endif
+   endif
+ 
++  if dirname =~ '/\*\*/'
++  " handle .../**/...
++"   call Decho("case Explore .../**/...")
++   let prefixdir      = substitute(dirname,'^\(.\{-}\)\*\*.*$','\1','')
++   if prefixdir =~ '^/' || (prefixdir =~ '^\a:/' && (has("win32") || has("win95") || has("win64") || has("win16")))
++    let b:netrw_curdir = prefixdir
++   else
++    let b:netrw_curdir= getcwd().'/'.prefixdir
++   endif
++   let dirname        = substitute(dirname,'^.\{-}\(\*\*/.*\)$','\1','')
++"   call Decho("pwd<".getcwd()."> dirname<".dirname.">")
++  endif
++
+   if dirname =~ '^\*/'
+    " Explore */pattern
+ "   call Decho("case Explore */pattern")
+@@ -4545,14 +5663,19 @@
+ "   call Decho("case Explore Hexplore Vexplore Sexplore")
+    let newdir= substitute(expand("%:p"),'^\(.*[/\\]\)[^/\\]*$','\1','e')
+    if newdir =~ '^scp:' || newdir =~ '^ftp:'
+-"    call Decho("calling NetBrowse(0,newdir<".newdir.">)")
+-    call s:NetBrowse(0,newdir)
++"    call Decho("calling NetrwBrowse(0,newdir<".newdir.">)")
++    call s:NetrwBrowse(0,newdir)
+    else
+     if newdir == ""|let newdir= getcwd()|endif
+ "    call Decho("calling LocalBrowseCheck(newdir<".newdir.">)")
+     call netrw#LocalBrowseCheck(newdir)
+    endif
+-   call search('\<'.substitute(curfile,'^.*/','','e').'\>','cW')
++"   call Decho("curfile<".curfile.">")
++   if has("win32") || has("win95") || has("win64") || has("win16")
++    call search('\<'.substitute(curfile,'^.*[/\\]','','e').'\>','cW')
++   else
++    call search('\<'.substitute(curfile,'^.*/','','e').'\>','cW')
++   endif
+ 
+   elseif dirname =~ '^\*\*/' || a:indx < 0 || dirname =~ '^\*/'
+    " Nexplore, Pexplore, Explore **/... , or Explore */pattern
+@@ -4727,7 +5850,7 @@
+    if !exists("b:netrw_curdir")
+     call netrw#LocalBrowseCheck(getcwd())
+    else
+-    call netrw#LocalBrowseCheck(s:NetBrowseChgDir(1,newdir))
++    call netrw#LocalBrowseCheck(s:NetrwBrowseChgDir(1,newdir))
+    endif
+   endif
+ 
+@@ -4751,7 +5874,7 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" SetupNetrwStatusLine: {{{2
++" s:SetupNetrwStatusLine: {{{2
+ fun! s:SetupNetrwStatusLine(statline)
+ "  call Dfunc("SetupNetrwStatusLine(statline<".a:statline.">)")
+ 
+@@ -4827,24 +5950,24 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" NetGetcwd: get the current directory. {{{2
++" s:NetrwGetcwd: get the current directory. {{{2
+ "   Change backslashes to forward slashes, if any.
+ "   If doesc is true, escape certain troublesome characters
+-fun! s:NetGetcwd(doesc)
+-"  call Dfunc("NetGetcwd(doesc=".a:doesc.")")
++fun! s:NetrwGetcwd(doesc)
++"  call Dfunc("NetrwGetcwd(doesc=".a:doesc.")")
+   let curdir= substitute(getcwd(),'\\','/','ge')
+   if curdir !~ '[\/]$'
+    let curdir= curdir.'/'
+   endif
+   if a:doesc
+-   let curdir= escape(curdir,s:netrw_cd_escape)
++   let curdir= escape(curdir,g:netrw_cd_escape)
+   endif
+-"  call Dret("NetGetcwd <".curdir.">")
++"  call Dret("NetrwGetcwd <".curdir.">")
+   return curdir
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" SetSort: sets up the sort based on the g:netrw_sort_sequence {{{2
++" s:SetSort: sets up the sort based on the g:netrw_sort_sequence {{{2
+ "          What this function does is to compute a priority for the patterns
+ "          in the g:netrw_sort_sequence.  It applies a substitute to any
+ "          "files" that satisfy each pattern, putting the priority / in
+@@ -4910,16 +6033,18 @@
+ " Support Functions: {{{1
+ 
+ " ---------------------------------------------------------------------
+-"  ComposePath: Appends a new part to a path taking different systems into consideration {{{2
++"  s:ComposePath: Appends a new part to a path taking different systems into consideration {{{2
+ fun! s:ComposePath(base,subdir)
+ "  call Dfunc("s:ComposePath(base<".a:base."> subdir<".a:subdir.">)")
+   if(has("amiga"))
+-   let ec = a:base[strlen(a:base)-1]
++   let ec = a:base[s:Strlen(a:base)-1]
+    if ec != '/' && ec != ':'
+     let ret = a:base . "/" . a:subdir
+    else
+     let ret = a:base . a:subdir
+    endif
++  elseif a:subdir =~ '^\a:[/\\][^/\\]' && (has("win32") || has("win95") || has("win64") || has("win16"))
++   let ret= a:subdir
+   elseif a:base =~ '^\a\+://'
+    let urlbase = substitute(a:base,'^\(\a\+://.\{-}/\)\(.*\)$','\1','')
+    let curpath = substitute(a:base,'^\(\a\+://.\{-}/\)\(.*\)$','\2','')
+@@ -4929,6 +6054,10 @@
+ "   call Decho("ret<".ret.">")
+   else
+    let ret = substitute(a:base."/".a:subdir,"//","/","g")
++   if a:base =~ '^//'
++    " keeping initial '//' for the benefit of network share listing support
++    let ret= '/'.ret
++   endif
+   endif
+ "  call Dret("s:ComposePath ".ret)
+   return ret
+@@ -4939,7 +6068,7 @@
+ "   0=note     = s:NOTE
+ "   1=warning  = s:WARNING
+ "   2=error    = s:ERROR
+-"   Mar 19, 2007 : max errnum currently is 49
++"  Sep 17, 2007 : max errnum currently is 60
+ fun! netrw#ErrorMsg(level,msg,errnum)
+ "  call Dfunc("netrw#ErrorMsg(level=".a:level." msg<".a:msg."> errnum=".a:errnum.") g:netrw_use_errorwindow=".g:netrw_use_errorwindow)
+ 
+@@ -4955,9 +6084,9 @@
+    " (default) netrw creates a one-line window to show error/warning
+    " messages (reliably displayed)
+ 
+-   " record current window number for NetRestorePosn()'s benefit
++   " record current window number for NetrwRestorePosn()'s benefit
+    let s:winBeforeErr= winnr()
+- 
++
+    " getting messages out reliably is just plain difficult!
+    " This attempt splits the current window, creating a one line window.
+    if bufexists("NetrwMessage") && bufwinnr("NetrwMessage") > 0
+@@ -5034,28 +6163,30 @@
+    " get a brand new temporary filename
+    let tmpfile= tempname()
+ "   call Decho("tmpfile<".tmpfile."> : from tempname()")
+- 
++
+    let tmpfile= escape(substitute(tmpfile,'\','/','ge'),g:netrw_tmpfile_escape)
+ "   call Decho("tmpfile<".tmpfile."> : chgd any \\ -> /")
+- 
++
+    " sanity check -- does the temporary file's directory exist?
+    if !isdirectory(substitute(tmpfile,'[^/]\+$','','e'))
+     call netrw#ErrorMsg(s:ERROR,"your <".substitute(tmpfile,'[^/]\+$','','e')."> directory is missing!",2)
+ "    call Dret("s:GetTempfile getcwd<".getcwd().">")
+     return ""
+    endif
+- 
++
+    " let netrw#NetSource() know about the tmpfile
+    let s:netrw_tmpfile= tmpfile " used by netrw#NetSource()
+ "   call Decho("tmpfile<".tmpfile."> s:netrw_tmpfile<".s:netrw_tmpfile.">")
+- 
++
+    " o/s dependencies
+-   if g:netrw_cygwin == 1
++   if g:netrw_cygwin != 0
+     let tmpfile = substitute(tmpfile,'^\(\a\):','/cygdrive/\1','e')
+    elseif has("win32") || has("win95") || has("win64") || has("win16")
+-    let tmpfile = substitute(tmpfile,'/','\\','g')
++    if !exists("+shellslash") || !&ssl
++     let tmpfile = substitute(tmpfile,'/','\','g')
++    endif
+    else
+-    let tmpfile = tmpfile  
++    let tmpfile = tmpfile
+    endif
+    let b:netrw_tmpfile= tmpfile
+ "   call Decho("o/s dependent fixed tempname<".tmpfile.">")
+@@ -5086,7 +6217,7 @@
+ 
+ "  call Dret("s:GetTempfile <".tmpfile.">")
+   return tmpfile
+-endfun  
++endfun
+ 
+ " ---------------------------------------------------------------------
+ " s:MakeSshCmd: transforms input command using USEPORT HOSTNAME into {{{2
+@@ -5106,11 +6237,36 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
++" s:RemoteSystem: runs a command on a remote host using ssh {{{2
++"                 Returns status
++fun! s:RemoteSystem(cmd)
++"  call Dfunc("s:RemoteSystem(cmd<".a:cmd.">)")
++  if !executable(g:netrw_ssh_cmd)
++   call netrw#ErrorMsg(s:ERROR,"g:netrw_ssh_cmd<".g:netrw_ssh_cmd."> is not executable!",52)
++  elseif !exists("b:netrw_curdir")
++   call netrw#ErrorMsg(s:ERROR,"for some reason b:netrw_curdir doesn't exist!",53)
++  else
++   let cmd      = s:MakeSshCmd(g:netrw_ssh_cmd." USEPORT HOSTNAME")
++   let remotedir= substitute(b:netrw_curdir,'^.*//[^/]\+/\(.*\)$','\1','')
++   if remotedir != ""
++    let cmd= cmd.' "cd '."'".remotedir."';"
++   else
++    let cmd= cmd.' "'
++   endif
++   let cmd= cmd.a:cmd.'"'
++"   call Decho("call system(".cmd.")")
++   let ret= system(cmd)
++  endif
++"  call Dret("s:RemoteSystem ".ret)
++  return ret
++endfun
++
++" ---------------------------------------------------------------------
+ " s:NetrwEnew: opens a new buffer, passes netrw buffer variables through {{{2
+ fun! s:NetrwEnew(curdir)
+ "  call Dfunc("s:NetrwEnew(curdir<".a:curdir.">) buf#".bufnr("%")."<".bufname("%").">")
+ 
+-  " grab a function-local copy of buffer variables
++  " grab a function-local-variable copy of buffer variables
+   if exists("b:netrw_bannercnt")      |let netrw_bannercnt       = b:netrw_bannercnt      |endif
+   if exists("b:netrw_browser_active") |let netrw_browser_active  = b:netrw_browser_active |endif
+   if exists("b:netrw_cpf")            |let netrw_cpf             = b:netrw_cpf            |endif
+@@ -5128,6 +6284,7 @@
+   if exists("b:netrw_option")         |let netrw_option          = b:netrw_option         |endif
+   if exists("b:netrw_prvdir")         |let netrw_prvdir          = b:netrw_prvdir         |endif
+ 
++  call s:NetrwOptionRestore("w:")
+   if getline(2) =~ '^" Netrw Directory Listing'
+ "   call Decho("generate a buffer with keepjumps keepalt enew! (1)")
+    keepjumps keepalt enew!
+@@ -5135,8 +6292,9 @@
+ "   call Decho("generate a buffer with keepjumps enew! (2)")
+    keepjumps enew!
+   endif
++  call s:NetrwOptionSave("w:")
+ 
+-  " copy function-local variables to buffer variable equivalents
++  " copy function-local-variables to buffer variable equivalents
+   if exists("netrw_bannercnt")      |let b:netrw_bannercnt       = netrw_bannercnt      |endif
+   if exists("netrw_browser_active") |let b:netrw_browser_active  = netrw_browser_active |endif
+   if exists("netrw_cpf")            |let b:netrw_cpf             = netrw_cpf            |endif
+@@ -5158,6 +6316,8 @@
+   if b:netrw_curdir =~ '/$'
+    if exists("w:netrw_liststyle") && w:netrw_liststyle == s:TREELIST
+     file NetrwTreeListing
++    nno <silent> <buffer> [	:silent call <SID>TreeListMove('[')<cr>
++    nno <silent> <buffer> ]	:silent call <SID>TreeListMove(']')<cr>
+    else
+     exe "silent! file ".b:netrw_curdir
+    endif
+@@ -5205,7 +6365,7 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" s:RestoreWinVars: (used by Explore() and NetSplit()) {{{2
++" s:RestoreWinVars: (used by Explore() and NetrwSplit()) {{{2
+ fun! s:RestoreWinVars()
+ "  call Dfunc("s:RestoreWinVars()")
+   if exists("s:bannercnt")      |let w:netrw_bannercnt       = s:bannercnt      |unlet s:bannercnt      |endif
+@@ -5245,7 +6405,7 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" s:SaveWinVars: (used by Explore() and NetSplit()) {{{2
++" s:SaveWinVars: (used by Explore() and NetrwSplit()) {{{2
+ fun! s:SaveWinVars()
+ "  call Dfunc("s:SaveWinVars()")
+   if exists("w:netrw_bannercnt")      |let s:bannercnt       = w:netrw_bannercnt      |endif
+@@ -5270,7 +6430,7 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" s:SetBufWinVars: (used by NetBrowse() and LocalBrowseCheck()) {{{2
++" s:SetBufWinVars: (used by NetrwBrowse() and LocalBrowseCheck()) {{{2
+ "   To allow separate windows to have their own activities, such as
+ "   Explore **/pattern, several variables have been made window-oriented.
+ "   However, when the user splits a browser window (ex: ctrl-w s), these
+@@ -5292,6 +6452,45 @@
+ endfun
+ 
+ " ---------------------------------------------------------------------
++" s:SetRexDir: set directory for :Rexplore {{{2
++fun! s:SetRexDir(islocal,dirname)
++"  call Dfunc("s:SetRexDir(islocal=".a:islocal." dirname<".a:dirname.">)")
++  " set up Rex and leftmouse-double-click
++  if a:islocal
++   exe 'com! Rexplore call netrw#LocalBrowseCheck("'.escape(a:dirname,g:netrw_cd_escape).'")'
++   if g:netrw_retmap
++    silent! unmap <2-leftmouse>
++    if !hasmapto("<Plug>NetrwReturn")
++     nmap <unique> <silent> <2-leftmouse>	<Plug>NetrwReturn
++    endif
++    exe 'nnoremap <silent> <Plug>NetrwReturn :call netrw#LocalBrowseCheck("'.a:dirname.'")<cr>'
++   endif
++  else
++   exe 'com! Rexplore call s:NetrwBrowse(0,"'.escape(a:dirname,g:netrw_cd_escape).'")'
++   if g:netrw_retmap
++    silent! unmap <2-leftmouse>
++    if !hasmapto("<Plug>NetrwReturn")
++     nmap <unique> <silent> <2-leftmouse>	<Plug>NetrwReturn
++    endif
++    exe 'nnoremap <silent> <Plug>NetrwReturn :call <SID>NetrwBrowse(0,"'.a:dirname.'")<cr>'
++   endif
++  endif
++"  call Dret("s:SetRexDir")
++endfun
++
++" ---------------------------------------------------------------------
++" s:Strlen: this function returns the length of a string, even if its {{{1
++"           using two-byte etc characters.  Depends on virtcol().
++"           Currently, its only used if g:Align_xstrlen is set to a
++"           nonzero value.
++fun! s:Strlen(x)
++"  call Dfunc("s:Strlen(x<".a:x.">")
++  let ret= strlen(substitute(a:x,'.','c','g'))
++"  call Dret("s:Strlen ".ret)
++  return ret
++endfun
++
++" ---------------------------------------------------------------------
+ " s:System: using Steve Hall's idea to insure that Windows paths stay {{{2
+ "              acceptable.  No effect on Unix paths.
+ "  Examples of use:  let result= s:System("system",path)
+@@ -5300,7 +6499,7 @@
+ "  call Dfunc("s:System(cmd<".a:cmd."> path<".a:path.">)")
+ 
+   let path = a:path
+-  if (has("win32") || has("win95") || has("win64") || has("win16"))
++  if !g:netrw_cygwin && (has("win32") || has("win95") || has("win64") || has("win16"))
+    " system call prep
+    " remove trailing slash (Win95)
+    let path = substitute(path, '\(\\\|/\)$', '', 'g')
+@@ -5320,13 +6519,68 @@
+    exe "let result= ".a:cmd."('".path."')"
+   endif
+ 
+-"  call Decho("result<".result.">")
+-"  call Dret("s:System")
++"  call Dret("s:System result<".result.">")
+   return result
+ endfun
+ 
+ " ---------------------------------------------------------------------
+-" s:UseBufWinVars: (used by NetBrowse() and LocalBrowseCheck() {{{2
++" s:TreeListMove: {{{2
++fun! s:TreeListMove(dir)
++"  call Dfunc("s:TreeListMove(dir<".a:dir.">)")
++  let curline  = getline(".")
++  let prvline  = (line(".") > 1)?         getline(line(".")-1) : ''
++  let nxtline  = (line(".") < line("$"))? getline(line(".")+1) : ''
++  let curindent= substitute(curline,'^\([| ]*\).\{-}$','\1','')
++  let indentm1 = substitute(curindent,'^| ','','')
++"  call Decho("prvline  <".prvline."> #".line(".")-1)
++"  call Decho("curline  <".curline."> #".line("."))
++"  call Decho("nxtline  <".nxtline."> #".line(".")+1)
++"  call Decho("curindent<".curindent.">")
++"  call Decho("indentm1 <".indentm1.">")
++
++  if curline !~ '/$'
++"   call Decho('regfile')
++   if     a:dir == '[' && prvline != ''
++    norm! 0
++    let nl = search('^'.indentm1.'[^|]','bWe')    " search backwards from regular file
++"    call Decho("regfile srch back: ".nl)
++   elseif a:dir == ']' && nxtline != ''
++    norm! $
++    let nl = search('^'.indentm1.'[^|]','We')     " search forwards from regular file
++"    call Decho("regfile srch fwd: ".nl)
++   endif
++
++  elseif a:dir == '[' && prvline != ''
++   norm! 0
++   let curline= line(".")
++   let nl     = search('^'.curindent.'[^|]','bWe') " search backwards From directory, same indentation
++"   call Decho("dir srch back ind: ".nl)
++   if nl != 0
++    if line(".") == curline-1
++     let nl= search('^'.indentm1.'[^|]','bWe')     " search backwards from directory, indentation - 1
++"     call Decho("dir srch back ind-1: ".nl)
++    endif
++   endif
++
++  elseif a:dir == ']' && nxtline != ''
++   norm! $
++   let curline = line(".")
++   let nl      = search('^'.curindent.'[^|]','We') " search forwards from directory, same indentation
++"   call Decho("dir srch fwd ind: ".nl)
++   if nl != 0
++    if line(".") == curline+1
++     let nl= search('^'.indentm1.'[^|]','We')         " search forwards from directory, indentation - 1
++"     call Decho("dir srch fwd ind-1: ".nl)
++    endif
++   endif
++
++  endif
++
++"  call Dret("s:TreeListMove")
++endfun
++
++" ---------------------------------------------------------------------
++" s:UseBufWinVars: (used by NetrwBrowse() and LocalBrowseCheck() {{{2
+ "              Matching function to BufferWinVars()
+ fun! s:UseBufWinVars()
+ "  call Dfunc("s:UseBufWinVars()")
+Index: vim/runtime/autoload/netrwSettings.vim
+===================================================================
+--- vim/runtime/autoload/netrwSettings.vim.orig
++++ vim/runtime/autoload/netrwSettings.vim
+@@ -1,7 +1,7 @@
+ " netrwSettings.vim: makes netrw settings simpler
+-" Date:		Mar 26, 2007
++" Date:		Jun 04, 2007
+ " Maintainer:	Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
+-" Version:	9
++" Version:	11
+ " Copyright:    Copyright (C) 1999-2007 Charles E. Campbell, Jr. {{{1
+ "               Permission is hereby granted to use and distribute this code,
+ "               with or without modifications, provided that this copyright
+@@ -19,13 +19,13 @@
+ if exists("g:loaded_netrwSettings") || &cp
+   finish
+ endif
+-let g:loaded_netrwSettings  = "v9"
++let g:loaded_netrwSettings  = "v11"
+ 
+ " ---------------------------------------------------------------------
+ " NetrwSettings: {{{1
+ fun! netrwSettings#NetrwSettings()
+   " this call is here largely just to insure that netrw has been loaded
+-  call netrw#NetSavePosn()
++  call netrw#NetrwSavePosn()
+   if !exists("g:loaded_netrw")
+    echohl WarningMsg | echomsg "***sorry*** netrw needs to be loaded prior to using NetrwSettings" | echohl None
+    return
+@@ -101,6 +101,11 @@
+   else
+    put = 'let g:netrw_browsex_viewer    = (not defined)'
+   endif
++  let cdescline= line("$")
++  put ='let g:netrw_cd_escape...'
++  put = 'let g:netrw_compress          = '.g:netrw_compress
++  let decompressline= line("$")
++  put ='let g:netrw_decompress...'
+   put = 'let g:netrw_dirhistmax        = '.g:netrw_dirhistmax
+   put = 'let g:netrw_fastbrowse        = '.g:netrw_fastbrowse
+   put = 'let g:netrw_ftp_browse_reject = '.g:netrw_ftp_browse_reject
+@@ -111,12 +116,15 @@
+   put = 'let g:netrw_keepdir           = '.g:netrw_keepdir
+   put = 'let g:netrw_list_cmd          = '.g:netrw_list_cmd
+   put = 'let g:netrw_list_hide         = '.g:netrw_list_hide
++  put = 'let g:netrw_liststyle         = '.g:netrw_liststyle
++  put = 'let g:netrw_localcopycmd      = '.g:netrw_localcopycmd
+   put = 'let g:netrw_local_mkdir       = '.g:netrw_local_mkdir
++  put = 'let g:netrw_localmovecmd      = '.g:netrw_localmovecmd
+   put = 'let g:netrw_local_rmdir       = '.g:netrw_local_rmdir
+-  put = 'let g:netrw_liststyle         = '.g:netrw_liststyle
+   put = 'let g:netrw_maxfilenamelen    = '.g:netrw_maxfilenamelen
+   put = 'let g:netrw_menu              = '.g:netrw_menu
+   put = 'let g:netrw_mkdir_cmd         = '.g:netrw_mkdir_cmd
++  put = 'let g:netrw_preview           = '.g:netrw_preview
+   put = 'let g:netrw_rename_cmd        = '.g:netrw_rename_cmd
+   put = 'let g:netrw_rm_cmd            = '.g:netrw_rm_cmd
+   put = 'let g:netrw_rmdir_cmd         = '.g:netrw_rmdir_cmd
+@@ -142,13 +150,15 @@
+   silent %s/= $/= ''/e
+   1
+ 
+-  " Put in shq setting.
++  " Put in g:netrw_shq setting and g:netrw_cd_escape
+   " (deferred so as to avoid the quote manipulation just preceding)
+   if g:netrw_shq == "'"
+    call setline(shqline,'let g:netrw_shq               = "'.g:netrw_shq.'"')
+   else
+    call setline(shqline,"let g:netrw_shq               = '".g:netrw_shq."'")
+   endif
++  call setline(cdescline,"let g:netrw_cd_escape         = ".'"'.escape(g:netrw_cd_escape,'\"').'"')
++  call setline(decompressline,"let g:netrw_decompress        = ".substitute(string(g:netrw_decompress),"^'\\(.*\\)'$",'\1',''))
+ 
+   set nomod
+ 
+Index: vim/runtime/doc/pi_netrw.txt
+===================================================================
+--- vim/runtime/doc/pi_netrw.txt.orig
++++ vim/runtime/doc/pi_netrw.txt
+@@ -1,4 +1,4 @@
+-*pi_netrw.txt*  For Vim version 7.1.  Last change: 2007 May 08
++*pi_netrw.txt*  For Vim version 7.1.  Last change: 2008 Jan 15
+ 
+ 	    -----------------------------------------------------
+ 	    NETRW REFERENCE MANUAL    by Charles E. Campbell, Jr.
+@@ -10,84 +10,79 @@
+ *ftp*           *netrw.vim*     *Nsource*       *rsync*    *sftp*
+ 
+ ==============================================================================
+-1. Contents						*netrw-contents*
++1. Contents						*netrw-contents* {{{1
+ 
+ 1.  Contents.............................................|netrw-contents|
+ 2.  Starting With Netrw..................................|netrw-start|
+ 3.  Netrw Reference......................................|netrw-ref|
+-      CONTROLLING EXTERNAL APPLICATIONS..................|netrw-externapp|
++      EXTERNAL APPLICATIONS AND PROTOCOLS................|netrw-externapp|
+       READING............................................|netrw-read|
+       WRITING............................................|netrw-write|
+       DIRECTORY LISTING..................................|netrw-dirlist|
+       CHANGING THE USERID AND PASSWORD...................|netrw-chgup|
+-      VARIABLES..........................................|netrw-variables|
++      VARIABLES AND SETTINGS.............................|netrw-variables|
+       PATHS..............................................|netrw-path|
+ 4.  Network-Oriented File Transfer.......................|netrw-xfer|
+       NETRC..............................................|netrw-netrc|
+       PASSWORD...........................................|netrw-passwd|
+ 5.  Activation...........................................|netrw-activate|
+-6.  Transparent File Transfer............................|netrw-transparent|
++6.  Transparent File Editing.............................|netrw-transparent|
+ 7.  Ex Commands..........................................|netrw-ex|
+ 8.  Variables and Options................................|netrw-var|
+-9.  Directory Browsing...................................|netrw-browse| {{{1
+-      Maps...............................................|netrw-maps|
+-      Exploring..........................................|netrw-explore-cmds|
+-      Quick Reference Commands Table.....................|netrw-browse-cmds|
+-      Netrw Browser Variables............................|netrw-browse-var|
+-      Introduction To Directory Browsing.................|netrw-browse-intro|
+-      Netrw Browsing And Option Incompatibilities........|netrw-incompatible|
+-      Directory Exploring Commands.......................|netrw-explore|
+-      Refreshing The Listing.............................|netrw-ctrl-l|
+-      Going Up...........................................|netrw--|
++9.  Browsing.............................................|netrw-browse|
++      Introduction To Browsing...........................|netrw-browse-intro|
++      Quick Reference: Maps..............................|netrw-browse-maps|
++      Quick Reference: Commands..........................|netrw-browse-cmds|
++      Bookmarking A Directory............................|netrw-mb|
+       Browsing...........................................|netrw-cr|
+-      Obtaining A File...................................|netrw-O|
+-      Change Listing Style...............................|netrw-i|
+-      Making A New Directory.............................|netrw-d|
+-      Deleting Files Or Directories......................|netrw-D|
+-      Renaming Files Or Directories......................|netrw-move|
+-      Hiding Files Or Directories........................|netrw-a|
+-      Edit File Or Directory Hiding List.................|netrw-ctrl-h|
+       Browsing With A Horizontally Split Window..........|netrw-o|
+-      Browsing With A Vertically Split Window............|netrw-v|
+       Browsing With A New Tab............................|netrw-t|
+-      Preview Window.....................................|netrw-p|
+-      Selecting Sorting Style............................|netrw-s|
+-      Editing The Sorting Sequence.......................|netrw-S|
+-      Reversing Sorting Order............................|netrw-r|
++      Browsing With A Vertically Split Window............|netrw-v|
++      Change Listing Style...............................|netrw-i|
++      Changing To A Bookmarked Directory.................|netrw-gb|
+       Changing To A Predecessor Directory................|netrw-u|
+       Changing To A Successor Directory..................|netrw-U|
+       Customizing Browsing With A User Function..........|netrw-x|
+-      Making The Browsing Directory The Current Directory|netrw-c|
+-      Bookmarking A Directory............................|netrw-mb|
+-      Changing To A Bookmarked Directory.................|netrw-gb|
++      Deleting Files Or Directories......................|netrw-D|
++      Directory Exploring Commands.......................|netrw-explore|
++      Edit File Or Directory Hiding List.................|netrw-ctrl-h|
++      Editing The Sorting Sequence.......................|netrw-S|
++      Going Up...........................................|netrw--|
++      Hiding Files Or Directories........................|netrw-a|
++      Improving Browsing.................................|netrw-ssh-hack|
+       Listing Bookmarks And History......................|netrw-q|
+-      Improving Directory Browsing.......................|netrw-listhack| }}}1
++      Making A New Directory.............................|netrw-d|
++      Making The Browsing Directory The Current Directory|netrw-c|
++      Marked Files: Compression And Decompression........|netrw-mz|
++      Marked Files: Printing.............................|netrw-mp|
++      Marked Files: Tagging..............................|netrw-mT|
++      Marked Files: Unmarking............................|netrw-mu|
++      Marking Files......................................|netrw-mf|
++      Marking Files By Regular Expression................|netrw-mr|
++      Netrw Browser Variables............................|netrw-browser-var|
++      Netrw Browsing And Option Incompatibilities........|netrw-incompatible|
++      Netrw Settings.....................................|netrw-settings|
++      Obtaining A File...................................|netrw-O|
++      Preview Window.....................................|netrw-p|
++      Previous Window....................................|netrw-P|
++      Refreshing The Listing.............................|netrw-ctrl-l|
++      Renaming Files Or Directories......................|netrw-move|
++      Reversing Sorting Order............................|netrw-r|
++      Selecting Sorting Style............................|netrw-s|
+ 10. Problems and Fixes...................................|netrw-problems|
+-11. Debugging............................................|netrw-debug|
++11. Debugging Netrw Itself...............................|netrw-debug|
+ 12. History..............................................|netrw-history|
+ 13. Credits..............................................|netrw-credits|
+ 
+-The Netrw plugin is generally sourced automatically as it is a
+-|standard-plugin|.  That said, to make use of netrw, one must
+-have plugins available which can be done with the following
+-two lines in your <.vimrc>: >
+-
+-	set nocp                    " 'compatible' is not set
+-	filetype plugin on          " plugins are enabled
+-<
+-You can avoid loading this plugin by setting the "loaded_netrw" variable
+-in your <.vimrc> file: >
+-
+-	:let loaded_netrw = 1
+-
+ {Vi does not have any of this}
+ 
+ ==============================================================================
+-2. Starting With Netrw						*netrw-start*
++2. Starting With Netrw					*netrw-start* {{{1
+ 
+-Netrw makes reading, writing, and browsing over a network connection easy!
+-First, make sure that you have plugins enabled, so you'll need to have at
+-least the following in your <.vimrc>: (or see |netrw-activate|) >
++Netrw makes reading files, writing files, browsing over a network, and
++browsing locally easy!  First, make sure that you have plugins enabled, so
++you'll need to have at least the following in your <.vimrc>:
++(or see |netrw-activate|) >
+ 
+ 	set nocp                    " 'compatible' is not set
+ 	filetype plugin on          " plugins are enabled
+@@ -96,14 +91,13 @@
+ 
+ Netrw supports "transparent" editing of files on other machines using urls
+ (see |netrw-transparent|). As an example of this, let's assume you have an
+-account on some other machine; try >
++account on some other machine; if you can use scp, try: >
+ 
+ 	vim scp://hostname/path/to/file
+ <
+-if you have an ssh connection.  Want to make ssh/scp easier to use? Check
+-out |netrw-listhack|!
++Want to make ssh/scp easier to use? Check out |netrw-ssh-hack|!
+ 
+-What if you have ftp, not ssh/scp?  That's easy, too; try >
++So, what if you have ftp, not ssh/scp?  That's easy, too; try >
+ 
+ 	vim ftp://hostname/path/to/file
+ <
+@@ -117,7 +111,7 @@
+ 	...
+ 	default          login USERID password "PASSWORD"
+ <
+-Now about browsing -- ie. when you just want to look around before editing a
++Now about browsing -- when you just want to look around before editing a
+ file.  For browsing on your current host, just "edit" a directory: >
+ 
+ 	vim .
+@@ -131,28 +125,44 @@
+ <
+ See |netrw-browse| for more!
+ 
+-There's more protocols supported than scp and ftp, too: see the next
+-section, |netrw-externapp|.
++There are more protocols supported by netrw just than scp and ftp, too: see the
++next section, |netrw-externapp|, for how to use these external applications.
++
++If you want to use plugins, but for some reason don't wish to use netrw, then
++you need to avoid loading both the plugin and the autoload portions of netrw.
++You may do so by placing the following two lines in your <.vimrc>: >
++
++	:let g:loaded_netrw       = 1
++	:let g:loaded_netrwPlugin = 1
++<
+ 
+ ==============================================================================
+-3. Netrw Reference						*netrw-ref*
++3. Netrw Reference					*netrw-ref* {{{1
+ 
+-CONTROLLING EXTERNAL APPLICATIONS			*netrw-externapp*
++EXTERNAL APPLICATIONS AND PROTOCOLS			*netrw-externapp* {{{2
+ 
+ 	Protocol  Variable	    Default Value
+ 	--------  ----------------  -------------
+ 	   dav:    *g:netrw_dav_cmd*  = "cadaver"
+ 	 fetch:  *g:netrw_fetch_cmd*  = "fetch -o"    if fetch is available
+ 	   ftp:    *g:netrw_ftp_cmd*  = "ftp"
+-	  http:   *g:netrw_http_cmd*  = "curl -o"     if      curl  is available
+-	  http:    g:netrw_http_cmd   = "wget -q -O"  else if wget  is available
+-          http:    g:netrw_http_cmd   = "fetch -o"    else if fetch is available
++	  http:   *g:netrw_http_cmd*  = "curl -o"     if     curl  is available
++	  http:    g:netrw_http_cmd   = "wget -q -O"  elseif wget  is available
++          http:    g:netrw_http_cmd   = "fetch -o"    elseif fetch is available
+ 	   rcp:    *g:netrw_rcp_cmd*  = "rcp"
+ 	 rsync:  *g:netrw_rsync_cmd*  = "rsync -a"
+ 	   scp:    *g:netrw_scp_cmd*  = "scp -q"
+ 	  sftp:   *g:netrw_sftp_cmd*  = "sftp"
+ 
+-READING						*netrw-read* *netrw-nread*
++READING						*netrw-read* *netrw-nread* {{{2
++
++	Generally, one may just use the url notation with a normal editing
++	command, such as >
++
++		:e ftp://[user@]machine/path
++<
++	Netrw also provides the Nread command:
++
+ 	:Nread ?					give help
+ 	:Nread "machine:path"				uses rcp
+ 	:Nread "machine path"				uses ftp w/ <.netrc>
+@@ -166,7 +176,15 @@
+ 	:Nread "scp://[user@]machine[[:#]port]/path"	uses scp
+ 	:Nread "sftp://[user@]machine/path"		uses sftp
+ 
+-WRITING						*netrw-write* *netrw-nwrite*
++WRITING					*netrw-write* *netrw-nwrite* {{{2
++
++	Generally, one may just use the url notation with a normal file writing
++	command, such as >
++
++		:w ftp://[user@]machine/path
++<
++	Netrw also provides the Nwrite command:
++
+ 	:Nwrite ?					give help
+ 	:Nwrite "machine:path"				uses rcp
+ 	:Nwrite "machine path"				uses ftp w/ <.netrc>
+@@ -179,7 +197,15 @@
+ 	:Nwrite "sftp://[user@]machine/path"		uses sftp
+ 	http: not supported!
+ 
+-SOURCING					*netrw-source*
++SOURCING					*netrw-source* {{{2
++
++	Generally, one may just use the url notation with the normal file
++	sourcing command, such as >
++
++		:so ftp://[user@]machine/path
++<
++	Netrw also provides the Nsource command:
++
+ 	:Nsource ?					give help
+ 	:Nsource "dav://machine[:port]/path"		uses cadaver
+ 	:Nsource "fetch://[user@]machine/path"		uses fetch
+@@ -190,30 +216,39 @@
+ 	:Nsource "scp://[user@]machine[[:#]port]/path"	uses scp
+ 	:Nsource "sftp://[user@]machine/path"		uses sftp
+ 
+-DIRECTORY LISTING					*netrw-dirlist*
++DIRECTORY LISTING					*netrw-dirlist* {{{2
++
++	Generally, one may browse a directory to get a listing by simply
++	attempting to edit the directory: >
++
++		:e scp://[user]@hostname/path/
++		:e ftp://[user]@hostname/path/
++<
++	However, the Nread command can also be used to accomplish this:
++
+ 	:Nread [protocol]://[user]@hostname/path/
+ 
+-						*netrw-login* *netrw-password*
+- CHANGING USERID AND PASSWORD			*netrw-chgup* *netrw-userpass*
++					*netrw-login* *netrw-password*
++CHANGING USERID AND PASSWORD		*netrw-chgup* *netrw-userpass* {{{2
+ 
+ 	Attempts to use ftp will prompt you for a user-id and a password.
+ 	These will be saved in global variables g:netrw_uid and
+-	g:netrw_passwd; subsequent uses of ftp will re-use those two items to
++	s:netrw_passwd; subsequent uses of ftp will re-use those two items to
+ 	simplify the further use of ftp.  However, if you need to use a
+ 	different user id and/or password, you'll want to call NetUserPass()
+ 	first.  To work around the need to enter passwords, check if your ftp
+ 	supports a <.netrc> file in your home directory.  Also see
+ 	|netrw-passwd| (and if you're using ssh/scp hoping to figure out how
+-	to not need to use passwords, look at |netrw-listhack|).
++	to not need to use passwords, look at |netrw-ssh-hack|).
+ 
+ 	:NetUserPass [uid [password]]		-- prompts as needed
+ 	:call NetUserPass()			-- prompts for uid and password
+ 	:call NetUserPass("uid")		-- prompts for password
+ 	:call NetUserPass("uid","password")	-- sets global uid and password
+ 
+-VARIABLES						*netrw-variables*
++NETRW VARIABLES AND SETTINGS				*netrw-variables* {{{2
+ 
+-(also see: |netrw-browse-var| |netrw-protocol| |netrw-settings| |netrw-var|)
++(also see: |netrw-browser-var| |netrw-protocol| |netrw-settings| |netrw-var|)
+ 
+  *b:netrw_lastfile*	last file Network-read/written retained on a per-buffer
+ 			basis		(supports plain :Nw )
+@@ -236,8 +271,8 @@
+ 
+  *g:netrw_ignorenetrc*	=0 (default for linux, cygwin)
+ 			=1 If you have a <.netrc> file but it doesn't work and
+-			   you want it ignored, then set this variable as shown.
+-			   (default for Windows + cmd.exe)
++			   you want it ignored, then set this variable as
++			   shown. (default for Windows + cmd.exe)
+ 
+  *g:netrw_menu*		=0 disable netrw's menu
+ 			=1 (default) netrw's menu enabled
+@@ -246,7 +281,13 @@
+ 			be available (see |netrw-gx|)
+ 
+  *g:netrw_uid*		(ftp) user-id,      retained on a per-session basis
+- *g:netrw_passwd*	(ftp) password,     retained on a per-session basis
++ *s:netrw_passwd*	(ftp) password,     retained on a per-session basis
++
++ *g:netrw_preview*	=0 (default) preview window shown in a horizontally
++                           split window
++			=1 preview window shown in a vertically split window.
++			Also affects the "previous window" (see |netrw-P|) in
++			the same way.
+ 
+  *g:netrw_shq*		= "'" for Unix/Linux systems (ie. a single quote)
+ 			= "'" for Windows + cygwin systems (ie. a single quote)
+@@ -258,6 +299,9 @@
+  *g:netrw_scpport*      = "-P" : option to use to set port for scp
+  *g:netrw_sshport*      = "-p" : option to use to set port for ssh
+ 
++  *g:netrw_silent*	=0 : transfers done normally
++			=1 : transfers done silently
++
+  *g:netrw_use_errorwindow* =1 : messages from netrw will use a separate one
+                                 line window.  This window provides reliable
+ 				delivery of messages. (default)
+@@ -279,7 +323,7 @@
+  *g:netrw_use_nt_rcp*	=0 don't use the rcp of WinNT, Win2000 and WinXP
+ 			=1 use WinNT's rcp in binary mode         (default)
+ 
+-PATHS								*netrw-path*
++PATHS							*netrw-path* {{{2
+ 
+ Paths to files are generally user-directory relative for most protocols.
+ It is possible that some protocol will make paths relative to some
+@@ -288,7 +332,7 @@
+ 	example:  vim scp://user@host/somefile
+ 	example:  vim scp://user@host/subdir1/subdir2/somefile
+ <
+-where "somefile" is the "user"'s home directory.  If you wish to get a
++where "somefile" is in the "user"'s home directory.  If you wish to get a
+ file using root-relative paths, use the full path:
+ >
+ 	example:  vim scp://user@host//somefile
+@@ -296,7 +340,7 @@
+ <
+ 
+ ==============================================================================
+-4. Network-Oriented File Transfer				*netrw-xfer*
++4. Network-Oriented File Transfer			*netrw-xfer* {{{1
+ 
+ Network-oriented file transfer under Vim is implemented by a VimL-based script
+ (<netrw.vim>) using plugin techniques.  It currently supports both reading and
+@@ -312,7 +356,7 @@
+ 	ex. vim ftp://hostname/path/to/file
+ <
+ The characters preceding the colon specify the protocol to use; in the
+-example, its ftp.  The <netrw.vim> script then formulates a command or a
++example, it's ftp.  The <netrw.vim> script then formulates a command or a
+ series of commands (typically ftp) which it issues to an external program
+ (ftp, scp, etc) which does the actual file transfer/protocol.  Files are read
+ from/written to a temporary file (under Unix/Linux, /tmp/...) which the
+@@ -419,6 +463,10 @@
+ 
+ NETRC							*netrw-netrc*
+ 
++The <.netrc> file, typically located in your home directory, contains lines
++therein which map a hostname (machine name) to the user id and password you
++prefer to use with it.
++
+ The typical syntax for lines in a <.netrc> file is given as shown below.
+ Ftp under Unix usually supports <.netrc>; ftp under Windows usually doesn't.
+ >
+@@ -433,7 +481,7 @@
+ 	Since this file contains passwords, make very sure nobody else can
+ 	read this file!  Most programs will refuse to use a .netrc that is
+ 	readable for others.  Don't forget that the system administrator can
+-	still read the file!
++	still read the file!  Ie. for Linux/Unix: chmod 600 .netrc
+ 
+ 
+ PASSWORD						*netrw-passwd*
+@@ -444,17 +492,19 @@
+ 
+ Unfortunately there doesn't appear to be a way for netrw to feed a password to
+ scp.  Thus every transfer via scp will require re-entry of the password.
+-However, |netrw-listhack| can help with this problem.
++However, |netrw-ssh-hack| can help with this problem.
+ 
+ 
+ ==============================================================================
+-5. Activation						*netrw-activate*
++5. Activation						*netrw-activate* {{{1
+ 
+ Network-oriented file transfers are available by default whenever Vim's
+-|'nocompatible'| mode is enabled.  The <netrw.vim> file resides in your
+-system's vim-plugin directory and is sourced automatically whenever you bring
+-up vim.  I suggest that, at a minimum, you have at least the following in your
+-<.vimrc> customization file: >
++|'nocompatible'| mode is enabled.  Netrw's script files reside in your
++system's plugin, autoload, and syntax directories; just the
++plugin/netrwPlugin.vim script is sourced automatically whenever you bring up
++vim.  The main script in autoload/netrw.vim is only loaded when you actually
++use netrw.  I suggest that, at a minimum, you have at least the following in
++your <.vimrc> customization file: >
+ 
+ 	set nocp
+ 	if version >= 600
+@@ -463,11 +513,12 @@
+ <
+ 
+ ==============================================================================
+-6. Transparent File Transfer				*netrw-transparent*
++6. Transparent File Editing			*netrw-transparent* {{{1
+ 
+ Transparent file transfers occur whenever a regular file read or write
+-(invoked via an |:autocmd| for |BufReadCmd| or |BufWriteCmd| events) is made.
+-Thus one may use files across networks just as simply as if they were local. >
++(invoked via an |:autocmd| for |BufReadCmd|, |BufWriteCmd|, or |SourceCmd|
++events) is made.  Thus one may read, write, or source  files across networks
++just as easily as if they were local files! >
+ 
+ 	vim ftp://[user@]machine/path
+ 	...
+@@ -478,10 +529,10 @@
+ 
+ 
+ ==============================================================================
+-7. Ex Commands						*netrw-ex*
++7. Ex Commands						*netrw-ex* {{{1
+ 
+ The usual read/write commands are supported.  There are also a few
+-additional commands available.  Often you won't need to use Nw or
++additional commands available.  Often you won't need to use Nwrite or
+ Nread as shown in |netrw-transparent| (ie. simply use >
+   :e url
+   :r url
+@@ -489,20 +540,20 @@
+ instead, as appropriate) -- see |netrw-urls|.  In the explanations
+ below, a {netfile} is an url to a remote file.
+ 
+-:[range]Nw	Write the specified lines to the current
++:[range]Nw[rite]	Write the specified lines to the current
+ 		file as specified in b:netrw_lastfile.
+ 
+-:[range]Nw {netfile} [{netfile}]...
++:[range]Nw[rite] {netfile} [{netfile}]...
+ 		Write the specified lines to the {netfile}.
+ 
+-:Nread		Read the specified lines into the current
++:Nr[ead]		Read the specified lines into the current
+ 		buffer from the file specified in
+ 		b:netrw_lastfile.
+ 
+-:Nread {netfile} {netfile}...
++:Nr[ead] {netfile} {netfile}...
+ 		Read the {netfile} after the current line.
+ 
+-:Nsource {netfile}
++:Ns[ource] {netfile}
+ 		Source the {netfile}.
+ 		To start up vim using a remote .vimrc, one may use
+ 		the following (all on one line) (tnx to Antoine Mechelynck) >
+@@ -511,31 +562,33 @@
+ 		 --cmd "source scp://HOSTNAME/.vimrc"
+ <								*netrw-uidpass*
+ :call NetUserPass()
+-		If b:netrw_uid and b:netrw_passwd don't exist,
+-		this function query the user for them.
++		If g:netrw_uid and s:netrw_passwd don't exist,
++		this function will query the user for them.
+ 
+ :call NetUserPass("userid")
+-		This call will set the b:netrw_uid and, if
++		This call will set the g:netrw_uid and, if
+ 		the password doesn't exist, will query the user for it.
+ 
+ :call NetUserPass("userid","passwd")
+-		This call will set both the b:netrw_uid and b:netrw_passwd.
++		This call will set both the g:netrw_uid and s:netrw_passwd.
+ 		The user-id and password are used by ftp transfers.  One may
+-		effectively remove the user-id and password by using ""
+-		strings.
++		effectively remove the user-id and password by using empty
++		strings (ie. "").
+ 
+ :NetrwSettings  This command is described in |netrw-settings| -- used to
+                 display netrw settings and change netrw behavior.
+ 
+ 
+ ==============================================================================
+-8. Variables and Options			*netrw-options* *netrw-var*
++8. Variables and Options		*netrw-options* *netrw-var* {{{1
++
++(if you're interested in the netrw browser settings, see: |netrw-browser-var|)
+ 
+ The <netrw.vim> script provides several variables which act as options to
+-ffect <netrw.vim>'s behavior.  These variables typically may be set in the
+-user's <.vimrc> file:
+-(also see:
+-|netrw-settings| |netrw-browse-var| |netrw-protocol| |netrw-settings|) >
++affect <netrw.vim>'s file transfer behavior.  These variables typically may be
++set in the user's <.vimrc> file: (see also |netrw-settings| |netrw-protocol|)
++
++>
+ 
+                         -------------
+                         Netrw Options
+@@ -584,7 +637,7 @@
+ 	g:netrw_fname		Holds filename being accessed >
+ 	------------------------------------------------------------
+ <
+-								*netrw-protocol*
++							*netrw-protocol*
+ 
+ Netrw supports a number of protocols.  These protocols are invoked using the
+ variables listed below, and may be modified by the user.
+@@ -706,297 +759,430 @@
+ >
+ 
+ ==============================================================================
+-9. Directory Browsing	*netrw-browse* *netrw-dir* *netrw-list* *netrw-help*
+-
+-MAPS								*netrw-maps*
+-     <F1>.............Help.......................................|netrw-help|
+-     <cr>.............Browsing...................................|netrw-cr|
+-     <del>............Deleting Files or Directories..............|netrw-delete|
+-     -................Going Up...................................|netrw--|
+-     a................Hiding Files or Directories................|netrw-a|
+-     mb...............Bookmarking a Directory....................|netrw-mb|
+-     gb...............Changing to a Bookmarked Directory.........|netrw-gb|
+-     c................Make Browsing Directory The Current Dir....|netrw-c|
+-     d................Make A New Directory.......................|netrw-d|
+-     D................Deleting Files or Directories..............|netrw-D|
+-     <c-h>............Edit File/Directory Hiding List............|netrw-ctrl-h|
+-     i................Change Listing Style.......................|netrw-i|
+-     <c-l>............Refreshing the Listing.....................|netrw-ctrl-l|
+-     o................Browsing with a Horizontal Split...........|netrw-o|
+-     p................Preview Window.............................|netrw-p|
+-     q................Listing Bookmarks and History..............|netrw-q|
+-     r................Reversing Sorting Order....................|netrw-r|
+-     R................Renaming Files or Directories..............|netrw-R|
+-     s................Selecting Sorting Style....................|netrw-s|
+-     S................Editing the Sorting Sequence...............|netrw-S|
+-     t................Browsing with a new tab....................|netrw-t|
+-     u................Changing to a Predecessor Directory........|netrw-u|
+-     U................Changing to a Successor Directory..........|netrw-U|
+-     v................Browsing with a Vertical Split.............|netrw-v|
+-     x................Customizing Browsing.......................|netrw-x|
+-
+-    COMMANDS						*netrw-explore-cmds*
+-     :Explore[!]  [dir] Explore directory of current file........|netrw-explore|
+-     :Sexplore[!] [dir] Split & Explore directory ...............|netrw-explore|
+-     :Hexplore[!] [dir] Horizontal Split & Explore...............|netrw-explore|
+-     :Vexplore[!] [dir] Vertical Split & Explore.................|netrw-explore|
+-     :Texplore[!] [dir] Tab & Explore............................|netrw-explore|
+-     :Pexplore[!] [dir] Vertical Split & Explore.................|netrw-explore|
+-     :Nexplore[!] [dir] Vertical Split & Explore.................|netrw-explore|
+-     :NetrwSettings.............................................|netrw-settings|
+-
+-QUICK REFERENCE COMMANDS TABLE				*netrw-browse-cmds*
+->
+-        -------	-----------
+-	Command	Explanation
+-        -------	-----------
+-<	<F1>	Causes Netrw to issue help
+-	 <cr>	Netrw will enter the directory or read the file |netrw-cr|
+-	 <del>	Netrw will attempt to remove the file/directory |netrw-del|
+-	   -	Makes Netrw go up one directory |netrw--|
+-	   a	Toggles between normal display, |netrw-a|
+-		 hiding (suppress display of files matching g:netrw_list_hide)
+-		 showing (display only files which match g:netrw_list_hide)
+-	   mb	bookmark current directory
+-	   gb	go to previous bookmarked directory
+-	   c	Make current browsing directory the current directory |netrw-c|
+-	   d	Make a directory |netrw-d|
+-	   D	Netrw will attempt to remove the file(s)/directory(ies) |netrw-D|
+-	 <c-h>	Edit file hiding list |netrw-ctrl-h|
+-	   i	Cycle between thin, long, wide, and tree listings|netrw-i|
+-	 <c-l>	Causes Netrw to refresh the directory listing |netrw-ctrl-l|
+-	   o	Enter the file/directory under the cursor in a new browser
+-		 window.  A horizontal split is used. |netrw-o|
+-	   O	Obtain a file specified by cursor |netrw-O|
+-	   p	Preview the file |netrw-p|
+-	   P	Browse in the previously used window |netrw-P|
+-	   q	List bookmarked directories and history |netrw-q|
+-	   r	Reverse sorting order |netrw-r|
+-	   R	Rename the designed file(s)/directory(ies) |netrw-R|
+-	   s	Select sorting style: by name, time, or file size |netrw-s|
+-	   S	Specify suffix priority for name-sorting |netrw-S|
+-	   t	Enter the file/directory under the cursor in a new tab|netrw-t|
+-	   u	Change to recently-visited directory |netrw-u|
+-	   U	Change to subsequently-visited directory |netrw-U|
+-	   v	Enter the file/directory under the cursor in a new browser
+-		 window.  A vertical split is used. |netrw-v|
+-	   x	Apply a function to a file. (special browsers) |netrw-x|
+-
+-NETRW BROWSER VARIABLES					*netrw-browse-var*
+->
+-   ---				-----------
+-   Var				Explanation
+-   ---				-----------
+-< *g:netrw_alto*		change from above splitting to below splitting
+-				by setting this variable (see |netrw-o|)
+-				 default: =&sb           (see |'sb'|)
++9. Browsing		*netrw-browsing* *netrw-browse* *netrw-help* {{{1
++   			*netrw-browser*  *netrw-dir*    *netrw-list*
+ 
+-  *g:netrw_altv*		change from left splitting to right splitting
+-				by setting this variable (see |netrw-v|)
+-				 default: =&spr          (see |'spr'|)
++INTRODUCTION TO BROWSING			*netrw-browse-intro* {{{2
+ 
+-  *g:netrw_browse_split*	when browsing, <cr> will open the file by:
+-				=0: re-using the same window
+-				=1: horizontally splitting the window first  
+-				=2: vertically   splitting the window first  
+-				=3: open file in new tab
++Netrw supports the browsing of directories on your local system and on remote
++hosts; browsing includes listing files and directories, entering directories,
++editing files therein, deleting files/directories, making new directories,
++moving (renaming) files and directories, copying files and directories, etc.
++One may mark files and execute any system command on them!  The Netrw browser
++generally implements the previous explorer's maps and commands for remote
++directories, although details (such as pertinent global variable names)
++necessarily differ.  To browse a directory, simply "edit" it! >
+ 
+-  *g:netrw_browsex_viewer*	specify user's preference for a viewer: >
+-					"kfmclient exec"
+-					"gnome-open"
+-<				If >
+-					"-"
+-<				is used, then netrwFileHandler() will look for
+-				a script/function to handle the given
+-				extension.  (see |netrw_filehandler|).
++	vim /your/directory/
++	vim .
++	vim c:\your\directory\
++<
++(Related topics: |netrw-cr|  |netrw-o|  |netrw-p| |netrw-P| |netrw-t|
++                 |netrw-mf|  |netrw-mx| |netrw-D| |netrw-R| |netrw-v| )
+ 
+-  *g:netrw_fastbrowse*		=0: slow speed browsing, never re-use
+-				    directory listings; always obtain
+-				    directory listings.
+-				=1: medium speed browsing, re-use directory
+-				    listings only when remote browsing.
+-				    (default value)
+-				=2: fast browsing, only obtains directory
+-				    listings when the directory hasn't been
+-				    seen before (or |netrw-ctrl-l| is used).
+-				Fast browsing retains old directory listing
+-				buffers so that they don't need to be
+-				re-acquired.  This feature is especially
+-				important for remote browsing.  However, if
+-				a file is introduced or deleted into or from
+-				such directories, the old directory buffer
+-				becomes out-of-date.  One may always refresh
+-				such a directory listing with |netrw-ctrl-l|.
+-				This option gives the choice of the trade-off
+-				between accuracy and speed to the user.
++The Netrw remote file and directory browser handles two protocols: ssh and
++ftp.  The protocol in the url, if it is ftp, will cause netrw also to use ftp
++in its remote browsing.  Specifying any other protocol will cause it to be
++used for file transfers; but the ssh protocol will be used to do remote
++browsing.
+ 
+-  *g:netrw_ftp_browse_reject*	ftp can produce a number of errors and warnings
+-				that can show up as "directories" and "files"
+-				in the listing.  This pattern is used to
+-				remove such embedded messages.  By default its
+-				value is:
+-				 '^total\s\+\d\+$\|
+-				 ^Trying\s\+\d\+.*$\|
+-				 ^KERBEROS_V\d rejected\|
+-				 ^Security extensions not\|
+-				 No such file\|
+-				 : connect to address [0-9a-fA-F:]*
+-				 : No route to host$'
++To use Netrw's remote directory browser, simply attempt to read a "file" with
++a trailing slash and it will be interpreted as a request to list a directory:
++>
++	vim [protocol]://[user@]hostname/path/
++<
++where [protocol] is typically scp or ftp.  As an example, try: >
+ 
+-  *g:netrw_ftp_list_cmd*	options for passing along to ftp for directory
+-				listing.  Defaults:
+-				 unix or g:netrw_cygwin set: : "ls -lF"
+-				 otherwise                     "dir"
++	vim ftp://ftp.home.vim.org/pub/vim/
++<
++For local directories, the trailing slash is not required.  Again, because its
++easy to miss: to browse remote directories, the url must terminate with a
++slash!
++
++If you'd like to avoid entering the password repeatedly for remote directory
++listings with ssh or scp, see |netrw-ssh-hack|.  To avoid password entry with
++ftp, see |netrw-netrc| (if your ftp supports it).
++
++There are several things you can do to affect the browser's display of files:
++
++	* To change the listing style, press the "i" key (|netrw-i|).
++	  Currently there are four styles: thin, long, wide, and tree.
++	* To hide files (don't want to see those xyz~ files anymore?) see
++	  |netrw-ctrl-h|.
++	* Press s to sort files by name, time, or size.
++
++See |netrw-browse-cmds| for all the things you can do!
++
++
++QUICK REFERENCE: MAPS				*netrw-browse-maps* {{{2
++>
++	  ---			-----------------			----
++	  Map			Quick Explanation			Link
++	  ---			-----------------			----
++<	 <F1>	Causes Netrw to issue help
++	 <cr>	Netrw will enter the directory or read the file      |netrw-cr|
++	 <del>	Netrw will attempt to remove the file/directory      |netrw-del|
++	   -	Makes Netrw go up one directory                      |netrw--|
++	   a	Toggles between normal display,                      |netrw-a|
++		hiding (suppress display of files matching g:netrw_list_hide)
++		showing (display only files which match g:netrw_list_hide)
++	   c	Make browsing directory the current directory        |netrw-c|
++	   d	Make a directory                                     |netrw-d|
++	   D	Attempt to remove the file(s)/directory(ies)         |netrw-D|
++	   gb	Go to previous bookmarked directory                  |netrw-gb|
++	 <c-h>	Edit file hiding list                             |netrw-ctrl-h|
++	   i	Cycle between thin, long, wide, and tree listings    |netrw-i|
++	 <c-l>	Causes Netrw to refresh the directory listing     |netrw-ctrl-l|
++	   mb	Bookmark current directory                           |netrw-mb|
++	   mc	Copy marked files to marked-file target directory    |netrw-mc|
++	   md	Apply diff to marked files (up to 3)                 |netrw-md|
++	   me	Place marked files on arg list and edit them         |netrw-me|
++	   mf	Mark a file                                          |netrw-mf|
++	   mm	Move marked files to marked-file target directory    |netrw-mm|
++	   mp	Print marked files                                   |netrw-mp|
++	   mr	Mark files satisfying a |regexp|                     |netrw-mr|
++	   mt	Current browsing directory becomes markfile target   |netrw-mt|
++	   mT	Apply ctags to marked files                          |netrw-mT|
++	   mu	Unmark all marked files                              |netrw-mu|
++	   mx	Apply arbitrary shell command to marked files        |netrw-mx|
++	   mz	Compress/decompress marked files                     |netrw-mz|
++	   o	Enter the file/directory under the cursor in a new   |netrw-o|
++	   	browser window.  A horizontal split is used.
++	   O	Obtain a file specified by cursor                    |netrw-O|
++	   p	Preview the file                                     |netrw-p|
++	   P	Browse in the previously used window                 |netrw-P|
++	   q	List bookmarked directories and history              |netrw-q|
++	   r	Reverse sorting order                                |netrw-r|
++	   R	Rename the designed file(s)/directory(ies)           |netrw-R|
++	   s	Select sorting style: by name, time, or file size    |netrw-s|
++	   S	Specify suffix priority for name-sorting             |netrw-S|
++	   t	Enter the file/directory under the cursor in a new tab|netrw-t|
++	   u	Change to recently-visited directory                 |netrw-u|
++	   U	Change to subsequently-visited directory             |netrw-U|
++	   v	Enter the file/directory under the cursor in a new   |netrw-v|
++	   	browser window.  A vertical split is used.
++	   x	View file with an associated program                 |netrw-x|
++
++	<leftmouse>	(gvim only) selects word under mouse as if a <cr>
++			had been pressed (ie. edit file, change directory)
++	<middlemouse>	(gvim only) same as P selecting word under mouse;
++			see |netrw-P|
++	<rightmouse>	(gvim only) delete file/directory using word under
++			mouse
++	<2-leftmouse>	(gvim only) when:
++	                 * in a netrw-selected file, AND
++		         * |g:netrw_retmap| == 1     AND
++		         * the user doesn't already have a <2-leftmouse> mapping
++			   defined before netrw is autoloaded,
++			then a double clicked leftmouse button will return
++			to the netrw browser window.
++	<s-leftmouse>	(gvim only) like mf, will mark files
++
++QUICK REFERENCE: COMMANDS	*netrw-explore-cmds* *netrw-browse-cmds* {{{2
++     :NetrwClean[!] ...........................................|netrw-clean|
++     :NetrwSettings ...........................................|netrw-settings|
++     :Explore[!]  [dir] Explore directory of current file......|netrw-explore|
++     :Hexplore[!] [dir] Horizontal Split & Explore.............|netrw-explore|
++     :Nexplore[!] [dir] Vertical Split & Explore...............|netrw-explore|
++     :Pexplore[!] [dir] Vertical Split & Explore...............|netrw-explore|
++     :Rexplore          Return to Explorer.....................|netrw-explore|
++     :Sexplore[!] [dir] Split & Explore directory .............|netrw-explore|
++     :Texplore[!] [dir] Tab & Explore..........................|netrw-explore|
++     :Vexplore[!] [dir] Vertical Split & Explore...............|netrw-explore|
+ 
++BOOKMARKING A DIRECTORY	*netrw-mb* *netrw-bookmark* *netrw-bookmarks* {{{2
++One may easily "bookmark" a directory by using >
+ 
+-  *g:netrw_ftp_sizelist_cmd*	options for passing along to ftp for directory
+-				listing, sorted by size of file.
+-				Defaults:
+-				 unix or g:netrw_cygwin set: : "ls -slF"
+-				 otherwise                     "dir"
++	{cnt}mb
++<
++Any count may be used.  One may use viminfo's "!" option to retain bookmarks
++between vim sessions.  See |netrw-gb| for how to return to a bookmark and
++|netrw-q| for how to list them.
+ 
+-  *g:netrw_ftp_timelist_cmd*	options for passing along to ftp for directory
+-				listing, sorted by time of last modification.
+-				Defaults:
+-				 unix or g:netrw_cygwin set: : "ls -tlF"
+-				 otherwise                     "dir"
+ 
+-  *g:netrw_hide*		if true, the hiding list is used
+-				 default: =0
++BROWSING						*netrw-cr* {{{2
+ 
+-  *g:netrw_keepdir*		=1 (default) keep current directory immune from
+-				   the browsing directory.
+-				=0 keep the current directory the same as the
+-				   browsing directory.
+-				The current browsing directory is contained in
+-				b:netrw_curdir (also see |netrw-c|)
++Browsing is simple: move the cursor onto a file or directory of interest.
++Hitting the <cr> (the return key) will select the file or directory.
++Directories will themselves be listed, and files will be opened using the
++protocol given in the original read request.  
+ 
+-  *g:netrw_list_cmd*		command for listing remote directories
+-				 default: (if ssh is executable)
+-				          "ssh HOSTNAME ls -FLa"
++  CAVEAT: There are four forms of listing (see |netrw-i|).  Netrw assumes that
++  two or more spaces delimit filenames and directory names for the long and
++  wide listing formats.  Thus, if your filename or directory name has two or
++  more sequential spaces embedded in it, or any trailing spaces, then you'll
++  need to use the "thin" format to select it.
+ 
+-  *g:netrw_liststyle*		Set the default listing style:
+-                                = 0: thin listing (one file per line)
+-                                = 1: long listing (one file per line with time
+-				     stamp information and file size)
+-				= 2: wide listing (multiple files in columns)
+-				= 3: tree style listing
+-  *g:netrw_list_hide*		comma separated pattern list for hiding files
+-				 default: ""
++The |g:netrw_browse_split| option, which is zero by default, may be used to
++cause the opening of files to be done in a new window or tab instead of the
++default.  When the option is one or two, the splitting will be taken
++horizontally or vertically, respectively.  When the option is set to three, a
++<cr> will cause the file to appear in a new tab.
++
++
++When using the gui (gvim) one may select a file by pressing the <leftmouse>
++button.  In addtion, if
++
++ *|g:netrw_retmap| == 1      AND   (its default value is 0)
++ * in a netrw-selected file, AND
++ * the user doesn't already have a <2-leftmouse> mapping defined before
++   netrw is loaded
++
++then a doubly-clicked leftmouse button will return to the netrw browser
++window.
++
++Netrw attempts to speed up browsing, especially for remote browsing where one
++may have to enter passwords, by keeping and re-using previously obtained
++directory listing buffers.  The |g:netrw_fastbrowse| variable is used to
++control this behavior; one may have slow browsing (no buffer re-use), medium
++speed browsing (re-use directory buffer listings only for remote directories),
++and fast browsing (re-use directory buffer listings as often as possible).
++The price for such re-use is that when changes are made (such as new files
++are introduced into a directory), the listing may become out-of-date.  One may
++always refresh directory listing buffers by pressing ctrl-L (see
++|netrw-ctrl-l|).
++
++
++Related topics: |netrw-o| |netrw-p| |netrw-P| |netrw-t| |netrw-v|
++Associated setting variables: |g:netrw_browse_split|      |g:netrw_fastbrowse|
++                              |g:netrw_ftp_list_cmd| |g:netrw_ftp_sizelist_cmd|
++			      |g:netrw_ftp_timelist_cmd|  |g:netrw_ssh_cmd|
++			      |g:netrw_ssh_browse_reject| |g:netrw_use_noswf|
+ 
+-  *g:netrw_local_mkdir*		command for making a local directory
+-				 default: "mkdir"
+ 
+-  *g:netrw_local_rmdir*		remove directory command (rmdir)
+-				 default: "rmdir"
++BROWSING WITH A HORIZONTALLY SPLIT WINDOW	*netrw-o* *netrw-horiz* {{{2
+ 
+-  *g:netrw_maxfilenamelen*	=32 by default, selected so as to make long
+-				    listings fit on 80 column displays.
+-				If your screen is wider, and you have file
+-				or directory names longer than 32 bytes,
+-				you may set this option to keep listings
+-				columnar.
++Normally one enters a file or directory using the <cr>.  However, the "o" map
++allows one to open a new window to hold the new directory listing or file.  A
++horizontal split is used.  (for vertical splitting, see |netrw-v|)
+ 
+-  *g:netrw_mkdir_cmd*		command for making a remote directory
+-				 default: "ssh USEPORT HOSTNAME mkdir"
++Normally, the o key splits the window horizontally with the new window and
++cursor at the top.  To change to splitting the window horizontally with the
++new window and cursor at the bottom, have
+ 
+-  *g:netrw_rm_cmd*		command for removing files
+-				 default: "ssh USEPORT HOSTNAME rm"
++	let g:netrw_alto = 1
+ 
+-  *g:netrw_rmdir_cmd*		command for removing directories
+-				 default: "ssh USEPORT HOSTNAME rmdir"
++in your <.vimrc>.  (also see |netrw-t| |netrw-v|)
+ 
+-  *g:netrw_rmf_cmd*		 command for removing softlinks
+-				 default: "ssh USEPORT HOSTNAME rm -f"
++There is only one tree listing buffer; using "o" on a displayed subdirectory 
++will split the screen, but the same buffer will be shown twice.
+ 
+-  *g:netrw_sort_by*		sort by "name", "time", or "size"
+-				 default: "name"
++Associated setting variables: |g:netrw_alto| |g:netrw_winsize|
+ 
+-  *g:netrw_sort_direction*	sorting direction: "normal" or "reverse"
+-				 default: "normal"
+ 
+-  *g:netrw_sort_sequence*	when sorting by name, first sort by the
+-				comma-separated pattern sequence
+-				 default: '[\/]$,*,\.bak$,\.o$,\.h$,
+-				           \.info$,\.swp$,\.obj$'
++BROWSING WITH A NEW TAB				*netrw-t* {{{2
+ 
+-  *g:netrw_ssh_cmd*		One may specify an executable command
+-				to use instead of ssh for remote actions
+-				such as listing, file removal, etc.
+-				 default: ssh
++Normally one enters a file or directory using the <cr>.  The "t" map
++allows one to open a new window hold the new directory listing or file in a
++new tab. (also see: |netrw-o| |netrw-v|)
+ 
+-  *g:netrw_ssh_browse_reject*	ssh can sometimes produce unwanted lines,
+-				messages, banners, and whatnot that one doesn't
+-				want masquerading as "directories" and "files".
+-				Use this pattern to remove such embedded
+-				messages.  By default its value is:
+-					 '^total\s\+\d\+$'
+ 
+-  *g:netrw_use_noswf*		netrw normally avoids writing swapfiles
+-  				for browser buffers.  However, under some
+-				systems this apparently is causing nasty
+-				ml_get errors to appear; if you're getting
+-				ml_get errors, try putting
+-				  let g:netrw_use_noswf= 0
+-				in your .vimrc.
++BROWSING WITH A VERTICALLY SPLIT WINDOW			*netrw-v* {{{2
+ 
+-  *g:netrw_timefmt*		specify format string to strftime() (%c)
+-				 default: "%c"
++Normally one enters a file or directory using the <cr>.  However, the "v" map
++allows one to open a new window to hold the new directory listing or file.  A
++vertical split is used.  (for horizontal splitting, see |netrw-o|)
+ 
+-  *g:netrw_winsize*		specify initial size of new o/v windows
+-				 default: ""
++Normally, the v key splits the window vertically with the new window and
++cursor at the left.  To change to splitting the window vertically with the new
++window and cursor at the right, have
+ 
+-  *g:NetrwTopLvlMenu*		This variable specifies the top level
+-				menu name; by default, its "Netrw.".  If
+-				you wish to change this, do so in your
+-				.vimrc.
++	let g:netrw_altv = 1
+ 
+-INTRODUCTION TO DIRECTORY BROWSING			*netrw-browse-intro*
++in your <.vimrc>.  (also see: |netrw-o| |netrw-t|)
+ 
+-Netrw supports the browsing of directories on the local system and on remote
+-hosts, including listing files and directories, entering directories, editing
+-files therein, deleting files/directories, making new directories, and moving
+-(renaming) files and directories.  The Netrw browser generally implements the
+-previous explorer maps and commands for remote directories, although details
+-(such as pertinent global variable names) necessarily differ.
++There is only one tree listing buffer; using "v" on a displayed subdirectory 
++will split the screen, but the same buffer will be shown twice.
+ 
+-The Netrw remote file and directory browser handles two protocols: ssh and
+-ftp.  The protocol in the url, if it is ftp, will cause netrw to use ftp
+-in its remote browsing.  Any other protocol will be used for file transfers,
+-but otherwise the ssh protocol will be used to do remote directory browsing.
++Associated setting variable: |g:netrw_altv| |g:netrw_winsize|
+ 
+-To use Netrw's remote directory browser, simply attempt to read a "file" with a
+-trailing slash and it will be interpreted as a request to list a directory:
++CHANGE LISTING STYLE					*netrw-i* {{{2
+ 
+-	vim [protocol]://[user@]hostname/path/
++The "i" map cycles between the thin, long, wide, and tree listing formats.
+ 
+-For local directories, the trailing slash is not required.
++The short listing format gives just the files' and directories' names.
+ 
+-If you'd like to avoid entering the password in for remote directory listings
+-with ssh or scp, see |netrw-listhack|.
++The long listing is either based on the "ls" command via ssh for remote
++directories or displays the filename, file size (in bytes), and the time and
++date of last modification for local directories.  With the long listing
++format, netrw is not able to recognize filenames which have trailing spaces.
++Use the thin listing format for such files.
+ 
++The wide listing format uses two or more contiguous spaces to delineate
++filenames; when using that format, netrw won't be able to recognize or use
++filenames which have two or more contiguous spaces embedded in the name or any
++trailing spaces.  The thin listing format will, however, work with such files.
++This listing format is the most compact.
++
++The tree listing format has a top directory followed by files and directories
++preceded by a "|".  One may open and close directories by pressing the <cr>
++key while atop the directory name.  There is only one tree listing buffer;
++hence, using "v" or "o" on a subdirectory will only show the same buffer,
++twice.
+ 
+-NETRW BROWSING AND OPTION INCOMPATIBILITIES		*netrw-incompatible*
++Associated setting variables: |g:netrw_liststyle| |g:netrw_maxfilenamelen|
++                              |g:netrw_timefmt|   |g:netrw_list_cmd|
+ 
+-Netrw will not work properly with >
+ 
+-	:set acd
+-	:set fo=...ta...
++CHANGING TO A BOOKMARKED DIRECTORY			*netrw-gb*  {{{2
++
++To change directory back to a bookmarked directory, use
++
++	{cnt}gb
++
++Any count may be used to reference any of the bookmarks.  See |netrw-mb| on
++how to bookmark a directory and |netrw-q| on how to list bookmarks.
++
++
++CHANGING TO A PREDECESSOR DIRECTORY	*netrw-u* *netrw-updir* {{{2
++
++Every time you change to a new directory (new for the current session),
++netrw will save the directory in a recently-visited directory history
++list (unless g:netrw_dirhistmax is zero; by default, it's ten).  With the
++"u" map, one can change to an earlier directory (predecessor).  To do
++the opposite, see |netrw-U|.
++
++
++CHANGING TO A SUCCESSOR DIRECTORY		*netrw-U* *netrw-downdir* {{{2
++
++With the "U" map, one can change to a later directory (successor).
++This map is the opposite of the "u" map. (see |netrw-u|)  Use the
++q map to list both the bookmarks and history. (see |netrw-q|)
++
++
++NETRW CLEAN					*netrw-clean* *:NetrwClean*
++
++With :NetrwClean one may easily remove netrw from one's home directory;
++more precisely, from the first directory on your |'runtimepath'|.
++
++With :NetrwClean!, netrw will remove netrw from all directories on your
++|'runtimepath'|.
++
++With either form of the command, netrw will first ask for confirmation
++that the removal is in fact what you want to do.  If netrw doesn't have
++permission to remove a file, it will issue an error message.
++
++						*netrw-gx*
++CUSTOMIZING BROWSING WITH A USER FUNCTION	*netrw-x* *netrw-handler* {{{2
++						(also see |netrw_filehandler|)
++
++Certain files, such as html, gif, jpeg, (word/office) doc, etc, files, are
++best seen with a special handler (ie. a tool provided with your computer).
++Netrw allows one to invoke such special handlers by: >
++
++	* when Exploring, hit the "x" key
++	* when editing, hit gx with the cursor atop the special filename
++<	  (not available if the |g:netrw_nogx| variable exists)
++
++Netrw determines which special handler by the following method:
++
++  * if |g:netrw_browsex_viewer| exists, then it will be used to attempt to
++    view files.  Examples of useful settings (place into your <.vimrc>): >
++
++	:let g:netrw_browsex_viewer= "kfmclient exec"
++<   or >
++	:let g:netrw_browsex_viewer= "gnome-open"
++<
++    If g:netrw_browsex_viewer == '-', then netrwFileHandler() will be
++    invoked first (see |netrw_filehandler|).
++
++  * for Windows 32 or 64, the url and FileProtocolHandler dlls are used.  
++  * for Gnome (with gnome-open): gnome-open is used.
++  * for KDE (with kfmclient)   : kfmclient is used.
++  * for Mac OS X               : open is used.
++  * otherwise the netrwFileHandler plugin is used.
++
++The file's suffix is used by these various approaches to determine an
++appropriate application to use to "handle" these files.  Such things as
++OpenOffice (*.sfx), visualization (*.jpg, *.gif, etc), and PostScript (*.ps,
++*.eps) can be handled.
++
++							*netrw_filehandler*
++
++The "x" map applies a function to a file, based on its extension.  Of course,
++the handler function must exist for it to be called!
++>
++ Ex. mypgm.html   x ->
++                  NFH_html("scp://user@host/some/path/mypgm.html")
++<
++Users may write their own netrw File Handler functions to support more
++suffixes with special handling.  See <plugin/netrwFileHandlers.vim> for
++examples on how to make file handler functions.   As an example: >
++
++	" NFH_suffix(filename)
++	fun! NFH_suffix(filename)
++	..do something special with filename..
++	endfun
++<
++These functions need to be defined in some file in your .vim/plugin
++(vimfiles\plugin) directory.  Vim's function names may not have punctuation
++characters (except for the underscore) in them.  To support suffices that
++contain such characters, netrw will first convert the suffix using the
++following table: >
++
++    @ -> AT       ! -> EXCLAMATION    % -> PERCENT  
++    : -> COLON    = -> EQUAL          ? -> QUESTION 
++    , -> COMMA    - -> MINUS          ; -> SEMICOLON
++    $ -> DOLLAR   + -> PLUS           ~ -> TILDE    
++<    
++So, for example: >
++
++	file.rcs,v  ->  NFH_rcsCOMMAv()
+ <
+-If either of these options are present when browsing is attempted, netrw
+-will change them by using noacd and removing the ta suboptions from the
+-|'formatoptions'|.
+-
+-			*netrw-explore*  *netrw-pexplore* *netrw-texplore*
+-			*netrw-hexplore* *netrw-sexplore* *netrw-nexplore*
+-			*netrw-vexplore*
+-DIRECTORY EXPLORING COMMANDS 
++If more such translations are necessary, please send me email: >
++		NdrOchip at ScampbellPfamily.AbizM - NOSPAM
++with a request.
++
++Associated setting variable: |g:netrw_browsex_viewer|
++
++							*netrw-curdir*
++DELETING FILES OR DIRECTORIES	*netrw-delete* *netrw-D* *netrw-del* {{{2
++
++If files have not been marked with |netrw-mf|:
++
++    Deleting/removing files and directories involves moving the cursor to the
++    file/directory to be deleted and pressing "D".  Directories must be empty
++    first before they can be successfully removed.  If the directory is a
++    softlink to a directory, then netrw will make two requests to remove the
++    directory before succeeding.  Netrw will ask for confirmation before doing
++    the removal(s).  You may select a range of lines with the "V" command
++    (visual selection), and then pressing "D".
++
++If files have been marked with |netrw-mf|:
++
++    Marked files (and empty directories) will be deleted; again, you'll be
++    asked to confirm the deletion before it actually takes place.
++
++The g:netrw_rm_cmd, g:netrw_rmf_cmd, and g:netrw_rmdir_cmd variables are used
++to control the attempts to remove files and directories.  The g:netrw_rm_cmd
++is used with files, and its default value is:
++
++	g:netrw_rm_cmd: ssh HOSTNAME rm
++
++The g:netrw_rmdir_cmd variable is used to support the removal of directories.
++Its default value is:
++
++	g:netrw_rmdir_cmd: ssh HOSTNAME rmdir
++
++If removing a directory fails with g:netrw_rmdir_cmd, netrw then will attempt
++to remove it again using the g:netrw_rmf_cmd variable.  Its default value is:
++
++	g:netrw_rmf_cmd: ssh HOSTNAME rm -f
++
++Associated setting variable: |g:netrw_local_rmdir| |g:netrw_rm_cmd|
++                             |g:netrw_rmdir_cmd|   |g:netrw_ssh_cmd|
++
++
++*netrw-explore*  *netrw-hexplore* *netrw-nexplore* *netrw-pexplore*
++*netrw-rexplore* *netrw-sexplore* *netrw-texplore* *netrw-vexplore*
++DIRECTORY EXPLORATION COMMANDS  {{{2
+ 
+      :Explore[!]   [dir]... Explore directory of current file       *:Explore*
+-     :Sexplore[!]  [dir]... Split&Explore directory of current file *:Sexplore*
+      :Hexplore[!]  [dir]... Horizontal Split & Explore              *:Hexplore*
+-     :Vexplore[!]  [dir]... Vertical   Split & Explore              *:Vexplore*
++     :Rexplore          ... Return to Explorer                      *:Rexplore*
++     :Sexplore[!]  [dir]... Split&Explore directory of current file *:Sexplore*
+      :Texplore     [dir]... Tab              & Explore              *:Texplore*
++     :Vexplore[!]  [dir]... Vertical   Split & Explore              *:Vexplore*
+ 
+      Used with :Explore **/pattern : (also see |netrw-starstar|)
+      :Nexplore............. go to next matching file                *:Nexplore*
+@@ -1021,6 +1207,16 @@
+ By default, these commands use the current file's directory.  However, one
+ may explicitly provide a directory (path) to use.
+ 
++The |g:netrw_winsize| variable also is used, if specified by the user, to
++size Hexplore and Vexplore windows.
++
++:Rexplore  This command is a little different from the others.  When one
++           edits a file, for example by pressing <cr> when atop a file in
++	   a netrw browser window, :Rexplore will return the display to
++	   that of the last netrw browser window.  Its a command version
++	   of <2-leftmouse> (which is only available under gvim and
++	   cooperative terms).
++
+ 							*netrw-starstar*
+ When Explore, Sexplore, Hexplore, or Vexplore are used with a **/filepat,
+ such as:
+@@ -1077,15 +1273,43 @@
+ however, Explore will also search subdirectories as well as the current
+ directory.
+ 
++Associated setting variables: |g:netrw_keepdir|      |g:netrw_browse_split|
++                              |g:netrw_fastbrowse|   |g:netrw_ftp_browse_reject|
++			      |g:netrw_ftp_list_cmd| |g:netrw_ftp_sizelist_cmd|
++			      |g:netrw_ftp_timelist_cmd| |g:netrw_list_cmd|
++			      |g:netrw_liststyle|
+ 
+-REFRESHING THE LISTING				*netrw-ctrl-l* *netrw-ctrl_l*
+ 
+-To refresh either a local or remote directory listing, press ctrl-l (<c-l>) or
+-hit the <cr> when atop the ./ directory entry in the listing.  One may also
+-refresh a local directory by using ":e .".
++EDIT FILE OR DIRECTORY HIDING LIST	*netrw-ctrl-h* *netrw-edithide* {{{2
++
++The "<ctrl-h>" map brings up a requestor allowing the user to change the
++file/directory hiding list.  The hiding list consists of one or more patterns
++delimited by commas.  Files and/or directories satisfying these patterns will
++either be hidden (ie. not shown) or be the only ones displayed (see
++|netrw-a|).
+ 
++Associated setting variable: |g:netrw_hide|
+ 
+-GOING UP						*netrw--*
++
++EDITING THE SORTING SEQUENCE	*netrw-S* *netrw-sortsequence* {{{2
++
++When "Sorted by" is name, one may specify priority via the sorting sequence
++(g:netrw_sort_sequence).  The sorting sequence typically prioritizes the
++name-listing by suffix, although any pattern will do.  Patterns are delimited
++by commas.  The default sorting sequence is:
++>
++	[\/]$,*,\.bak$,\.o$,\.h$,\.info$,\.swp$,\.obj$
++<
++The lone * is where all filenames not covered by one of the other patterns
++will end up.  One may change the sorting sequence by modifying the
++g:netrw_sort_sequence variable (either manually or in your <.vimrc>) or by
++using the "S" map.
++
++Related topics:              |g:netrw-s| |g:netrw-S|
++Associated setting variable: |g:netrw_sort_sequence|
++
++
++GOING UP						*netrw--* {{{2
+ 
+ To go up a directory, press "-" or press the <cr> when atop the ../ directory
+ entry in the listing.
+@@ -1098,78 +1322,103 @@
+ 
+ where the HOSTNAME becomes the [user@]hostname as requested by the attempt to
+ read.  Naturally, the user may override this command with whatever is
+-preferred.  The NetList function which implements remote directory browsing
++preferred.  The NetList function which implements remote browsing
+ expects that directories will be flagged by a trailing slash.
+ 
+ 
+-BROWSING							*netrw-cr*
++HIDING FILES OR DIRECTORIES		*netrw-a* *netrw-hiding* {{{2
+ 
+-Browsing is simple: move the cursor onto a file or directory of interest.
+-Hitting the <cr> (the return key) will select the file or directory.
+-Directories will themselves be listed, and files will be opened using the
+-protocol given in the original read request.  
++Netrw's browsing facility allows one to use the hiding list in one of three
++ways: ignore it, hide files which match, and show only those files which
++match.
+ 
+-  CAVEAT: There are four forms of listing (see |netrw-i|).  Netrw assumes
+-  that two or more spaces delimit filenames and directory names for the long
+-  and wide listing formats.  Thus, if your filename or directory name has two
+-  or more spaces embedded in it, or any trailing spaces, then you'll need to
+-  use the "thin" format to select it.
++If no files have been marked via |netrw-mf|:
+ 
+-The |g:netrw_browse_split| option, which is zero by default, may be used to
+-cause the opening of files to be done in a new window or tab.  When the option
+-is one or two, the splitting will be taken horizontally or vertically,
+-respectively.  When the option is set to three, a <cr> will cause the file
+-to appear in a new tab.
++The "a" map allows the user to cycle through the three hiding modes.
+ 
++The |g:netrw_list_hide| variable holds a comma delimited list of patterns
++based on regular expressions (ex. ^.*\.obj$,^\.) which specify the hiding list.
++(also see |netrw-ctrl-h|)  To set the hiding list, use the <c-h> map.  As an
++example, to hide files which begin with a ".", one may use the <c-h> map to
++set the hiding list to '^\..*' (or one may put let g:netrw_list_hide= '^\..*'
++in one's <.vimrc>).  One may then use the "a" key to show all files, hide
++matching files, or to show only the matching files.
+ 
+-OBTAINING A FILE						*netrw-O*
++	Example: \.[ch]$
++		This hiding list command will hide/show all *.c and *.h files.
+ 
+-When browsing a remote directory, one may obtain a file under the cursor (ie.
+-get a copy on your local machine, but not edit it) by pressing the O key.
+-Only ftp and scp are supported for this operation (but since these two are
+-available for browsing, that shouldn't be a problem).  The status bar
+-will then show, on its right hand side, a message like "Obtaining filename".
+-The statusline will be restored after the transfer is complete.
++	Example: \.c$,\.h$
++		This hiding list command will also hide/show all *.c and *.h
++		files.
+ 
+-Netrw can also "obtain" a file using the local browser.  Netrw's display
+-of a directory is not necessarily the same as Vim's "current directory",
+-unless |g:netrw_keepdir| is set to 0 in the user's <.vimrc>.  One may select
+-a file using the local browser (by putting the cursor on it) and pressing
+-"O" will then "obtain" the file; ie. copy it to Vim's current directory.
++Don't forget to use the "a" map to select the mode (normal/hiding/show) you
++want!
+ 
+-Related topics:
+- * To see what the current directory is, use |:pwd|
+- * To make the currently browsed directory the current directory, see |netrw-c|
+- * To automatically make the currently browsed directory the current
+-   directory, see |g:netrw_keepdir|.
++If files have been marked using |netrw-mf|, then this command will:
+ 
++  if showing all files or non-hidden files:
++   modify the g:netrw_list_hide list by appending the marked files to it
++   and showing only non-hidden files.
+ 
+-CHANGE LISTING STYLE						*netrw-i*
++  else if showing hidden files only:
++   modify the g:netrw_list_hide list by removing the marked files from it
++   and showing only non-hidden files.
++  endif
+ 
+-The "i" map cycles between the thin, long, wide, and tree listing formats.
++Associated setting variable: |g:netrw_list_hide|
+ 
+-The short listing format gives just the files' and directories' names.
++					*netrw-ctrl_h*
++IMPROVING BROWSING			*netrw-listhack* *netrw-ssh-hack* {{{2
+ 
+-The long listing is either based on the "ls" command via ssh for remote
+-directories or displays the filename, file size (in bytes), and the time and
+-date of last modification for local directories.  With the long listing
+-format, netrw is not able to recognize filenames which have trailing spaces.
+-Use the thin listing format for such files.
++Especially with the remote directory browser, constantly entering the password
++is tedious.
+ 
+-The wide listing format uses two or more contiguous spaces to delineate
+-filenames; when using that format, netrw won't be able to recognize or use
+-filenames which have two or more contiguous spaces embedded in the name or any
+-trailing spaces.  The thin listing format will, however, work with such files.
+-This listing format is the most compact.
++For Linux/Unix systems, the book "Linux Server Hacks - 100 industrial strength
++tips & tools" by Rob Flickenger (O'Reilly, ISBN 0-596-00461-3) gives a tip
++for setting up no-password ssh and scp and discusses associated security
++issues.  It used to be available at http://hacks.oreilly.com/pub/h/66 ,
++but apparently that address is now being redirected to some "hackzine".
++I'll attempt a summary:
+ 
+-The tree listing format has a top directory followed by files and directories
+-preceded by a "|".  One may open and close directories by pressing the <cr>
+-key while atop the directory name.  There is only one tree listing buffer;
+-hence, using "v" or "o" on a subdirectory will only show the same buffer,
+-twice.
++	1. Generate a public/private key pair on the ssh server:
++	   ssh-keygen -t rsa
++	   (saving the file in ~/.ssh/id_rsa is ok)
++	2. Just hit the <CR> when asked for passphrase (twice).
++	3. This creates two files:
++	     ~/.ssh/id_rsa
++	     ~/.ssh/id_rsa.pub
++	4. On the client:
++	    cd
++	    mkdir .ssh
++	    chmod 0700 .ssh
++	    scp {serverhostname}:.ssh/id_rsa.pub .
++	    cat id_rsa.pub >> .ssh/authorized_keys2
++
++For Windows, folks on the vim mailing list have mentioned that Pageant helps
++with avoiding the constant need to enter the password.
++
++Kingston Fung wrote about another way to avoid constantly needing to enter
++passwords:
++
++    In order to avoid the need to type in the password for scp each time, you
++    provide a hack in the docs to set up a non password ssh account. I found a
++    better way to do that: I can use a regular ssh account which uses a
++    password to access the material without the need to key-in the password
++    each time. It's good for security and convenience. I tried ssh public key
++    authorization + ssh-agent, implementing this, and it works! Here are two
++    links with instructions:
++
++    http://www.ibm.com/developerworks/library/l-keyc2/
++    http://sial.org/howto/openssh/publickey-auth/
++
++
++LISTING BOOKMARKS AND HISTORY		*netrw-q* *netrw-listbookmark* {{{2
++
++Pressing "q" will list the bookmarked directories and directory traversal
++history (query). (see |netrw-mb|, |netrw-gb|, |netrw-u|, and |netrw-U|)
+ 
+ 
+-MAKING A NEW DIRECTORY						*netrw-d*
++MAKING A NEW DIRECTORY					*netrw-d* {{{2
+ 
+ With the "d" map one may make a new directory either remotely (which depends
+ on the global variable g:netrw_mkdir_cmd) or locally (which depends on the
+@@ -1178,345 +1427,492 @@
+ directory.  Attempts to make a local directory that already exists (as either
+ a file or a directory) will be detected, reported on, and ignored.
+ 
++Associated setting variable: |g:netrw_local_mkdir| |g:netrw_mkdir_cmd|
+ 
+-DELETING FILES OR DIRECTORIES		*netrw-delete* *netrw-D* *netrw-del*
+ 
+-Deleting/removing files and directories involves moving the cursor to the
+-file/directory to be deleted and pressing "D".  Directories must be empty
+-first before they can be successfully removed.  If the directory is a softlink
+-to a directory, then netrw will make two requests to remove the directory
+-before succeeding.  Netrw will ask for confirmation before doing the
+-removal(s).  You may select a range of lines with the "V" command (visual
+-selection), and then pressing "D".
++MAKING THE BROWSING DIRECTORY THE CURRENT DIRECTORY	*netrw-c* {{{2
+ 
+-The g:netrw_rm_cmd, g:netrw_rmf_cmd, and g:netrw_rmdir_cmd variables are used
+-to control the attempts to remove files and directories.  The g:netrw_rm_cmd
+-is used with files, and its default value is:
++By default, |g:netrw_keepdir| is 1.  This setting means that the current
++directory will not track the browsing directory.
+ 
+-	g:netrw_rm_cmd: ssh HOSTNAME rm
++Setting g:netrw_keepdir to 0 tells netrw to make vim's current directory to
++track netrw's browsing directory.
+ 
+-The g:netrw_rmdir_cmd variable is used to support the removal of directories.
+-Its default value is:
++However, given the default setting for g:netrw_keepdir of 1 where netrw
++maintains its own separate notion of the current directory, in order to make
++the two directories the same, use the "c" map (just type c).  That map will
++set Vim's notion of the current directory to netrw's current browsing
++directory.
+ 
+-	g:netrw_rmdir_cmd: ssh HOSTNAME rmdir
++Associated setting variable: |g:netrw_keepdir|
+ 
+-If removing a directory fails with g:netrw_rmdir_cmd, netrw then will attempt
+-to remove it again using the g:netrw_rmf_cmd variable.  Its default value is:
+ 
+-	g:netrw_rmf_cmd: ssh HOSTNAME rm -f
++MARKED FILES: ARBITRARY COMMAND				*netrw-mx* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
++Upon activation of the "mx" map, netrw will query the user for some command to
++be applied to all marked files.  All %s in the command will be substituted
++with the name of a marked file.  If no %s are in the command, then the command
++will be followed by a space and a marked filename.
+ 
+-RENAMING FILES OR DIRECTORIES		*netrw-move* *netrw-rename* *netrw-R*
+ 
+-Renaming/moving files and directories involves moving the cursor to the
+-file/directory to be moved (renamed) and pressing "R".  You will then be
+-queried for where you want the file/directory to be moved.  You may select a
+-range of lines with the "V" command (visual selection), and then pressing "R".
++MARKED FILES: COMPRESSION AND DECOMPRESSION		*netrw-mz* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
+-The g:netrw_rename_cmd variable is used to implement renaming.  By default its
+-value is:
++If any marked files are compressed,   then "mz" will decompress them.
++If any marked files are decompressed, then "mz" will compress them
++using the command specified by |g:netrw_compress|; by default,
++that's "gzip".
+ 
+-	ssh HOSTNAME mv
++For decompression, netrw provides a |Dictionary| of suffices and their
++associated decompressing utilities; see |g:netrw_decompress|.
+ 
+-One may rename a block of files and directories by selecting them with
+-the V (|linewise-visual|).
++Associated setting variables: |g:netrw_compress| |g:netrw_decompress|
+ 
++MARKED FILES: COPYING					*netrw-mc* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
+-HIDING FILES OR DIRECTORIES			*netrw-a* *netrw-hiding*
++Select a target directory with mt (|netrw-mt|).  Then change directory,
++select file(s) (see |netrw-mf|), and press "mc".
+ 
+-Netrw's browsing facility allows one to use the hiding list in one of three
+-ways: ignore it, hide files which match, and show only those files which
+-match.  The "a" map allows the user to cycle about these three ways.
++Associated setting variable: |g:netrw_localcopycmd| |g:netrw_ssh_cmd|
+ 
+-The g:netrw_list_hide variable holds a comma delimited list of patterns (ex.
+-\.obj) which specify the hiding list. (also see |netrw-ctrl-h|)  To set the
+-hiding list, use the <c-h> map.  As an example, to hide files which begin with
+-a ".", one may use the <c-h> map to set the hiding list to '^\..*' (or one may
+-put let g:netrw_list_hide= '^\..*' in one's <.vimrc>).  One may then use the
+-"a" key to show all files, hide matching files, or to show only the matching
+-files.
++MARKED FILES: DIFF					*netrw-md* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
+-	Example: ^.*\.[ch]
+-		This hiding list command will hide/show all *.c and *.h files.
++Use |vimdiff| to visualize difference between selected files (two or
++three may be selected for this).
+ 
+-	Example: ^.*\.c,^.*\.h
+-		This hiding list command will also hide/show all *.c and *.h
+-		files.
++MARKED FILES: EDITING					*netrw-me* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
+-Don't forget to use the "a" map to select the normal/hiding/show mode you want!
++This command will place the marked files on the |arglist| and commence
++editing them.  One may return the to explorer window with |:Rexplore|.
+ 
+-						*netrw-ctrl_h*
+-EDIT FILE OR DIRECTORY HIDING LIST		*netrw-ctrl-h* *netrw-edithide*
++MARKED FILES: MOVING						*netrw-mm* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
+-The "<ctrl-h>" map brings up a requestor allowing the user to change the
+-file/directory hiding list.  The hiding list consists of one or more patterns
+-delimited by commas.  Files and/or directories satisfying these patterns will
+-either be hidden (ie. not shown) or be the only ones displayed (see
+-|netrw-a|).
++Select a target directory with mT (|netrw-mt|).  Then change directory,
++select file(s) (see |netrw-mf|), and press "mm".
+ 
++Associated setting variable: |g:netrw_localmovecmd| |g:netrw_ssh_cmd|
+ 
+-BROWSING WITH A HORIZONTALLY SPLIT WINDOW		*netrw-o* *netrw-horiz*
++MARKED FILES: PRINTING					*netrw-mp* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
+-Normally one enters a file or directory using the <cr>.  However, the "o" map
+-allows one to open a new window to hold the new directory listing or file.  A
+-horizontal split is used.  (for vertical splitting, see |netrw-v|)
++Netrw will apply the |:hardcopy| command to marked files.  What it does
++is open each file in a one-line window, execute hardcopy, then close the
++one-line window.
+ 
+-Normally, the o key splits the window horizontally with the new window and
+-cursor at the top.  To change to splitting the window horizontally with the
+-new window and cursor at the bottom, have
+ 
+-	let g:netrw_alto = 1
++MARKED FILES: TAGGING					*netrw-mT* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
+-in your <.vimrc>.  (also see |netrw-t| |netrw-v| |g:netrw_alto|)
++The "mt" mapping will apply the command in |g:netrw_ctags| (by default, its
++"ctags") to marked files.  For remote browsing, in order to create a tags file
++netrw will use ssh (see |g:netrw_ssh_cmd|), and so ssh must be available for
++this to work on remote systems.  For your local system, see |ctags| on how to
++get a version.  I myself use hdrtags, currently available at
++http://mysite.verizon.net/astronaut/src/index.html , and have >
+ 
+-There is only one tree listing buffer; using "o" on a displayed subdirectory 
+-will split the screen, but the same buffer will be shown twice.
++	let g:netrw_ctags= "hdrtag"
++<
++in my <.vimrc>.
+ 
++When a remote set of files are tagged, the resulting tags file is "obtained";
++ie. a copy is transferred to the local system's directory.  The local tags
++file is then modified so that one may use it through the network.  The
++modification is concerns the names of the files in the tags; each filename is
++preceded by the netrw-compatible url used to obtain it.  When one subsequently
++uses one of the go to tag actions (|tags|), the url will be used by netrw to
++edit the desired file and go to the tag.
+ 
+-BROWSING WITH A VERTICALLY SPLIT WINDOW				*netrw-v*
++Associated setting variables: |g:netrw_ctags| |g:netrw_ssh_cmd|
+ 
+-Normally one enters a file or directory using the <cr>.  However, the "v" map
+-allows one to open a new window to hold the new directory listing or file.  A
+-vertical split is used.  (for horizontal splitting, see |netrw-o|)
+ 
+-Normally, the v key splits the window vertically with the new window and
+-cursor at the left.  To change to splitting the window vertically with the new
+-window and cursor at the right, have
++MARKED FILES: SETTING TARGET DIRECTORY				*netrw-mt* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
+-	let g:netrw_altv = 1
++Set the marked file move/copy target (see |netrw-mc| and |netrw-mm|).
+ 
+-in your <.vimrc>.  (also see: |netrw-o| |netrw-t| |g:netrw_altv|)
+ 
+-There is only one tree listing buffer; using "v" on a displayed subdirectory 
+-will split the screen, but the same buffer will be shown twice.
++MARKED FILES: UNMARKING					*netrw-mu* {{{2
++     (See |netrw-mf| and |netrw-mr| for how to mark files)
+ 
++The "mu" mapping will unmark all currently marked files.
+ 
+-BROWSING WITH A NEW TAB					*netrw-t*
+ 
+-Normally one enters a file or directory using the <cr>.  The "t" map
+-allows one to open a new window hold the new directory listing or file in a
+-new tab. (also see: |netrw-o| |netrw-v|)
++MARKING FILES						*netrw-mf* {{{2
++	(also see |netrw-mr|)
++
++One may mark files with the cursor atop a filename and then pressing "mf".
++With gvim, one may also mark files with <s-leftmouse>.  The following netrw
++maps make use of marked files:
++
++  |netrw-a| |netrw-O| |netrw-mc| |netrw-me| |netrw-mp| |netrw-mx|               
++  |netrw-D| |netrw-R| |netrw-md| |netrw-mm| |netrw-mT| |netrw-mz|               
++
++One may unmark files one at a time the same way one marks them; ie. place
++the cursor atop a marked file and press "mf".  This process also works
++with <s-leftmouse> using gvim.  One may unmark all files by pressing
++"mu" (see |netrw-mu|).
++
++Two commands, |netrw-mc| and |netrw-mm|, copy/move marked files to a
++target directory (which can be set with |netrw-mt|).
++
++
++MARKING FILES BY REGULAR EXPRESSION			*netrw-mr* {{{2
++	(also see |netrw-mf|)
++
++One may also mark files by pressing "mr"; netrw will then issue a prompt,
++"Enter regexp: ".  You may then enter a regular expression such as \.c$ .
++All files in the current directory will then be marked.  Note that the
++regular expressions are vim-style |regexp| ones, not shell ones.  So
++entering *.c probably isn't what you want!
++
++
++NETRW BROWSER VARIABLES		*netrw-browser-options* *netrw-browser-var* {{{2
++
++(if you're interestd in the netrw file transfer settings, see |netrw-options|)
++
++The <netrw.vim> browser provides settings in the form of variables which
++you may modify; by placing these settings in your <.vimrc>, you may customize
++your browsing preferences.  (see also: |netrw-settings|)
++>
++   ---				-----------
++   Var				Explanation
++   ---				-----------
++< *g:netrw_alto*		change from above splitting to below splitting
++				by setting this variable (see |netrw-o|)
++				 default: =&sb           (see |'sb'|)
++
++  *g:netrw_altv*		change from left splitting to right splitting
++				by setting this variable (see |netrw-v|)
++				 default: =&spr          (see |'spr'|)
++
++  *g:netrw_browse_split*	when browsing, <cr> will open the file by:
++				=0: re-using the same window
++				=1: horizontally splitting the window first  
++				=2: vertically   splitting the window first  
++				=3: open file in new tab
++				=4: act like "P" (ie. open previous window)
++
++  *g:netrw_browsex_viewer*	specify user's preference for a viewer: >
++					"kfmclient exec"
++					"gnome-open"
++<				If >
++					"-"
++<				is used, then netrwFileHandler() will look for
++				a script/function to handle the given
++				extension.  (see |netrw_filehandler|).
++
++  *g:netrw_compress*		="gzip"
++				    Will compress marked files with this
++				    command
++  *g:netrw_decompress*		= { ".gz" : "gunzip" ,
++				    ".bz2" : "bunzip2" ,
++				    ".zip" : "unzip" ,
++				    ".tar" : "tar -xf"}
++				  A dictionary mapping suffices to
++				  decompression programs.
++  *g:netrw_fastbrowse*		=0: slow speed browsing, never re-use
++				    directory listings; always obtain
++				    directory listings.
++				=1: medium speed browsing, re-use directory
++				    listings only when remote browsing.
++				    (default value)
++				=2: fast browsing, only obtains directory
++				    listings when the directory hasn't been
++				    seen before (or |netrw-ctrl-l| is used).
++				Fast browsing retains old directory listing
++				buffers so that they don't need to be
++				re-acquired.  This feature is especially
++				important for remote browsing.  However, if
++				a file is introduced or deleted into or from
++				such directories, the old directory buffer
++				becomes out-of-date.  One may always refresh
++				such a directory listing with |netrw-ctrl-l|.
++				This option gives the choice of the trade-off
++				between accuracy and speed to the user.
++
++  *g:netrw_ftp_browse_reject*	ftp can produce a number of errors and warnings
++				that can show up as "directories" and "files"
++				in the listing.  This pattern is used to
++				remove such embedded messages.  By default its
++				value is:
++				 '^total\s\+\d\+$\|
++				 ^Trying\s\+\d\+.*$\|
++				 ^KERBEROS_V\d rejected\|
++				 ^Security extensions not\|
++				 No such file\|
++				 : connect to address [0-9a-fA-F:]*
++				 : No route to host$'
++
++  *g:netrw_ftp_list_cmd*	options for passing along to ftp for directory
++				listing.  Defaults:
++				 unix or g:netrw_cygwin set: : "ls -lF"
++				 otherwise                     "dir"
++
++
++  *g:netrw_ftp_sizelist_cmd*	options for passing along to ftp for directory
++				listing, sorted by size of file.
++				Defaults:
++				 unix or g:netrw_cygwin set: : "ls -slF"
++				 otherwise                     "dir"
++
++  *g:netrw_ftp_timelist_cmd*	options for passing along to ftp for directory
++				listing, sorted by time of last modification.
++				Defaults:
++				 unix or g:netrw_cygwin set: : "ls -tlF"
++				 otherwise                     "dir"
++
++  *g:netrw_hide*		if true, the hiding list is used
++				 default: =0
++
++  *g:netrw_keepdir*		=1 (default) keep current directory immune from
++				   the browsing directory.
++				=0 keep the current directory the same as the
++				   browsing directory.
++				The current browsing directory is contained in
++				b:netrw_curdir (also see |netrw-c|)
+ 
++  *g:netrw_list_cmd*		command for listing remote directories
++				 default: (if ssh is executable)
++				          "ssh HOSTNAME ls -FLa"
+ 
+-PREVIEW WINDOW					*netrw-p* *netrw-preview*
++  *g:netrw_liststyle*		Set the default listing style:
++                                = 0: thin listing (one file per line)
++                                = 1: long listing (one file per line with time
++				     stamp information and file size)
++				= 2: wide listing (multiple files in columns)
++				= 3: tree style listing
++  *g:netrw_list_hide*		comma separated pattern list for hiding files
++				Patterns are regular expressions (see |regexp|)
++				Example: let g:netrw_list_hide= '.*\.swp$'
++				 default: ""
+ 
+-One may use a preview window by using the "p" key when the cursor is atop the
+-desired filename to be previewed.
++  *g:netrw_localcopycmd*	="cp" Linux/Unix/MacOS/Cygwin
++  				="copy" Windows
++				Copies marked files (|netrw-mf|) to target
++				directory (|netrw-mt|, |netrw-mc|)
++
++  *g:netrw_localmovecmd*	="mv" Linux/Unix/MacOS/Cygwin
++  				="move" Windows
++				Moves marked files (|netrw-mf|) to target
++				directory (|netrw-mt|, |netrw-mm|)
+ 
++  *g:netrw_local_mkdir*		command for making a local directory
++				 default: "mkdir"
+ 
+-PREVIOUS WINDOW					*netrw-P* *netrw-prvwin*
++  *g:netrw_local_rmdir*		remove directory command (rmdir)
++				 default: "rmdir"
+ 
+-To edit a file or directory in the previously used window (see :he |CTRL-W_P|),
+-press a "P".  If there's only one window, then the one window will be
+-horizontally split (above/below splitting is controlled by |g:netrw_alto|,
+-and its initial size is controlled by |g:netrw_winsize|).
++  *g:netrw_maxfilenamelen*	=32 by default, selected so as to make long
++				    listings fit on 80 column displays.
++				If your screen is wider, and you have file
++				or directory names longer than 32 bytes,
++				you may set this option to keep listings
++				columnar.
+ 
+-If there's more than one window, the previous window will be re-used on
+-the selected file/directory.  If the previous window's associated buffer
+-has been modified, and there's only one window with that buffer, then
+-the user will be asked if s/he wishes to save the buffer first (yes,
+-no, or cancel).
++  *g:netrw_mkdir_cmd*		command for making a remote directory
++				 default: "ssh USEPORT HOSTNAME mkdir"
+ 
++  *g:netrw_retmap*		if it exists and is set to one, then
++				<2-leftmouse> will be mapped for easy
++				return to the netrw browser window.
++				(example: click once to select and open
++				a file, double-click to return)
++				  default: =0
+ 
+-SELECTING SORTING STYLE				*netrw-s* *netrw-sort*
++  *g:netrw_rm_cmd*		command for removing files
++				 default: "ssh USEPORT HOSTNAME rm"
+ 
+-One may select the sorting style by name, time, or (file) size.  The "s" map
+-allows one to circulate amongst the three choices; the directory listing will
+-automatically be refreshed to reflect the selected style.
++  *g:netrw_rmdir_cmd*		command for removing directories
++				 default: "ssh USEPORT HOSTNAME rmdir"
+ 
++  *g:netrw_rmf_cmd*		 command for removing softlinks
++				 default: "ssh USEPORT HOSTNAME rm -f"
+ 
+-EDITING THE SORTING SEQUENCE		*netrw-S* *netrw-sortsequence*
++  *g:netrw_sort_by*		sort by "name", "time", or "size"
++				 default: "name"
+ 
+-When "Sorted by" is name, one may specify priority via the sorting sequence
+-(g:netrw_sort_sequence).  The sorting sequence typically prioritizes the
+-name-listing by suffix, although any pattern will do.  Patterns are delimited
+-by commas.  The default sorting sequence is:
+->
+-	[\/]$,*,\.bak$,\.o$,\.h$,\.info$,\.swp$,\.obj$
+-<
+-The lone * is where all filenames not covered by one of the other patterns
+-will end up.  One may change the sorting sequence by modifying the
+-g:netrw_sort_sequence variable (either manually or in your <.vimrc>) or by
+-using the "S" map.
++  *g:netrw_sort_direction*	sorting direction: "normal" or "reverse"
++				 default: "normal"
+ 
++  *g:netrw_sort_sequence*	when sorting by name, first sort by the
++				comma-separated pattern sequence
++				 default: '[\/]$,*,\.bak$,\.o$,\.h$,
++				           \.info$,\.swp$,\.obj$'
+ 
+-REVERSING SORTING ORDER			*netrw-r* *netrw-reverse*
++  *g:netrw_ssh_cmd*		One may specify an executable command
++				to use instead of ssh for remote actions
++				such as listing, file removal, etc.
++				 default: ssh
+ 
+-One may toggle between normal and reverse sorting order by pressing the
+-"r" key.
++  *g:netrw_ssh_browse_reject*	ssh can sometimes produce unwanted lines,
++				messages, banners, and whatnot that one doesn't
++				want masquerading as "directories" and "files".
++				Use this pattern to remove such embedded
++				messages.  By default its value is:
++					 '^total\s\+\d\+$'
+ 
++  *g:netrw_use_noswf*		netrw normally avoids writing swapfiles
++  				for browser buffers.  However, under some
++				systems this apparently is causing nasty
++				ml_get errors to appear; if you're getting
++				ml_get errors, try putting
++				  let g:netrw_use_noswf= 0
++				in your .vimrc.
+ 
+-CHANGING TO A PREDECESSOR DIRECTORY		*netrw-u* *netrw-updir*
++  *g:netrw_timefmt*		specify format string to vim's strftime().
++				The default, "%c", is "the preferred date
++				and time representation for the current
++				locale" according to my manpage entry for
++				strftime(); however, not all are satisfied
++				with it.  Some alternatives:
++				 "%a %d %b %Y %T",
++				 " %a %Y-%m-%d  %I-%M-%S %p"
++				 default: "%c"
+ 
+-Every time you change to a new directory (new for the current session),
+-netrw will save the directory in a recently-visited directory history
+-list (unless g:netrw_dirhistmax is zero; by default, its ten).  With the
+-"u" map, one can change to an earlier directory (predecessor).  To do
+-the opposite, see |netrw-U|.
++  *g:netrw_winsize*		specify initial size of new windows made with
++				"o" (see |netrw-o|), "v" (see |netrw-v|),
++				|:Hexplore| or |:Vexplore|.
++				 default: ""
+ 
++  *g:NetrwTopLvlMenu*		This variable specifies the top level
++				menu name; by default, it's "Netrw.".  If
++				you wish to change this, do so in your
++				.vimrc.
+ 
+-CHANGING TO A SUCCESSOR DIRECTORY		*netrw-U* *netrw-downdir*
++NETRW BROWSING AND OPTION INCOMPATIBILITIES	*netrw-incompatible* {{{2
+ 
+-With the "U" map, one can change to a later directory (successor).
+-This map is the opposite of the "u" map. (see |netrw-u|)  Use the
+-q map to list both the bookmarks and history. (see |netrw-q|)
++Netrw has been designed to handle user options by saving them, setting the
++options to something that's compatible with netrw's needs, and then restoring
++them.  However, the autochdir option: >
++	:set acd
++is problematical.  Autochdir sets the current directory to that containing the
++file you edit; this apparently also applies to directories.  In other words,
++autochdir sets the current directory to that containing the "file" (even if
++that "file" is itself a directory).
+ 
+-						*netrw-gx*
+-CUSTOMIZING BROWSING WITH A USER FUNCTION	*netrw-x* *netrw-handler*
+-						(also see |netrw_filehandler|)
++NETRW SETTINGS						*netrw-settings* {{{2
+ 
+-Certain files, such as html, gif, jpeg, (word/office) doc, etc, files, are
+-best seen with a special handler (ie. a tool provided with your computer).
+-Netrw allows one to invoke such special handlers by: >
++With the NetrwSettings.vim plugin, >
++	:NetrwSettings
++will bring up a window with the many variables that netrw uses for its
++settings.  You may change any of their values; when you save the file, the
++settings therein will be used.  One may also press "?" on any of the lines for
++help on what each of the variables do.
+ 
+-	* when Exploring, hit the "x" key
+-	* when editing, hit gx with the cursor atop the special filename
+-<	  (not available if the |g:netrw_nogx| variable exists)
++(also see: |netrw-browser-var| |netrw-protocol| |netrw-var| |netrw-variables|)
+ 
+-Netrw determines which special handler by the following method:
+ 
+-  * if |g:netrw_browsex_viewer| exists, then it will be used to attempt to
+-    view files.  Examples of useful settings (place into your <.vimrc>): >
++==============================================================================
++OBTAINING A FILE					*netrw-O* {{{2
+ 
+-	:let g:netrw_browsex_viewer= "kfmclient exec"
+-<   or >
+-	:let g:netrw_browsex_viewer= "gnome-open"
+-<
+-    If g:netrw_browsex_viewer == '-', then netrwFileHandler() will be
+-    invoked first (see |netrw_filehandler|).
++If there are no marked files:
+ 
+-  * for Windows 32 or 64, the url and FileProtocolHandler dlls are used.  
+-  * for Gnome (with gnome-open): gnome-open is used.
+-  * for KDE (with kfmclient): kfmclient is used.
+-  * otherwise the netrwFileHandler plugin is used.
++    When browsing a remote directory, one may obtain a file under the cursor
++    (ie.  get a copy on your local machine, but not edit it) by pressing the O
++    key.
+ 
+-The file's suffix is used by these various approaches to determine an
+-appropriate application to use to "handle" these files.  Such things as
+-OpenOffice (*.sfx), visualization (*.jpg, *.gif, etc), and PostScript (*.ps,
+-*.eps) can be handled.
++If there are marked files:
+ 
+-							*netrw_filehandler*
++    The marked files will be obtained (ie. a copy will be transferred to your
++    local machine, but not set up for editing).
+ 
+-The "x" map applies a function to a file, based on its extension.  Of course,
+-the handler function must exist for it to be called!
+->
+- Ex. mypgm.html   x ->
+-                  NFH_html("scp://user@host/some/path/mypgm.html")
+-<
+-Users may write their own netrw File Handler functions to support more
+-suffixes with special handling.  See <plugin/netrwFileHandlers.vim> for
+-examples on how to make file handler functions.   As an example: >
++Only ftp and scp are supported for this operation (but since these two are
++available for browsing, that shouldn't be a problem).  The status bar will
++then show, on its right hand side, a message like "Obtaining filename".  The
++statusline will be restored after the transfer is complete.
+ 
+-	" NFH_suffix(filename)
+-	fun! NFH_suffix(filename)
+-	..do something special with filename..
+-	endfun
+-<
+-These functions need to be defined in some file in your .vim/plugin
+-(vimfiles\plugin) directory.  Vim's function names may not have punctuation
+-characters (except for the underscore) in them.  To support suffices that
+-contain such characters, netrw will first convert the suffix using the
+-following table: >
++Netrw can also "obtain" a file using the local browser.  Netrw's display
++of a directory is not necessarily the same as Vim's "current directory",
++unless |g:netrw_keepdir| is set to 0 in the user's <.vimrc>.  One may select
++a file using the local browser (by putting the cursor on it) and pressing
++"O" will then "obtain" the file; ie. copy it to Vim's current directory.
+ 
+-    @ -> AT       ! -> EXCLAMATION    % -> PERCENT  
+-    : -> COLON    = -> EQUAL          ? -> QUESTION 
+-    , -> COMMA    - -> MINUS          ; -> SEMICOLON
+-    $ -> DOLLAR   + -> PLUS           ~ -> TILDE    
+-<    
+-So, for example: >
++Related topics:
++ * To see what the current directory is, use |:pwd|
++ * To make the currently browsed directory the current directory, see |netrw-c|
++ * To automatically make the currently browsed directory the current
++   directory, see |g:netrw_keepdir|.
+ 
+-	file.rcs,v  ->  NFH_rcsCOMMAv()
+-<
+-If more such translations are necessary, please send me email: >
+-		NdrOchip at ScampbellPfamily.AbizM - NOSPAM
+-with a request.
+ 
++PREVIEW WINDOW				*netrw-p* *netrw-preview* {{{2
+ 
+-MAKING THE BROWSING DIRECTORY THE CURRENT DIRECTORY	*netrw-c* *netrw-curdir*
++One may use a preview window by using the "p" key when the cursor is atop the
++desired filename to be previewed.  The display will then split to show both
++the browser (where the cursor will remain) and the file (see |:pedit|).
++By default, the split will be taken horizontally; one may use vertical
++splitting if one has set |g:netrw_preview| first.
+ 
+-By default, |g:netrw_keepdir| is 1.  This setting means that the current
+-directory will not track the browsing directory.
+ 
+-Setting g:netrw_keepdir to 0 tells netrw to make vim's current directory to
+-track netrw's browsing directory.
++PREVIOUS WINDOW				*netrw-P* *netrw-prvwin* {{{2
+ 
+-However, given the default setting for g:netrw_keepdir of 1 where netrw
+-maintains its own separate notion of the current directory, in order to make
+-the two directories the same, use the "c" map (just type c).  That map will
+-set Vim's notion of the current directory to netrw's current browsing
+-directory.
++To edit a file or directory in the previously used window (see :he |CTRL-W_P|),
++press a "P".  If there's only one window, then the one window will be
++horizontally split (above/below splitting is controlled by |g:netrw_alto|,
++and its initial size is controlled by |g:netrw_winsize|).
+ 
++If there's more than one window, the previous window will be re-used on
++the selected file/directory.  If the previous window's associated buffer
++has been modified, and there's only one window with that buffer, then
++the user will be asked if s/he wishes to save the buffer first (yes,
++no, or cancel).
+ 
+-BOOKMARKING A DIRECTORY		*netrw-mb* *netrw-bookmark* *netrw-bookmarks*
+-One may easily "bookmark" a directory by using >
+ 
+-	{cnt}mb
+-<
+-Any count may be used.  One may use viminfo's "!" option to retain bookmarks
+-between vim sessions.  See |netrw-gb| for how to return to a bookmark and
+-|netrw-q| for how to list them.
++REFRESHING THE LISTING			*netrw-ctrl-l* *netrw-ctrl_l* {{{2
+ 
++To refresh either a local or remote directory listing, press ctrl-l (<c-l>) or
++hit the <cr> when atop the ./ directory entry in the listing.  One may also
++refresh a local directory by using ":e .".
+ 
+-CHANGING TO A BOOKMARKED DIRECTORY			*netrw-gb* 
+ 
+-To change directory back to a bookmarked directory, use
++RENAMING FILES OR DIRECTORIES	*netrw-move* *netrw-rename* *netrw-R* {{{2
+ 
+-	{cnt}gb
++If there are no marked files: (see |netrw-mf|)
+ 
+-Any count may be used to reference any of the bookmarks.  See |netrw-mb| on
+-how to bookmark a directory and |netrw-q| on how to list bookmarks.
++    Renaming/moving files and directories involves moving the cursor to the
++    file/directory to be moved (renamed) and pressing "R".  You will then be
++    queried for where you want the file/directory to be moved.  You may select
++    a range of lines with the "V" command (visual selection), and then
++    pressing "R".
+ 
++If there are marked files:  (see |netrw-mf|)
+ 
+-LISTING BOOKMARKS AND HISTORY			*netrw-q* *netrw-listbookmark*
++    Marked files will be renamed (moved).  You will be queried as above in
++    order to specify where you want the file/directory to be moved.
+ 
+-Pressing "q" will list the bookmarked directories and directory traversal
+-history (query). (see |netrw-mb|, |netrw-gb|, |netrw-u|, and |netrw-U|)
++The g:netrw_rename_cmd variable is used to implement renaming.  By default its
++value is:
+ 
++	ssh HOSTNAME mv
+ 
+-IMPROVING DIRECTORY BROWSING				*netrw-listhack*
++One may rename a block of files and directories by selecting them with
++the V (|linewise-visual|).
+ 
+-Especially with the remote directory browser, constantly entering the password
+-is tedious.
+ 
+-For Linux/Unix systems, the book "Linux Server Hacks - 100 industrial strength
+-tips & tools" by Rob Flickenger (O'Reilly, ISBN 0-596-00461-3) gives a tip
+-for setting up no-password ssh and scp and discusses associated security
+-issues.  It used to be available at http://hacks.oreilly.com/pub/h/66 ,
+-but apparently that address is now being redirected to some "hackzine".
+-I'll attempt a summary:
++REVERSING SORTING ORDER		*netrw-r* *netrw-reverse* {{{2
+ 
+-	1. Generate a public/private key pair on the ssh server:
+-	   ssh-keygen -t rsa
+-	   (saving the file in ~/.ssh/id_rsa is ok)
+-	2. Just hit the <CR> when asked for passphrase (twice).
+-	3. This creates two files:
+-	     ~/.ssh/id_rsa
+-	     ~/.ssh/id_rsa.pub
+-	4. On the client:
+-	    cd
+-	    mkdir .ssh
+-	    chmod 0700 .ssh
+-	    scp {serverhostname}:.ssh/id_rsa.pub .
+-	    cat id_rsa.pub >> .ssh/authorized_keys2
++One may toggle between normal and reverse sorting order by pressing the
++"r" key.
+ 
+-For Windows, folks on the vim mailing list have mentioned that Pageant helps
+-with avoiding the constant need to enter the password.
++Related topics:              |g:netrw-s|
++Associated setting variable: |g:netrw_sort_direction|
+ 
+ 
+-NETRW SETTINGS						*netrw-settings*
++SELECTING SORTING STYLE			*netrw-s* *netrw-sort* {{{2
+ 
+-With the NetrwSettings.vim plugin, >
+-	:NetrwSettings
+-will bring up a window with the many variables that netrw uses for its
+-settings.  You may change any of their values; when you save the file, the
+-settings therein will be used.  One may also press "?" on any of the lines for
+-help on what each of the variables do.
++One may select the sorting style by name, time, or (file) size.  The "s" map
++allows one to circulate amongst the three choices; the directory listing will
++automatically be refreshed to reflect the selected style.
+ 
+-(also see: |netrw-browse-var| |netrw-protocol| |netrw-var| |netrw-variables|)
++Related topics:               |g:netrw-r| |g:netrw-S|
++Associated setting variables: |g:netrw_sort_by| |g:netrw_sort_sequence|
+ 
+ 
+-==============================================================================
+-10. Problems and Fixes						*netrw-problems*
++10. Problems and Fixes					*netrw-problems* {{{1
+ 
+ 	(This section is likely to grow as I get feedback)
+ 	(also see |netrw-debug|)
+@@ -1568,9 +1964,11 @@
+ 								*netrw-p4*
+ 	P4. I would like long listings to be the default.
+ 
+-			let g:netrw_liststyle= 1
++		Put the following statement into your |.vimrc|: >
+ 
+-		Check out |netrw-browse-var| for more customizations that
++			let g:netrw_liststyle= 1
++<
++		Check out |netrw-browser-var| for more customizations that
+ 		you can set.
+ 
+ 								*netrw-p5*
+@@ -1579,15 +1977,18 @@
+ 		Does your system's strftime() accept the "%c" to yield dates
+ 		such as "Sun Apr 27 11:49:23 1997"?  If not, do a "man strftime"
+ 		and find out what option should be used.  Then put it into
+-		your <.vimrc>:
+-			let g:netrw_timefmt= "%X"  (where X is the option)
++		your |.vimrc|: >
+ 
++			let g:netrw_timefmt= "%X"  (where X is the option)
++<
+ 								*netrw-p6*
+ 	P6. I want my current directory to track my browsing.
+ 	    How do I do that?
+ 
++	    Put the following line in your |.vimrc|:
++>
+ 		let g:netrw_keepdir= 0
+-	
++<	
+ 								*netrw-p7*
+ 	P7. I use Chinese (or other non-ascii) characters in my filenames, and
+ 	    netrw (Explore, Sexplore, Hexplore, etc) doesn't display them!
+@@ -1652,9 +2053,9 @@
+ 			  {asterisk}.{asterisk} (all files), or whatever types
+ 			  you want (cec: change {asterisk} to * ; I had to
+ 			  write it that way because otherwise the helptags
+-			  system thinks its a tag)
+-			- Make sure its at the top of the listbox (click it,
+-			  then click "Up" if its not)
++			  system thinks it's a tag)
++			- Make sure it's at the top of the listbox (click it,
++			  then click "Up" if it's not)
+ 		If using the Norton Commander style, you just have to hit <F4>
+ 		to edit a file in a local copy of gvim.
+ 
+@@ -1663,16 +2064,24 @@
+   http://www.tartarus.org/~simon/puttydoc/Chapter8.html#pubkey-gettingready
+ 			8.3 Getting ready for public key authentication
+ <
+-		How to use private key with 'pscp': >
++		How to use a private key with 'pscp': >
++
+ 			http://www.tartarus.org/~simon/puttydoc/Chapter5.html
+ 			5.2.4 Using public key authentication with PSCP 
+ <
++		(Ben Schmidt) I find the ssh included with cwRsync is
++		brilliant, and install cwRsync or cwRsyncServer on most
++		Windows systems I come across these days. I guess COPSSH,
++		packed by the same person, is probably even better for use as
++		just ssh on Windows, and probably includes sftp, etc. which I
++		suspect the cwRsync doesn't, though it might
++
+ 		(cec) To make proper use of these suggestions above, you will
+ 		need to modify the following user-settable variables in your
+ 		.vimrc:
+ 
+-			|g:netrw_ssh_cmd| |g:netrw_list_cmd|  |g:netrw_mkdir_cmd|
+-			|g:netrw_rm_cmd|  |g:netrw_rmdir_cmd| |g:netrw_rmf_cmd|
++		|g:netrw_ssh_cmd| |g:netrw_list_cmd|  |g:netrw_mkdir_cmd|
++		|g:netrw_rm_cmd|  |g:netrw_rmdir_cmd| |g:netrw_rmf_cmd|
+ 
+ 		The first one (|g:netrw_ssh_cmd|) is the most important; most
+ 		of the others will use the string in g:netrw_ssh_cmd by
+@@ -1688,52 +2097,77 @@
+ 		in your <.vimrc>: >
+ 			let g:netrw_use_noswf= 0
+ <
++								*netrw-p10*
++	P10. I'm being pestered with "[something] is a directory" and
++	     "Press ENTER or type command to continue" prompts...
++
++		The "[something] is a directory" prompt is issued by Vim,
++		not by netrw, and there appears to be no way to work around
++		it.  Coupled with the default cmdheight of 1, this message
++		causes the "Press ENTER..." prompt.  So:  read |hit-enter|;
++		I also suggest that you set your |'cmdheight'| to 2 (or more) in
++		your <.vimrc> file.
++
++								*netrw-p11*
++	P11. I want to have two windows; a thin one on the left and my editing
++	     window on the right.  How can I do this?
++
++		* Put the following line in your <.vimrc>:
++			let g:netrw_altv = 1
++		* Edit the current directory:  :e .
++		* Select some file, press v
++		* Resize the windows as you wish (see |ctrl-w_<| and
++		  |ctrl-w_>|).  If you're using gvim, you can drag
++		  the separating bar with your mouse.
++		* When you want a new file, use  ctrl-w h  to go back to the
++		  netrw browser, select a file, then press P  (see |ctrl-w_h|
++		  and |netrw-P|).  If you're using gvim, you can press
++		  <leftmouse> in the browser window and then press the
++		  <middlemouse> to select the file.
+ 
+ ==============================================================================
+-11. Debugging						*netrw-debug*
++11. Debugging Netrw Itself				*netrw-debug* {{{1
+ 
+ The <netrw.vim> script is typically available as:
+ >
+-	/usr/local/share/vim/vim6x/plugin/netrw.vim
++	/usr/local/share/vim/vim6x/plugin/netrwPlugin.vim
++	/usr/local/share/vim/vim6x/autoload/netrw.vim
+ < -or- >
+-	/usr/local/share/vim/vim7x/plugin/netrw.vim
++	/usr/local/share/vim/vim7x/plugin/netrwPlugin.vim
++	/usr/local/share/vim/vim7x/autoload/netrw.vim
+ <
+ which is loaded automatically at startup (assuming :set nocp).
+ 
+ 	1. Get the <Decho.vim> script, available as:
+ 
+-	     http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_scripts
+-	     as "Decho, a vimL debugging aid"
++	     http://mysite.verizon.net/astronaut/vim/index.html#DECHO
+ 	   or
+ 	     http://vim.sourceforge.net/scripts/script.php?script_id=120
+ 
+-	   and put it into your local plugin directory.
+-
+-	2. <Decho.vim> itself needs the <cecutil.vim> script, so you'll need
+-	   to put it into your .vim/plugin, too.  You may obtain it from:
++	  It now comes as a "vimball"; if you're using vim 7.0 or earlier,
++	  you'll need to update vimball, too.  See
++	     http://mysite.verizon.net/astronaut/vim/index.html#VIMBALL
+ 
+-		http://mysite.verizon.net/astronaut/vim/index.html#VimFuncs
+-		as "DrC's Utilities"
+-
+-	3. Edit the <netrw.vim> file by typing:
++	2. Edit the <netrw.vim> file by typing: >
+ 
+ 		vim netrw.vim
+ 		:DechoOn
+ 		:wq
+-
+-	   To restore to normal non-debugging behavior, edit <netrw.vim>
+-	   by typing
++<
++	   To restore to normal non-debugging behavior, re-edit <netrw.vim>
++	   and type >
+ 
+ 		vim netrw.vim
+ 		:DechoOff
+ 		:wq
+-
++<
+ 	   This command, provided by <Decho.vim>, will comment out all
+ 	   Decho-debugging statements (Dfunc(), Dret(), Decho(), Dredir()).
+ 
+-	4. Then bring up vim and attempt a transfer or do browsing.  A set of
+-	   messages should appear concerning the steps that <netrw.vim> took
+-	   in attempting to read/write your file over the network.
++	3. Then bring up vim and attempt to evoke the problem by doing a
++	   transfer or doing some browsing.  A set of messages should appear
++	   concerning the steps that <netrw.vim> took in attempting to
++	   read/write your file over the network in a separate tab.
+ 
+ 	   To save the file, use >
+ 		:wincmd j
+@@ -1745,15 +2179,118 @@
+ ==============================================================================
+ 12. History						*netrw-history* {{{1
+ 
++	v119: Jan 10, 2008 * When g:netrw_keepdir is false,
++			     NetrwOptionsRestore() had a problem
++			     (Bill McCarthy)
++	      Jan 11, 2008 * Netrw now shows symbolic links with a trailing
++	                     "@" and special highlighting.
++	      Jan 15, 2008 * Changed g:netrw_noretmap -> |g:netrw_retmap|.
++	                     Changed: disabled by default at Bram's
++			     preference.
++	v118: Jan 02, 2008 * Fixed a problem with Windows;
++			     :Explore c:/path/ would not work,
++			     but :Explore c:/path would.
++			   * Fixed a bug in s:NetrwOptionRestore() - lcd's
++			     argument wasn't being properly escaped so it
++			     wouldn't handle spaces in directory names.
++			     (Gary Johnson)
++	v117: Jan 02, 2008 * Fixed a problem with P; had to include
++			     a b:netrw_curdir bypass (Bram Moolenaar)
++	v116: Nov 27, 2007 * netrw#LocalBrowseCheck() has &ft=="netrw"
++			     check to prevent doing a directory listing
++			     (was getting unexpected directory refreshes
++			     in the middle of some function calls)
++			   * NetrwOptionRestore moved after e! filename
++			     in order to retain user options for editing
++			     in s:NetrwBrowseChgDir()
++	      Dec 12, 2007 * Bug fix -- netrw does a better job of retaining
++	                     user options when editing files under the aegis
++			     of the browser
++	v115: Oct 04, 2007 * Erik Remmelzwaal pointed out that the use of
++			     shellslash in s:GetTempfile() was incorrect
++	      Oct 11, 2007 * Tracked down and eliminated a bug with editing
++			     remote *.tar.gz and *.tar.bz2 files
++	      Oct 11, 2007 * g:netrw_localmovecmd wasn't being initialized
++			     properly, and g:netrw_localcopycmd was being
++			     overwritten.
++	      Oct 12, 2007 * Placed all :Rexplore and <2-leftmouse> setup
++			     in a new support function (s:SetRexDir()).
++	      Oct 15, 2007 * new: g:netrw_browse_split == 4; means <cr>
++			     based selection will use previous window
++	      Oct 20, 2007 * also checks on |'shellxquote'| to set g:netrw_shq
++	      Oct 24, 2007 * Explore handles path/**/filename
++	      Oct 27, 2007 * sourcing remote files often didn't work with ftp,
++	                     turns out that b:netrw_method was undefined, so
++			     s:SaveBufVars and s:RestoreBufVars() fixed it.
++	v114: Sep 28, 2007 * mT, the map that invokes tags, has been improved
++			     to support use of remote tags files.
++	      Oct 02, 2007 * changed Netrw menu to use more submenus
++	v113: Sep 07, 2007 * worked out why the cursor position wasn't being
++			     saved and restored as intended after doing such
++			     things as deleting and renaming files.
++	      Sep 11, 2007 * Fixed bug which effectively disabled <c-l> and
++			     <c-h> maps
++	      Sep 18, 2007 * there used to be one NetrwOptionRestore() call at
++			     the end of the s:NetrwBrowseChgDir() function;
++			     they're now at the end of every if..elseif..else
++			     block.  The edit-a-file one is not quite at the end
++			     of its block; instead, its just before the edit.
++			     Restores user options, then this new placement
++			     allows ftplugins, autocmds, etc to change settings
++			     (ex. ftplugin/cpp.vim sets cindent).
++	      Sep 19, 2007 * changed all strlen() calls to use s:Strlen(), a
++			     function which handles utf-8 wide characters
++			     correctly.
++	      Sep 20, 2007 * (Nico Weber) the "x" command has been extended
++			     to Mac's OS/X (macunix); it now uses open to
++			     handle |netrw-x| browsing with special files.
++	      Sep 22, 2007 * Added |g:netrw_noretmap| to netrw at Tony M's
++			     request.
++			   * Included path to NetrwRemoteRmFile()
++	v112: Aug 18, 2007 * added mx (|netrw-mx|) for executing arbitrary
++			     commands on marked files
++	      Aug 22, 2007 * more option save/restore work for
++			     s:NetrwBrowseChgDir(); s:NetrwOptionSave()
++			     and s:NetrwOptionRestore() now take a parameter
++			     specifying the type of variables to be used for
++			     saving and restoring (either "w:" or "s:")
++	      Sep 04, 2007 * added the :NetrwClean[!] command
++	v111: Jul 25, 2007 * using Windows but not using Cygwin, netrw does a
++			     "file bufname" where the bufname uses /s
++			     instead of \s; Vim "fixes" it by changing the
++			     bufname to use \s anyway.  This meant that
++			     NetrwGetBuffer() didn't find the appropriately
++			     named buffer, and so would generate a new
++			     buffer listing; hence the cursor would appear
++			     to have been moved when doing a preview.
++			   * added <2-leftmouse> map to return to netrw's
++			     browser display
++	      Aug 16, 2007 * added the mark-file system, including
++			     maps for mf mp mt mz and mu.  Modifications
++			     made to maps for a D O and R to support
++			     marked files.
++	v110: May 10, 2007 * added [ and ] maps to NetrwTreeListing
++	      May 25, 2007 * |g:netrw_preview| included
++	      May 29, 2007 * modifed netrw#NetBrowseX to consistently use
++			    |g:netrw_shq| instead of hardcoded quotes,
++			     and modified the snippet that sets up redir
++			     so Windows machines use "nul" instead of
++			     "/dev/null".
++	      Jun 01, 2007 * fixed bug -- NetGetBuffer() wasn't always
++			     recognizing a buffer name match when it should,
++			     thus resulting in [Scratch] buffers.
++	      Jun 04, 2007 * Gary Johnson found a bugfix for the "c" mapping
++			     when the directory is to be made current but
++			     the name contains spaces.
+ 	v109: Mar 26, 2007 * if a directory name includes a "$" character,
+ 			     Explore() will use expand() in an attempt to
+ 			     decipher the name.
+ 	      May 07, 2007 * g:netrw_use_errorwindow now allows one to
+-	                     have error messages go to a reliable window
++			     have error messages go to a reliable window
+ 			     or to use a less reliable but recallable 
+ 			     echoerr method
+ 	      May 07, 2007 * g:netrw_scpport and g:netrw_sshport support
+-	                     use of -P and -p, respectively, to set port
++			     use of -P and -p, respectively, to set port
+ 			     for scp/ssh.
+ 	v108: Jan 03, 2007 * included preview map (|netrw-p|), supporting
+ 			     remote browsing
+@@ -1879,257 +2416,319 @@
+ 	v97: May 01, 2006  * exists("&acd") now used to determine if
+ 			     the 'acd' option exists
+ 			   * "obtain" now works again under Windows
+-	v96: * bugfix - the |'acd'| option is not always defined but is
+-	       now bypassed only when it is
+-	v95: * bugfix - Hiding mode worked correctly (don't show any file
+-	       matching any of the g:netrw_hide patterns), but
+-	       showing mode was showing only those files that didn't
+-	       match any of the g:netrw_hide patterns.  Instead, it now
+-	       shows all files that match any of the g:netrw_hide patterns
+-	       (the difference between a logical and and logical or).
+-	v94: * bugfix - a Decho() had a missing quote; only affects things
+-	       when debugging was enabled.
+-	v93: * bugfix - removed FocusGained event from causing a slow-browser
+-	       refresh for Windows
+-	v92: * :Explore **//pattern implemented  (**/filepattern already taken)
+-	v91: * :Explore */pattern implemented
+-	     * |'acd'| option bypassed
+-	v90: * mark ', as suggested by Yegappan Lakshmanan, used to help
+-	       guarantee entry into the jump list when appropriate.
+-	     * <s-down> and <s-up> are no longer defined until a
+-	       :Explore **/pattern  is used (if the user already has a map
+-	       for them).  They will be defined for new browser windows
+-	       from that point forward.
+-	v89: * A <s-down>, <s-up>, :Nexplore, or a :Pexplore without having
+-	       first done an :Explore **/pattern (see |netrw-starstar|) caused
+-	       a lot of unhelpful error messages to appear
+-	v88: * moved DrChip.Netrw menu to Netrw.  Now has priority 80 by
+-	       default.  g:NetrwTopLvlMenu == "Netrw" and can be changed
+-	       by the user to suit.  The priority is g:NetrwMenuPriority.
+-	     * Changed filetype for browser displays from netrwlist to netrw.
+-	v87: * bug fix -- menus were partially disappearing
+-	v85: * bug fix -- missing an endif
+-	     * bug fix -- handles spaces in names and directories when using
+-	       ftp-based browsing
+-	v83: * disabled stop-acd handling; the change in directory handling
+-	       may allow acd to be used again.  Awaiting feedback.
+-	     * D was refusing to delete remote files/directories in wide
+-	       listing mode.
+-	v81: * FocusGained also used to refresh/wipe local browser directory
+-	       buffers
+-	     * (bugfix) netrw was leaving [Scratch] buffers behind when the
+-	       user had the "hidden" option set.  The 'hidden' option is
+-	       now bypassed.
+-	v80: * ShellCmdPost event used in conjunction with g:netrw_fastbrowse
+-	       to refresh/wipe local browser directory buffers.
+-	v79: * directories are now displayed with nowrap
+-	     * (bugfix) if the column width was smaller than the largest
+-	       file's name, then netrw would hang when using wide-listing
+-	       mode - fixed
+-	     * g:netrw_fastbrowse introduced
+-	v78: * progress has been made on allowing spaces inside directory
+-	       names for remote work (reading, writing, browsing).  (scp)
+-	v77: * Mikolaj Machowski fixed a bug in a substitute command
+-	     * g:netrw_browsex_viewer implemented
+-	     * Mikolaj Machowski pointed out that gnome-open is often
+-	       executable under KDE systems, although it is effectively
+-	       not functional.  NetBrowseX now looks for "kicker" as 
+-	       a running process to determine if KDE is actually the
+-	       really running.
+-	     * Explorer's O functionality was inadvertently left out.
+-	       Netrw now does the same thing, but with the "P" key.
+-	     * added g:netrw_browse_split option
+-	     * fixed a bug where the directory contained a "." but
+-	       the file didn't (was treating the dirname from "."
+-	       onwards as a suffix)
+-	v76: * "directory is missing" error message now restores echo
+-	       highlighting
+-	v75: * file://... now conforms to RFC2396 (thanks to S. Zacchiroli)
+-	     * if the binary option is set, then NetWrite() will only write
+-	       the whole file (line numbers don't make sense with this).
+-	       Supports writing of tar and zip files.
+-	v74: * bugfix (vim, then :Explore) now works
+-	     * ctrl-L keeps cursor at same screen location (both local and
+-	       remote browsing)
+-	     * netrw now can read remote zip and tar files
+-	     * Obtain now uses WinXP ftp+.netrc successfully
+-	v73: * bugfix -- scp://host/path/file was getting named incorrectly
+-	     * netrw detects use of earlier-than-7.0 version of vim and issues
+-	       a pertinent error message.
+-	     * netrwSettings.vim is now uses autoloading.  Only
+-	       <netrwPlugin.vim> is needed as a pure plugin
+-	       (ie. always loaded).
+-	v72: * bugfix -- formerly, one could prevent the loading of netrw
+-	       by "let g:loaded_netrw=1"; when autoloading became supported,
+-	       this feature was lost.  It is now restored.
+-	v71: * bugfix -- made some "set nomodifiable"s into setlocal variants
+-	       (allows :e somenewfile  to be modifiable as usual)
+-	     * NetrwSettings calls a netrw function, thereby assuring that
+-	       netrw has loaded.  However, if netrw does not load for whatever
+-	       reason, then NetrwSettings will now issue a warning message.
+-	     * For what reason I don't recall, when wget and fetch are both
+-	       not present, and an attempt to read a http://... url is made,
+-	       netrw exited.  It now only returns.
+-	     * When ch=1, on the second and subsequent uses of browsing Netrw
+-	       would issue a blank line to clear the echo'd messages.  This
+-	       caused an annoying "Hit-Enter" prompt; now a blank line message
+-	       is echo'd only if &ch>1.
+-	v70: * when using |netrw-O|, the "Obtaining filename" message is now
+-	       shown using |hl-User9|.  If User9 has not been defined, netrw
+-	       will define it.
+-	v69: * Bugfix: win95/98 machines were experiencing a
+-	       "E121: Undefined variable: g:netrw_win95ftp" message
+-	v68: * double-click-leftmouse selects word under mouse
+-	v67: * Passwords which contain blanks will now be surrounded by
+-	       double-quotes automatically (Yongwei)
+-	v66: * Netrw now seems to work with a few more Windows situations
+-	     * O now obtains a file: remote browsing file -> local copy,
+-	       locally browsing file -> current directory (see :pwd)
+-	     * i now cycles between thin, long, and wide listing styles
+-	     * NB and Nb are maps that are always available; corresponding
+-	       B and b maps are only available when not using wide listing
+-	       in order to allow them to be used for motions
+-	v65: * Browser functions now use NetOptionSave/Restore; in particular,
+-	       netrw now works around the report setting
+-	v64: * Bugfix - browsing a "/" directory (Unix) yielded buffers 
+-	       named "[Scratch]" instead of "/"
+-	     * Bugfix - remote browsing with ftp was omitting the ./ and ../
+-	v63: * netrw now takes advantage of autoload (and requires 7.0)
+-	     * Bugfix - using r (to reverse sort) working again
+-	v62: * Bugfix - spaces allowed again in directory names with
+-	       g:netrw_keepdir=0.  In fact, I've tested netrw (again)
+-	       with most ANSI punctuation marks for directory names.
+-	     * Bugfix - NetrwSettings gave errors when g:netrw_silent
+-	       had not be set.
+-	v61: * document upgrade -- netrw variable-based settings all should
+-	       have tags.  Supports NetrwSettings command.
+-	     * several important variables are window-oriented.  Netrw has
+-	       to transfer these across a window split.  See s:BufWinVars()
+-	       and s:UseBufWinVars().
+-	v60: * when using the i map to switch between long and short listings,
+-	       netrw will now keep cursor on same line
+-	     * "Match # of #" now uses status line
+-	     * :Explore **/*.c  will now work from a non-netrw-browser window
+-	     * :Explore **/patterns can now be run in separate browser windows
+-	     * active banner (hit <cr> will cause various things to happen)
+-	v59: * bugfix -- another keepalt work-around installed (for vim6.3)
+-	     * "Match # of #" for Explore **/pattern matches
+-	v58: * Explore and relatives can now handle **/somefilepattern (v7)
+-	     * Nexplore and Pexplore introduced (v7).  shift-down and shift-up
+-	       cursor keys will invoke Nexplore and Pexplore, respectively.
+-	     * bug fixed with o and v
+-	     * autochdir only worked around for vim when it has been
+-	       compiled with either |+netbeans_intg| or |+sun_workshop|
+-	     * Under Windows, all directories and files were being preceded
+-	       with a "/" when local browsing.  Fixed.
+-	     * When: syntax highlighting is off, laststatus=2, and remote
+-	       browsing is used, sometimes the laststatus highlighting
+-	       bleeds into the entire display.  Work around - do an extra
+-	       redraw in that case.
+-	     * Bugfix: when g:netrw_keepdir=0, due to re-use of buffers,
+-	       netrw didn't change the directory when it should've
+-	     * Bugfix: D and R commands work again
+-	v57: * Explore and relatives can now handle RO files
+-	     * reverse sort restored with vim7's sort command
+-	     * g:netrw_keepdir now being used to keep the current directory
+-	       unchanged as intended (sense change)
+-	     * vim 6.3 still supported
+-	v56: * LocalBrowse now saves autochdir setting, unsets it, and
+-	       restores it before returning.
+-	     * using vim's rename() instead of system + local_rename variable
+-	     * avoids changing directory when g:netrw_keepdir is false
+-	v55: * -bar used with :Explore :Sexplore etc to allow multiple
+-	       commands to be separated by |s
+-	     * browser listings now use the "nowrap" option
+-	     * browser: some unuseful error messages now suppressed
+-	v54: * For backwards compatibility, Explore and Sexplore have been
+-	       implemented.  In addition, Hexplore and Vexplore commands
+-	       are available, too.
+-	     * <amatch> used instead of <afile> in the transparency
+-	       support (BufReadCmd, FileReadCmd, FileWriteCmd)
+-	     * ***netrw*** prepended to various error messages netrw may emit
+-	     * g:netrw_port used instead of b:netrw_port for scp
+-	     * any leading [:#] is removed from port numbers
+-	v53: * backslashes as well as slashes placed in various patterns
+-	       (ex. g:netrw_sort_sequence) to better support Windows
+-	v52: * nonumber'ing now set for browsing buffers
+-	     * when the hiding list hid all files, error messages ensued. Fixed
+-	     * when browsing, swf is set, but directory is not set, when netrw
+-	       was attempting to restore options, vim wanted to save a swapfile
+-	       to a local directory using an url-style path.  Fixed
+-	v51: * cygwin detection now automated (using windows and &shell is bash)
+-	     * customizable browser "file" rejection patterns
+-	     * directory history
+-	     * :[range]w url  now supported (ie. netrw has a FileWriteCmd event)
+-	     * error messages have a "Press <cr> to continue" to allow them
+-	       to be seen
+-	     * directory browser displays no longer bother the swapfile
+-	     * u/U commands to go up and down the history stack
+-	     * history stack may be saved with viminfo with its "!" option
+-	     * bugfixes associated with unwanted [No Files] entries
+-	v50: * directories now displayed using buftype=nofile; should keep the
+-	       directory names as-is
+-	     * attempts to remove empty "[No File]" buffers leftover
+-	       from :file ..name.. commands
+-	     * bugfix: a "caps-lock" editing difficulty left in v49 was fixed
+-	     * syntax highlighting for "Showing:" the hiding list included
+-	     * bookmarks can now be retained if "!" is in the viminfo option
+-	v49: * will use ftp for http://.../ browsing v48:
+-	     * One may use ftp to do remote host file browsing
+-	     * (windows and !cygwin) remote browsing with ftp can now use
+-	       the "dir" command internally to provide listings
+-	     * g:netrw_keepdir now allows one to keep the initial current
+-	       directory as the current directory (normally the local file
+-	       browser makes the currently viewed directory the current
+-	       directory)
+-	     * g:netrw_alto and g:netrw_altv now support alternate placement
+-	       of windows started with o or v
+-	     * Nread ? and Nwrite ?  now uses echomsg (instead of echo) so
+-	       :messages can repeat showing the help
+-	     * bugfix: avoids problems with partial matches of directory names
+-	       to prior buffers with longer names
+-	     * one can suppress error messages with g:netrw_quiet ctrl-h used
+-	     * instead of <Leader>h for editing hiding list one may edit the
+-	     * sorting sequence with the S map now allows confirmation of
+-	     * deletion with [y(es) n(o) a(ll) q(uit)] the "x" map now handles
+-	     * special file viewing with:
+-	       (windows) rundll32 url.dll (gnome)   gnome-open (kde)
+-	       kfmclient If none of these are on the executable path, then
+-	       netrwFileHandlers.vim is used.
+-	     * directory bookmarking during both local and remote browsing
+-	       implemented
+-	     * one may view all, use the hiding list to suppress, or use the
+-	       hiding list to show-only remote and local file/directory
+-	       listings
+-	     * improved unusual file and directory name handling preview
+-	     * window support
+-	v47: * now handles local directory browsing.
+-	v46: * now handles remote directory browsing
+-	     * g:netrw_silent (if 1) will cause all transfers to be silent
+-	v45: * made the [user@]hostname:path form a bit more restrictive to
+-	       better handle errors in using protocols (e.g. scp:usr at host:file
+-	       was being recognized as an rcp request) v44: * changed from
+-	       "rsync -a" to just "rsync"
+-	     * somehow an editing error messed up the test to recognize
+-	       use of the fetch method for NetRead.
+-	     * more debugging statements included
+-	v43: * moved "Explanation" comments to <pi_netrw.txt> help file as
+-	       "Network Reference" (|netrw-ref|)
+-	     * <netrw.vim> now uses Dfunc() Decho() and Dret() for debugging
+-	     * removed superfluous NetRestorePosn() calls
+-	v42: * now does BufReadPre and BufReadPost events on file:///* and
+-	       file://localhost/* v41: * installed file:///* and
+-	       file://localhost/* handling v40: * prevents redraw when a
+-	       protocol error occurs so that the user may see it v39: * sftp
+-	       support v38: * Now uses NetRestorePosn() calls with
+-	       Nread/Nwrite commands
+-	     * Temporary files now removed via bwipe! instead of bwipe
+-	       (thanks to Dave Roberts) v37: * Claar's modifications which
+-	       test if ftp is successful, otherwise give an error message
+-	     * After a read, the alternate file was pointing to the temp file.
+-	       The temp file buffer is now wiped out.
+-	     * removed silent from transfer methods so user can see what's
+-	       happening
++	v96:		   * bugfix - the |'acd'| option is not always defined
++			     but is now bypassed only when it is
++	v95:		   * bugfix - Hiding mode worked correctly (don't show
++			     any file matching any of the g:netrw_hide
++			     patterns), but showing mode was showing only those
++			     files that didn't match any of the g:netrw_hide
++			     patterns.  Instead, it now shows all files that
++			     match any of the g:netrw_hide patterns (the
++			     difference between a logical and and logical or).
++	v94:		   * bugfix - a Decho() had a missing quote; only
++			     affects things when debugging was enabled.
++	v93:		   * bugfix - removed FocusGained event from causing a
++			     slow-browser refresh for Windows
++	v92:		   * :Explore **//pattern implemented
++			      (**/filepattern was already taken)
++	v91:		   * :Explore */pattern implemented
++			   * |'acd'| option bypassed
++	v90:		   * mark ', as suggested by Yegappan Lakshmanan, used
++			     to help guarantee entry into the jump list when
++			     appropriate.
++			   * <s-down> and <s-up> are no longer defined until a
++			     :Explore **/pattern  is used (if the user already
++			     has a map for them).  They will be defined for new
++			     browser windows from that point forward.
++	v89:		   * A <s-down>, <s-up>, :Nexplore, or a :Pexplore
++			     without having first done an :Explore **/pattern
++			     (see |netrw-starstar|) caused
++			     a lot of unhelpful error messages to appear
++	v88:		   * moved DrChip.Netrw menu to Netrw.  Now has
++			     priority 80 by default.
++			     g:NetrwTopLvlMenu == "Netrw" and can be changed
++			     by the user to suit.  The priority is given by
++			     g:NetrwMenuPriority.
++			   * Changed filetype for browser displays from
++			     netrwlist to netrw.
++	v87:		   * bug fix -- menus were partially disappearing
++	v85:		   * bug fix -- missing an endif
++			   * bug fix -- handles spaces in names and directories
++			     when using ftp-based browsing
++	v83:		   * disabled stop-acd handling; the change in directory
++			     handling may allow acd to be used again.
++			   * D was refusing to delete remote files/directories
++			     in wide listing mode.
++	v81:		   * FocusGained also used to refresh/wipe local browser
++			     directory buffers
++			   * (bugfix) netrw was leaving [Scratch] buffers behind
++			     when the user had the "hidden" option set.  The
++			     'hidden' option is now bypassed.
++	v80:		   * ShellCmdPost event used in conjunction with
++			     g:netrw_fastbrowse to refresh/wipe local browser
++			     directory buffers.
++	v79:		   * directories are now displayed with nowrap
++			   * (bugfix) if the column width was smaller than the
++			     largest file's name, then netrw would hang when
++			     using wide-listing mode - fixed
++			   * g:netrw_fastbrowse introduced
++	v78:		   * progress has been made on allowing spaces inside
++			     directory names for remote work (reading, writing,
++			     browsing).  (scp)
++	v77:		   * Mikolaj Machowski fixed a bug in a substitute cmd
++			   * g:netrw_browsex_viewer implemented
++			   * Mikolaj Machowski pointed out that gnome-open is
++			     often executable under KDE systems, although it is
++			     effectively not functional.  NetBrowseX now looks
++			     for "kicker" as a running process to determine if
++			     KDE is actually running.
++			   * Explorer's O functionality was inadvertently left
++			     out.  Netrw now does the same thing, but with the
++			     "P" key.
++			   * added g:netrw_browse_split option
++			   * fixed a bug where the directory contained a "." but
++			     the file didn't (was treating the dirname from "."
++			     onwards as a suffix)
++	v76:		   * "directory is missing" error message now restores
++			      echo highlighting
++	v75:		   * file://... now conforms to RFC2396 (thanks to
++			     S. Zacchiroli)
++			   * if the binary option is set, then NetWrite() will
++			     only write the whole file (line numbers don't make
++			     sense with this).  Supports writing of tar and zip
++			     files.
++	v74:		   * bugfix (vim, then :Explore) now works
++			   * ctrl-L keeps cursor at same screen location (both
++			     local and remote browsing)
++			   * netrw now can read remote zip and tar files
++			   * Obtain now uses WinXP ftp+.netrc successfully
++	v73:		   * bugfix -- scp://host/path/file was getting named
++			     incorrectly
++			   * netrw detects use of earlier-than-7.0 version of
++			     vim and issues a pertinent error message.
++			   * netrwSettings.vim is now uses autoloading.  Only
++			     <netrwPlugin.vim> is needed as a pure plugin
++			     (ie. always loaded).
++	v72:		   * bugfix -- formerly, one could prevent the loading
++			     of netrw by "let g:loaded_netrw=1"; when
++			     autoloading became supported, this feature was
++			     lost.  It is now restored.
++	v71:		   * bugfix -- made some "set nomodifiable"s into
++			     setlocal variants (allows :e somenewfile  to be
++			     modifiable as usual)
++			   * NetrwSettings calls a netrw function, thereby
++			     assuring that netrw has loaded.  However, if netrw
++			     does not load for whatever reason, then
++			     NetrwSettings will now issue a warning message.
++			   * For what reason I don't recall, when wget and fetch
++			     are both not present, and an attempt to read a
++			     http://... url is made, netrw exited.  It now only
++			     returns.
++			   * When ch=1, on the second and subsequent uses of
++			     browsing Netrw would issue a blank line to clear
++			     the echo'd messages.  This caused an annoying
++			     "Hit-Enter" prompt; now a blank line message
++			     is echo'd only if &ch>1.
++	v70:		   * when using |netrw-O|, the "Obtaining filename"
++			     message is now shown using |hl-User9|.  If User9
++			     has not been defined, netrw itself will define it.
++	v69:		   * Bugfix: win95/98 machines were experiencing a
++			     "E121: Undefined variable: g:netrw_win95ftp"
++			     message
++	v68:		   * double-click-leftmouse selects word under mouse
++	v67:		   * Passwords which contain blanks will now be
++			     surrounded by double-quotes automatically (Yongwei)
++	v66:		   * Netrw now seems to work with a few more Windows
++			     situations
++			   * O now obtains a file: remote browsing
++			     file -> local copy, locally browsing
++			     file -> current directory (see :pwd)
++			   * i now cycles between thin, long, and wide listing
++			     styles
++			   * NB and Nb are maps that are always available;
++			     corresponding B and b maps are only available when
++			     not using wide listing in order to allow them to
++			     be used for motions
++	v65:		   * Browser functions now use NetOptionSave/Restore; in
++			     particular, netrw now works around the report
++			     setting
++	v64:		   * Bugfix - browsing a "/" directory (Unix) yielded
++			     buffers named "[Scratch]" instead of "/"
++			   * Bugfix - remote browsing with ftp was omitting
++			     the ./ and ../
++	v63:		   * netrw now takes advantage of autoload (needs 7.0)
++			   * Bugfix - using r (to reverse sort) working again
++	v62:		   * Bugfix - spaces allowed again in directory names
++			     with g:netrw_keepdir=0.  In fact, I've tested netrw
++			     with most ANSI punctuation marks for directory
++			     names.
++			   * Bugfix - NetrwSettings gave errors when
++			     g:netrw_silent had not be set.
++	v61:		   * Document upgrade -- netrw variable-based settings
++			     all should have tags.  Supports NetrwSettings cmd.
++			   * Several important variables are window-oriented.
++			     Netrw has to transfer these across a window split.
++			     See s:BufWinVars() and s:UseBufWinVars().
++	v60:		   * When using the i map to switch between long and
++			     short listings, netrw will now keep cursor on same
++			     line
++			   * "Match # of #" now uses status line
++			   * :Explore **/*.c  will now work from a
++			     non-netrw-browser window
++			   * :Explore **/patterns can now be run in separate
++			     browser windows
++			   * active banner (hit <cr> will cause various things
++			     to happen)
++	v59:		   * bugfix -- another keepalt work-around installed
++			     (for vim6.3)
++			   * "Match # of #" for Explore **/pattern matches
++	v58:		   * Explore and relatives can now handle
++			     **/somefilepattern (v7)
++			   * Nexplore and Pexplore introduced (v7).  shift-down
++			     and shift-up cursor keys will invoke Nexplore and
++			     Pexplore, respectively.
++			   * bug fixed with o and v
++			   * autochdir only worked around for vim when it has
++			     been compiled with either
++			     |+netbeans_intg| or |+sun_workshop|
++			   * Under Windows, all directories and files were
++			     being preceded with a "/" when local browsing.
++			     Fixed.
++			   * When: syntax highlighting is off, laststatus=2, and
++			     remote browsing is used, sometimes the laststatus
++			     highlighting bleeds into the entire display.  Work
++			     around - do an extra redraw in that case.
++			   * Bugfix: when g:netrw_keepdir=0, due to re-use of
++			     buffers, netrw didn't change the directory when it
++			     should've
++			   * Bugfix: D and R commands work again
++	v57:		   * Explore and relatives can now handle RO files
++			   * reverse sort restored with vim7's sort command
++			   * g:netrw_keepdir now being used to keep the current
++			     directory unchanged as intended (sense change)
++			   * vim 6.3 still supported
++	v56:		   * LocalBrowse now saves autochdir setting, unsets it,
++			     and restores it before returning.
++			   * using vim's rename() instead of system +
++			     local_rename variable
++			   * avoids changing directory when g:netrw_keepdir is
++			     false
++	v55:		   * -bar used with :Explore :Sexplore etc to allow
++			     multiple commands to be separated by |s
++			   * browser listings now use the "nowrap" option
++			   * browser: some unuseful error messages now
++			     suppressed
++	v54:		   * For backwards compatibility, Explore and Sexplore
++			     have been implemented.  In addition, Hexplore and
++			     Vexplore commands are available, too.
++			   * <amatch> used instead of <afile> in the
++			     transparency support (BufReadCmd, FileReadCmd,
++			     FileWriteCmd)
++			   * ***netrw*** prepended to various error messages
++			     netrw may emit
++			   * g:netrw_port used instead of b:netrw_port for scp
++			   * any leading [:#] is removed from port numbers
++	v53:		   * backslashes as well as slashes placed in various
++			     patterns (ex. g:netrw_sort_sequence) to better
++			     support Windows
++	v52:		   * nonumber'ing now set for browsing buffers
++			   * when the hiding list hid all files, error messages
++			     ensued. Fixed
++			   * when browsing, swf is set, but directory is not
++			     set, when netrw was attempting to restore options,
++			     vim wanted to save a swapfile to a local directory
++			     using an url-style path.  Fixed
++	v51:		   * cygwin detection now automated
++			     (using windows and &shell is bash)
++			   * customizable browser "file" rejection patterns
++			   * directory history
++			   * :[range]w url  now supported (ie. netrw uses a
++			     FileWriteCmd event)
++			   * error messages have a "Press <cr> to continue" to
++			     allow them to be seen
++			   * directory browser displays no longer bother the
++			     swapfile
++			   * u/U commands to go up and down the history stack
++			   * history stack may be saved with viminfo with it's
++			     "!" option
++			   * bugfixes associated with unwanted [No Files]
++			     entries
++	v50:		   * directories now displayed using buftype=nofile;
++			     should keep the directory names as-is
++			   * attempts to remove empty "[No File]" buffers
++			     leftover from :file ..name.. commands
++			   * bugfix: a "caps-lock" editing difficulty left in
++			     v49 was fixed
++			   * syntax highlighting for "Showing:" the hiding list
++			     included
++			   * bookmarks can now be retained if "!" is in the
++			     viminfo option
++	v49:		   * will use ftp for http://.../ browsing
++	v48:		   * One may use ftp to do remote host file browsing
++			   * (windows and !cygwin) remote browsing with ftp can
++			     now use the "dir" command internally to provide
++			     listings
++			   * g:netrw_keepdir now allows one to keep the initial
++			     current directory as the current directory
++			     (normally the local file browser makes the
++			     currently viewed directory the current directory)
++			   * g:netrw_alto and g:netrw_altv now support
++			     alternate placement of windows started with o or v
++			   * Nread ? and Nwrite ?  now uses echomsg (instead of
++			     echo) so :messages can repeat showing the help
++			   * bugfix: avoids problems with partial matches of
++			     directory names to prior buffers with longer names
++			   * one can suppress error messages with g:netrw_quiet
++			     ctrl-h used
++			   * instead of <Leader>h for editing hiding list one
++			     may edit the sorting sequence with the S map, which
++			     now allows confirmation of deletion with
++			     [y(es) n(o) a(ll) q(uit)]
++			   * the "x" map now handles special file viewing with:
++			     (windows) rundll32 url.dll (gnome) gnome-open (kde)
++			     kfmclient If none of these are on the executable
++			     path, then netrwFileHandlers.vim is used.
++			   * directory bookmarking during both local and remote
++			     browsing implemented
++			   * one may view all, use the hiding list to suppress,
++			     or use the hiding list to show-only remote and
++			     local file/directory listings
++			   * improved unusual file and directory name handling
++			     preview window support
++	v47:		   * now handles local browsing.
++	v46:		   * now handles remote browsing
++			   * g:netrw_silent (if 1) will cause all transfers to
++			     be silent
++	v45:		   * made the [user@]hostname:path form a bit more
++			     restrictive to better handle errors in using
++			     protocols (e.g. scp:usr at host:file was being
++			     recognized as an rcp request)
++	v44:		   * changed from "rsync -a" to just "rsync"
++			   * somehow an editing error messed up the test to
++			     recognize use of the fetch method for NetRead.
++			   * more debugging statements included
++	v43:		   * moved "Explanation" comments to <pi_netrw.txt> help
++			     file as "Network Reference" (|netrw-ref|)
++			   * <netrw.vim> now uses Dfunc() Decho() and Dret() for
++			     debugging
++			   * removed superfluous NetRestorePosn() calls
++	v42:		   * now does BufReadPre and BufReadPost events on
++			     file:///* and file://localhost/*
++	v41:		   * installed file:///* and file://localhost/* handling
++	v40:		   * prevents redraw when a protocol error occurs so
++			     that the user may see it
++	v39:		   * sftp support
++	v38:		   * Now uses NetRestorePosn() calls with Nread/Nwrite
++			     commands
++			   * Temporary files now removed via bwipe! instead of
++			     bwipe (thanks to Dave Roberts)
++	v37:		   * Claar's modifications which test if ftp is
++			     successful, otherwise give an error message
++			   * After a read, the alternate file was pointing to
++			     the temp file.  The temp file buffer is now wiped
++			     out.
++			   * removed silent from transfer methods so user can
++			     see what's happening
+ 
+ 
+ ==============================================================================
+@@ -2157,4 +2756,5 @@
+ 	                           operation
+ 
+ ==============================================================================
++Modelines: {{{1
+  vim:tw=78:ts=8:ft=help:norl:fdm=marker
+Index: vim/runtime/syntax/netrw.vim
+===================================================================
+--- vim/runtime/syntax/netrw.vim.orig
++++ vim/runtime/syntax/netrw.vim
+@@ -1,7 +1,7 @@
+ " Language   : Netrw Remote-Directory Listing Syntax
+ " Maintainer : Charles E. Campbell, Jr.
+-" Last change: Nov 27, 2006
+-" Version    : 9
++" Last change: Aug 08, 2007
++" Version    : 10
+ " ---------------------------------------------------------------------
+ 
+ " Syntax Clearing: {{{1
+@@ -13,7 +13,7 @@
+ 
+ " ---------------------------------------------------------------------
+ " Directory List Syntax Highlighting: {{{1
+-syn cluster NetrwGroup contains=netrwHide,netrwSortBy,netrwSortSeq,netrwQuickHelp,netrwVersion
++syn cluster NetrwGroup contains=netrwHide,netrwSortBy,netrwSortSeq,netrwQuickHelp,netrwVersion,netrwCopyTgt
+ 
+ syn match  netrwSpecial		"\%(\S\+ \)*\S\+[*|=]\ze\%(\s\{2,}\|$\)" contains=netrwClassify
+ syn match  netrwDir		"\.\{1,2}/"			contains=netrwClassify
+@@ -36,6 +36,7 @@
+ syn match  netrwHideSep		","				contained transparent skipwhite nextgroup=netrwHidePat
+ syn match  netrwSortBy		"Sorted by"			contained transparent skipwhite nextgroup=netrwList
+ syn match  netrwSortSeq		"Sort sequence:"		contained transparent skipwhite nextgroup=netrwList
++syn match  netrwCopyTgt		"Copy/Move Tgt:"		contained transparent skipwhite nextgroup=netrwList
+ syn match  netrwList		".*$"				contained contains=netrwComma
+ syn match  netrwComma		","				contained
+ syn region netrwQuickHelp	matchgroup=Comment start="Quick Help:\s\+" end="$" contains=netrwHelpCmd keepend contained
+@@ -46,7 +47,7 @@
+ 
+ " ---------------------------------------------------------------------
+ " Highlighting Links: {{{1
+-if !exists("did_drchip_dbg_syntax")
++if !exists("did_drchip_netrwlist_syntax")
+  let did_drchip_netrwlist_syntax= 1
+  hi link netrwClassify	Function
+  hi link netrwCmdSep	Delimiter
+@@ -56,13 +57,14 @@
+  hi link netrwHidePat	Statement
+  hi link netrwList	Statement
+  hi link netrwVersion	Identifier
+- hi link netrwSymLink	Special
++ hi link netrwSymLink	Question
+  hi link netrwExe	PreProc
+  hi link netrwDateSep	Delimiter
+ 
+  hi link netrwTimeSep	netrwDateSep
+  hi link netrwComma	netrwComment
+  hi link netrwHide	netrwComment
++ hi link netrwMarkFile	Identifier
+ endif
+ 
+ " Current Syntax: {{{1




More information about the pkg-vim-maintainers mailing list