forked from aniani/vim
move netrw back to the previous version
This commit is contained in:
File diff suppressed because it is too large
Load Diff
@@ -1,7 +1,7 @@
|
|||||||
" netrwSettings.vim: makes netrw settings simpler
|
" netrwSettings.vim: makes netrw settings simpler
|
||||||
" Date: Nov 09, 2016
|
" Date: Dec 30, 2014
|
||||||
" Maintainer: Charles E Campbell <drchipNOSPAM at campbellfamily dot biz>
|
" Maintainer: Charles E Campbell <drchipNOSPAM at campbellfamily dot biz>
|
||||||
" Version: 16
|
" Version: 15
|
||||||
" Copyright: Copyright (C) 1999-2007 Charles E. Campbell {{{1
|
" Copyright: Copyright (C) 1999-2007 Charles E. Campbell {{{1
|
||||||
" Permission is hereby granted to use and distribute this code,
|
" Permission is hereby granted to use and distribute this code,
|
||||||
" with or without modifications, provided that this copyright
|
" with or without modifications, provided that this copyright
|
||||||
@@ -19,7 +19,7 @@
|
|||||||
if exists("g:loaded_netrwSettings") || &cp
|
if exists("g:loaded_netrwSettings") || &cp
|
||||||
finish
|
finish
|
||||||
endif
|
endif
|
||||||
let g:loaded_netrwSettings = "v16"
|
let g:loaded_netrwSettings = "v15"
|
||||||
if v:version < 700
|
if v:version < 700
|
||||||
echohl WarningMsg
|
echohl WarningMsg
|
||||||
echo "***warning*** this version of netrwSettings needs vim 7.0"
|
echo "***warning*** this version of netrwSettings needs vim 7.0"
|
||||||
@@ -154,13 +154,9 @@ fun! netrwSettings#NetrwSettings()
|
|||||||
put = 'let g:netrw_list_hide = '.g:netrw_list_hide
|
put = 'let g:netrw_list_hide = '.g:netrw_list_hide
|
||||||
put = 'let g:netrw_liststyle = '.g:netrw_liststyle
|
put = 'let g:netrw_liststyle = '.g:netrw_liststyle
|
||||||
put = 'let g:netrw_localcopycmd = '.g:netrw_localcopycmd
|
put = 'let g:netrw_localcopycmd = '.g:netrw_localcopycmd
|
||||||
put = 'let g:netrw_localcopycmdopt = '.g:netrw_localcopycmdopt
|
|
||||||
put = 'let g:netrw_localmkdir = '.g:netrw_localmkdir
|
put = 'let g:netrw_localmkdir = '.g:netrw_localmkdir
|
||||||
put = 'let g:netrw_localmkdiropt = '.g:netrw_localmkdiropt
|
|
||||||
put = 'let g:netrw_localmovecmd = '.g:netrw_localmovecmd
|
put = 'let g:netrw_localmovecmd = '.g:netrw_localmovecmd
|
||||||
put = 'let g:netrw_localmovecmdopt = '.g:netrw_localmovecmdopt
|
|
||||||
put = 'let g:netrw_localrmdir = '.g:netrw_localrmdir
|
put = 'let g:netrw_localrmdir = '.g:netrw_localrmdir
|
||||||
put = 'let g:netrw_localrmdiropt = '.g:netrw_localrmdiropt
|
|
||||||
put = 'let g:netrw_maxfilenamelen = '.g:netrw_maxfilenamelen
|
put = 'let g:netrw_maxfilenamelen = '.g:netrw_maxfilenamelen
|
||||||
put = 'let g:netrw_menu = '.g:netrw_menu
|
put = 'let g:netrw_menu = '.g:netrw_menu
|
||||||
put = 'let g:netrw_mousemaps = '.g:netrw_mousemaps
|
put = 'let g:netrw_mousemaps = '.g:netrw_mousemaps
|
||||||
|
@@ -20,7 +20,7 @@
|
|||||||
if &cp || exists("g:loaded_netrwPlugin")
|
if &cp || exists("g:loaded_netrwPlugin")
|
||||||
finish
|
finish
|
||||||
endif
|
endif
|
||||||
let g:loaded_netrwPlugin = "v162"
|
let g:loaded_netrwPlugin = "v156"
|
||||||
let s:keepcpo = &cpo
|
let s:keepcpo = &cpo
|
||||||
set cpo&vim
|
set cpo&vim
|
||||||
"DechoRemOn
|
"DechoRemOn
|
||||||
@@ -42,8 +42,8 @@ augroup END
|
|||||||
" Network Browsing Reading Writing: {{{2
|
" Network Browsing Reading Writing: {{{2
|
||||||
augroup Network
|
augroup Network
|
||||||
au!
|
au!
|
||||||
au BufReadCmd file://* call netrw#FileUrlEdit(expand("<amatch>"))
|
au BufReadCmd file://* call netrw#FileUrlRead(expand("<amatch>"))
|
||||||
au BufReadCmd ftp://*,rcp://*,scp://*,http://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau BufReadPre ".fnameescape(expand("<amatch>"))|call netrw#Nread(2,expand("<amatch>"))|exe "sil doau BufReadPost ".fnameescape(expand("<amatch>"))
|
au BufReadCmd ftp://*,rcp://*,scp://*,http://*,file://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau BufReadPre ".fnameescape(expand("<amatch>"))|call netrw#Nread(2,expand("<amatch>"))|exe "sil doau BufReadPost ".fnameescape(expand("<amatch>"))
|
||||||
au FileReadCmd ftp://*,rcp://*,scp://*,http://*,file://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau FileReadPre ".fnameescape(expand("<amatch>"))|call netrw#Nread(1,expand("<amatch>"))|exe "sil doau FileReadPost ".fnameescape(expand("<amatch>"))
|
au FileReadCmd ftp://*,rcp://*,scp://*,http://*,file://*,https://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau FileReadPre ".fnameescape(expand("<amatch>"))|call netrw#Nread(1,expand("<amatch>"))|exe "sil doau FileReadPost ".fnameescape(expand("<amatch>"))
|
||||||
au BufWriteCmd ftp://*,rcp://*,scp://*,http://*,file://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau BufWritePre ".fnameescape(expand("<amatch>"))|exe 'Nwrite '.fnameescape(expand("<amatch>"))|exe "sil doau BufWritePost ".fnameescape(expand("<amatch>"))
|
au BufWriteCmd ftp://*,rcp://*,scp://*,http://*,file://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau BufWritePre ".fnameescape(expand("<amatch>"))|exe 'Nwrite '.fnameescape(expand("<amatch>"))|exe "sil doau BufWritePost ".fnameescape(expand("<amatch>"))
|
||||||
au FileWriteCmd ftp://*,rcp://*,scp://*,http://*,file://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau FileWritePre ".fnameescape(expand("<amatch>"))|exe "'[,']".'Nwrite '.fnameescape(expand("<amatch>"))|exe "sil doau FileWritePost ".fnameescape(expand("<amatch>"))
|
au FileWriteCmd ftp://*,rcp://*,scp://*,http://*,file://*,dav://*,davs://*,rsync://*,sftp://* exe "sil doau FileWritePre ".fnameescape(expand("<amatch>"))|exe "'[,']".'Nwrite '.fnameescape(expand("<amatch>"))|exe "sil doau FileWritePost ".fnameescape(expand("<amatch>"))
|
||||||
@@ -59,7 +59,7 @@ com! -count=1 -nargs=* Nread let s:svpos= winsaveview()<bar>call netrw#NetRead(
|
|||||||
com! -range=% -nargs=* Nwrite let s:svpos= winsaveview()<bar><line1>,<line2>call netrw#NetWrite(<f-args>)<bar>call winrestview(s:svpos)
|
com! -range=% -nargs=* Nwrite let s:svpos= winsaveview()<bar><line1>,<line2>call netrw#NetWrite(<f-args>)<bar>call winrestview(s:svpos)
|
||||||
com! -nargs=* NetUserPass call NetUserPass(<f-args>)
|
com! -nargs=* NetUserPass call NetUserPass(<f-args>)
|
||||||
com! -nargs=* Nsource let s:svpos= winsaveview()<bar>call netrw#NetSource(<f-args>)<bar>call winrestview(s:svpos)
|
com! -nargs=* Nsource let s:svpos= winsaveview()<bar>call netrw#NetSource(<f-args>)<bar>call winrestview(s:svpos)
|
||||||
com! -nargs=? Ntree call netrw#SetTreetop(1,<q-args>)
|
com! -nargs=? Ntree call netrw#SetTreetop(<q-args>)
|
||||||
|
|
||||||
" Commands: :Explore, :Sexplore, Hexplore, Vexplore, Lexplore {{{2
|
" Commands: :Explore, :Sexplore, Hexplore, Vexplore, Lexplore {{{2
|
||||||
com! -nargs=* -bar -bang -count=0 -complete=dir Explore call netrw#Explore(<count>,0,0+<bang>0,<q-args>)
|
com! -nargs=* -bar -bang -count=0 -complete=dir Explore call netrw#Explore(<count>,0,0+<bang>0,<q-args>)
|
||||||
@@ -81,7 +81,7 @@ if !exists("g:netrw_nogx")
|
|||||||
if !hasmapto('<Plug>NetrwBrowseX')
|
if !hasmapto('<Plug>NetrwBrowseX')
|
||||||
nmap <unique> gx <Plug>NetrwBrowseX
|
nmap <unique> gx <Plug>NetrwBrowseX
|
||||||
endif
|
endif
|
||||||
nno <silent> <Plug>NetrwBrowseX :call netrw#BrowseX(netrw#GX(),netrw#CheckIfRemote(netrw#GX()))<cr>
|
nno <silent> <Plug>NetrwBrowseX :call netrw#BrowseX(expand((exists("g:netrw_gx")? g:netrw_gx : '<cfile>')),netrw#CheckIfRemote())<cr>
|
||||||
endif
|
endif
|
||||||
if maparg('gx','v') == ""
|
if maparg('gx','v') == ""
|
||||||
if !hasmapto('<Plug>NetrwBrowseXVis')
|
if !hasmapto('<Plug>NetrwBrowseXVis')
|
||||||
@@ -129,15 +129,19 @@ fun! s:LocalBrowse(dirname)
|
|||||||
elseif isdirectory(a:dirname)
|
elseif isdirectory(a:dirname)
|
||||||
" call Decho("(LocalBrowse) dirname<".a:dirname."> ft=".&ft." (isdirectory, not amiga)")
|
" call Decho("(LocalBrowse) dirname<".a:dirname."> ft=".&ft." (isdirectory, not amiga)")
|
||||||
" call Dredir("LocalBrowse ft last set: ","verbose set ft")
|
" call Dredir("LocalBrowse ft last set: ","verbose set ft")
|
||||||
|
" call Decho("(s:LocalBrowse) COMBAK#23: buf#".bufnr("%")." file<".expand("%")."> line#".line(".")." col#".col("."))
|
||||||
sil! call netrw#LocalBrowseCheck(a:dirname)
|
sil! call netrw#LocalBrowseCheck(a:dirname)
|
||||||
|
" call Decho("(s:LocalBrowse) COMBAK#24: buf#".bufnr("%")." file<".expand("%")."> line#".line(".")." col#".col("."))
|
||||||
if exists("w:netrw_bannercnt") && line('.') < w:netrw_bannercnt
|
if exists("w:netrw_bannercnt") && line('.') < w:netrw_bannercnt
|
||||||
exe w:netrw_bannercnt
|
exe w:netrw_bannercnt
|
||||||
|
" call Decho("(s:LocalBrowse) COMBAK#25: buf#".bufnr("%")." file<".expand("%")."> line#".line(".")." col#".col("."))
|
||||||
endif
|
endif
|
||||||
|
|
||||||
else
|
else
|
||||||
" not a directory, ignore it
|
" not a directory, ignore it
|
||||||
" call Decho("(LocalBrowse) dirname<".a:dirname."> not a directory, ignoring...")
|
" call Decho("(LocalBrowse) dirname<".a:dirname."> not a directory, ignoring...")
|
||||||
endif
|
endif
|
||||||
|
" call Decho("(s:LocalBrowse) COMBAK#26: buf#".bufnr("%")." file<".expand("%")."> line#".line(".")." col#".col("."))
|
||||||
|
|
||||||
" call Dret("s:LocalBrowse")
|
" call Dret("s:LocalBrowse")
|
||||||
endfun
|
endfun
|
||||||
|
Reference in New Issue
Block a user