1
0
Fork 0
mirror of https://github.com/vim/vim synced 2025-03-16 06:47:52 +01:00

updated for version 7.0158

This commit is contained in:
Bram Moolenaar 2005-11-23 21:25:05 +00:00
parent af289d333a
commit a5792f5890
90 changed files with 9703 additions and 4368 deletions

View file

@ -687,6 +687,7 @@ LANG_GEN = \
runtime/tutor/tutor.ko.* \
runtime/tutor/tutor.pl.* \
runtime/tutor/tutor.ru.* \
runtime/tutor/tutor.sk.* \
runtime/tutor/tutor.zh.* \
runtime/spell/README.txt \
runtime/spell/??/*.diff \

View file

@ -70,8 +70,8 @@ all install uninstall tools config configure proto depend lint tags types test t
# compiled binaries.
# Before creating an archive first delete all backup files, *.orig, etc.
MAJOR = 6
MINOR = 3
MAJOR = 7
MINOR = 0aa
# Uncomment this line if the Win32s version is to be included.
#DOSBIN_S = dosbin_s
@ -423,12 +423,15 @@ dosrt: dist dist/$(COMMENT_RT) dosrt_unix2dos
-rm -rf dist/vim$(VERSION)rt.zip
cd dist && zip -9 -rD -z vim$(VERSION)rt.zip vim <$(COMMENT_RT)
# Split in two parts to avoid a "argument list too long" error.
dosrt_unix2dos: dist prepare no_title.vim
-rm -rf dist/vim
mkdir dist/vim
mkdir dist/vim/$(VIMRTDIR)
tar cf - \
$(RT_ALL) \
| (cd dist/vim/$(VIMRTDIR); tar xf -)
tar cf - \
$(RT_SCRIPTS) \
$(RT_DOS) \
$(RT_NO_UNIX) \

View file

@ -1,7 +1,7 @@
" Vim completion script
" Language: XHTML 1.0 Strict
" Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl )
" Last Change: 2005 Oct 12
" Last Change: 2005 Now 20
function! htmlcomplete#CompleteTags(findstart, base)
if a:findstart
@ -52,10 +52,13 @@ function! htmlcomplete#CompleteTags(findstart, base)
if exists("b:entitiescompl")
unlet! b:entitiescompl
" Very, very long line
let values = ["AElig", "Aacute", "Acirc", "Agrave", "Alpha", "Aring", "Atilde", "Auml", "Beta", "Ccedil", "Chi", "Dagger", "Delta", "ETH", "Eacute", "Ecirc", "Egrave", "Epsilon", "Eta", "Euml", "Gamma", "Iacute", "Icirc", "Igrave", "Iota", "Iuml", "Kappa", "Lambda", "Mu", "Ntilde", "Nu", "OElig", "Oacute", "Ocirc", "Ograve", "Omega", "Omicron", "Oslash", "Otilde", "Ouml", "Phi", "Pi", "Prime", "Psi", "Rho", "Scaron", "Sigma", "THORN", "TITY", "Tau", "Theta", "Uacute", "Ucirc", "Ugrave", "Upsilon", "Uuml", "Xi", "Yacute", "Yuml", "Zeta", "amp", "aacute", "acirc", "acute", "aelig", "agrave", "alefsym", "alpha", "and", "ang", "apos", "aring", "asymp", "atilde", "auml", "bdquo", "beta", "brvbar", "bull", "cap", "ccedil", "cedil", "cent", "chi", "circ", "clubs", "copy", "cong", "crarr", "cup", "curren", "dArr", "dagger", "darr", "deg", "delta", "diams", "divide", "eacute", "ecirc", "egrave", "empty", "ensp", "emsp", "epsilon", "equiv", "eta", "eth", "euro", "euml", "exist", "fnof", "forall", "frac12", "frac14", "frac34", "frasl", "gt", "gamma", "ge", "hArr", "harr", "hearts", "hellip", "iacute", "icirc", "iexcl", "igrave", "image", "infin", "int", "iota", "iquest", "isin", "iuml", "kappa", "lt", "laquo", "lArr", "lambda", "lang", "larr", "lceil", "ldquo", "le", "lfloor", "lowast", "loz", "lrm", "lsaquo", "lsquo", "macr", "mdash", "micro", "middot", "minus", "mu", "nbsp", "nabla", "ndash", "ne", "ni", "not", "notin", "nsub", "ntilde", "nu", "oacute", "ocirc", "oelig", "ograve", "oline", "omega", "omicron", "oplus", "or", "ordf", "ordm", "oslash", "otilde", "otimes", "ouml", "para", "part", "permil", "perp", "phi", "pi", "piv", "plusmn", "pound", "prime", "prod", "prop", "psi", "quot", "rArr", "raquo", "radic", "rang", "rarr", "rceil", "rdquo", "real", "reg", "rfloor", "rho", "rlm", "rsaquo", "rsquo", "sbquo", "scaron", "sdot", "sect", "shy", "sigma", "sigmaf", "sim", "spades", "sub", "sube", "sum", "sup", "sup1", "sup2", "sup3", "supe", "szlig", "tau", "there4", "theta", "thetasym", "thinsp", "thorn", "tilde", "times", "trade", "uArr", "uacute", "uarr", "ucirc", "ugrave", "uml", "upsih", "upsilon", "uuml", "weierp", "xi", "yacute", "yen", "yuml", "zeta", "zwj", "zwnj"]
if !exists("g:xmldata_xhtml10s")
runtime! autoload/xml/xhtml10s.vim
endif
for m in values
let entities = g:xmldata_xhtml10s['vimxmlentities']
for m in entities
if m =~ '^'.a:base
call add(res, m.';')
endif
@ -114,6 +117,7 @@ function! htmlcomplete#CompleteTags(findstart, base)
let head = getline(search('<head\>'), search('<\/head>'))
let headjoined = join(copy(head), ' ')
if headjoined =~ '<style'
" Remove possibly confusing CSS operators
let stylehead = substitute(headjoined, '+>\*[,', ' ', 'g')
if search_for == 'class'
let styleheadlines = split(stylehead)
@ -447,68 +451,18 @@ function! htmlcomplete#CompleteTags(findstart, base)
" Close tag
let b:unaryTagsStack = "base meta link hr br param img area input col"
if context =~ '^\/'
let opentag = htmlcomplete#GetLastOpenTag("b:unaryTagsStack")
let opentag = xmlcomplete#GetLastOpenTag("b:unaryTagsStack")
return [opentag.">"]
endif
" Deal with tag completion.
let opentag = htmlcomplete#GetLastOpenTag("b:unaryTagsStack")
" Clusters
let special = "br span bdo map object img"
let phrase = "em strong dfn code q samp kbd var cite abbr acronym sub sup"
let inlineforms = "input select textarea label button"
let miscinline = "ins del script"
let inline = "a ".special." ".phrase." ".inlineforms." tt i b big small"
let misc = "noscript ".miscinline
let block = "p h1 h2 h3 h4 h5 h6 div ul ol dl pre hr blockquote address fieldset table"
let opentag = xmlcomplete#GetLastOpenTag("b:unaryTagsStack")
if opentag == 'a'
let tags = split("tt i b big small ".special." ".phrase." ".inlineforms." ".miscinline)
elseif opentag =~ '^\(abbr\|acronym\|address\|b\|p\|h\d\|dt\|span\|bdo\|em\|strong\|dfn\|code\|samp\|kbd\|var\|cite\|q\|sub\|sup\|tt\|i\|big\|small\|label\|caption\)$'
let tags = split(inline." ".miscinline)
elseif opentag == 'pre'
let tags = split("a tt i b big small br span bdo map ".phrase." ".miscinline." ".inlineforms)
elseif opentag == 'html'
let tags = ["head", "body"]
elseif opentag == 'legend'
let tags = split(inline." ".miscinline)
elseif opentag == 'head'
let tags = ["title", "base", "scipt", "style", "meta", "link", "object"]
elseif opentag =~ '^\(noscript\|body\|blockquote\)$'
let tags = split("form ".block." ".misc)
elseif opentag =~ '^\(ul\|ol\)$'
let tags = ["li"]
elseif opentag == 'dl'
let tags = ["dt", "dd"]
elseif opentag =~ '^\(ins\|del\|th\|td\|dd\|div\|li\)$'
let tags = split("form ".block." ".inline." ".misc)
elseif opentag == 'object'
let tags = split("param form ".block." ".inline." ".misc)
elseif opentag == 'fieldset'
let tags = split("legend form ".block." ".inline." ".misc)
elseif opentag == 'map'
let tags = split("area form ".block." ".misc)
elseif opentag == 'form'
let tags = split(block." ".misc)
elseif opentag == 'select'
let tags = ["optgroup", "option"]
elseif opentag == 'optgroup'
let tags = ["option"]
elseif opentag == 'colgroup'
let tags = ["col"]
elseif opentag == '^\(textarea\|option\|script\|style\|title\)$'
let tags = ['empty']
elseif opentag == 'button'
let tags = ["p", "h1", "h2", "h3", "h4", "h5", "h6", "div", "ul", "ol", "dl", "table"]
elseif opentag =~ '^\(thead\|tfoot\|tbody\)$'
let tags = ["tr"]
elseif opentag == 'tr'
let tags = ["th", "td"]
elseif opentag == 'table'
let tags = ["caption", "col", "colgroup", "thead", "tfoot", "tbody", "tr"]
else
return []
if !exists("g:xmldata_xhtml10s")
runtime! autoload/xml/xhtml10s.vim
endif
let tags = g:xmldata_xhtml10s[opentag][0]
for m in tags
if m =~ '^'.context
call add(res, m)
@ -521,133 +475,3 @@ function! htmlcomplete#CompleteTags(findstart, base)
endif
endfunction
" MM: This is greatly reduced closetag.vim used with kind permission of Steven
" Mueller
" Changes: strip all comments; delete error messages
" Author: Steven Mueller <diffusor@ugcs.caltech.edu>
" Last Modified: Tue May 24 13:29:48 PDT 2005
" Version: 0.9.1
function! htmlcomplete#GetLastOpenTag(unaryTagsStack)
let linenum=line('.')
let lineend=col('.') - 1 " start: cursor position
let first=1 " flag for first line searched
let b:TagStack='' " main stack of tags
let startInComment=s:InComment()
let tagpat='</\=\(\k\|[-:]\)\+\|/>'
while (linenum>0)
let line=getline(linenum)
if first
let line=strpart(line,0,lineend)
else
let lineend=strlen(line)
endif
let b:lineTagStack=''
let mpos=0
let b:TagCol=0
while (mpos > -1)
let mpos=matchend(line,tagpat)
if mpos > -1
let b:TagCol=b:TagCol+mpos
let tag=matchstr(line,tagpat)
if exists('b:closetag_disable_synID') || startInComment==s:InCommentAt(linenum, b:TagCol)
let b:TagLine=linenum
call s:Push(matchstr(tag,'[^<>]\+'),'b:lineTagStack')
endif
let lineend=lineend-mpos
let line=strpart(line,mpos,lineend)
endif
endwhile
while (!s:EmptystackP('b:lineTagStack'))
let tag=s:Pop('b:lineTagStack')
if match(tag, '^/') == 0 "found end tag
call s:Push(tag,'b:TagStack')
elseif s:EmptystackP('b:TagStack') && !s:Instack(tag, a:unaryTagsStack) "found unclosed tag
return tag
else
let endtag=s:Peekstack('b:TagStack')
if endtag == '/'.tag || endtag == '/'
call s:Pop('b:TagStack') "found a open/close tag pair
elseif !s:Instack(tag, a:unaryTagsStack) "we have a mismatch error
return ''
endif
endif
endwhile
let linenum=linenum-1 | let first=0
endwhile
return ''
endfunction
function! s:InComment()
return synIDattr(synID(line('.'), col('.'), 0), 'name') =~ 'Comment'
endfunction
function! s:InCommentAt(line, col)
return synIDattr(synID(a:line, a:col, 0), 'name') =~ 'Comment'
endfunction
function! s:SetKeywords()
let g:IsKeywordBak=&iskeyword
let &iskeyword='33-255'
endfunction
function! s:RestoreKeywords()
let &iskeyword=g:IsKeywordBak
endfunction
function! s:Push(el, sname)
if !s:EmptystackP(a:sname)
exe 'let '.a:sname."=a:el.' '.".a:sname
else
exe 'let '.a:sname.'=a:el'
endif
endfunction
function! s:EmptystackP(sname)
exe 'let stack='.a:sname
if match(stack,'^ *$') == 0
return 1
else
return 0
endif
endfunction
function! s:Instack(el, sname)
exe 'let stack='.a:sname
call s:SetKeywords()
let m=match(stack, '\<'.a:el.'\>')
call s:RestoreKeywords()
if m < 0
return 0
else
return 1
endif
endfunction
function! s:Peekstack(sname)
call s:SetKeywords()
exe 'let stack='.a:sname
let top=matchstr(stack, '\<.\{-1,}\>')
call s:RestoreKeywords()
return top
endfunction
function! s:Pop(sname)
if s:EmptystackP(a:sname)
return ''
endif
exe 'let stack='.a:sname
call s:SetKeywords()
let loc=matchend(stack,'\<.\{-1,}\>')
exe 'let '.a:sname.'=strpart(stack, loc+1, strlen(stack))'
let top=strpart(stack, match(stack, '\<'), loc)
call s:RestoreKeywords()
return top
endfunction
function! s:Clearstack(sname)
exe 'let '.a:sname."=''"
endfunction

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,161 @@
" netrwSettings.vim: makes netrw settings simpler
" Date: Oct 12, 2005
" Maintainer: Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
" Version: 4
" Copyright: Copyright (C) 1999-2005 Charles E. Campbell, Jr. {{{1
" Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright
" notice is copied with it. Like anything else that's free,
" netrwSettings.vim is provided *as is* and comes with no
" warranty of any kind, either expressed or implied. By using
" this plugin, you agree that in no event will the copyright
" holder be liable for any damages resulting from the use
" of this software.
"
" Mat 4:23 (WEB) Jesus went about in all Galilee, teaching in their {{{1
" synagogues, preaching the gospel of the kingdom, and healing
" every disease and every sickness among the people.
" Load Once: {{{1
if exists("g:loaded_netrwSettings") || &cp
finish
endif
let g:loaded_netrwSettings = "v4"
" ---------------------------------------------------------------------
" NetrwSettings: {{{1
fun! netrwSettings#NetrwSettings()
" this call is here largely just to insure that netrw has been loaded
call netrw#NetSavePosn()
if !exists("g:loaded_netrw")
echohl WarningMsg | echomsg "***sorry*** netrw needs to be loaded prior to using NetrwSettings" | echohl None
return
endif
above wincmd s
enew
setlocal noswapfile bh=wipe
set ft=vim
file Netrw\ Settings
" these variables have the following default effects when they don't
" exist (ie. have not been set by the user in his/her .vimrc)
if !exists("g:netrw_longlist")
let g:netrw_longlist= 0
let g:netrw_list_cmd= "ssh HOSTNAME ls -FLa"
endif
if !exists("g:netrw_silent")
let g:netrw_silent= 0
endif
if !exists("g:netrw_use_nt_rcp")
let g:netrw_use_nt_rcp= 0
endif
if !exists("g:netrw_ftp")
let g:netrw_ftp= 0
endif
if !exists("g:netrw_ignorenetrc")
let g:netrw_ignorenetrc= 0
endif
put ='+ ---------------------------------------------'
put ='+ NetrwSettings: (by Charles E. Campbell, Jr.)'
put ='+ Press ? with cursor atop any line for help '
put ='+ ---------------------------------------------'
let s:netrw_settings_stop= line(".")
put =''
put ='+ Netrw Protocol Commands'
put = 'let g:netrw_dav_cmd = '.g:netrw_dav_cmd
put = 'let g:netrw_fetch_cmd = '.g:netrw_fetch_cmd
put = 'let g:netrw_ftp_cmd = '.g:netrw_ftp_cmd
put = 'let g:netrw_http_cmd = '.g:netrw_http_cmd
put = 'let g:netrw_rcp_cmd = '.g:netrw_rcp_cmd
put = 'let g:netrw_rsync_cmd = '.g:netrw_rsync_cmd
put = 'let g:netrw_scp_cmd = '.g:netrw_scp_cmd
put = 'let g:netrw_sftp_cmd = '.g:netrw_sftp_cmd
put = 'let g:netrw_ssh_cmd = '.g:netrw_ssh_cmd
let s:netrw_protocol_stop= line(".")
put = ''
put ='+Netrw Transfer Control'
put = 'let g:netrw_cygwin = '.g:netrw_cygwin
put = 'let g:netrw_ftp = '.g:netrw_ftp
put = 'let g:netrw_ftpmode = '.g:netrw_ftpmode
put = 'let g:netrw_ignorenetrc = '.g:netrw_ignorenetrc
put = 'let g:netrw_use_nt_rcp = '.g:netrw_use_nt_rcp
put = 'let g:netrw_win95ftp = '.g:netrw_win95ftp
let s:netrw_xfer_stop= line(".")
put = ''
put ='+ Netrw Browser Control'
put = 'let g:netrw_alto = '.g:netrw_alto
put = 'let g:netrw_altv = '.g:netrw_altv
put = 'let g:netrw_dirhistmax = '.g:netrw_dirhistmax
put = 'let g:netrw_ftp_browse_reject = '.g:netrw_ftp_browse_reject
put = 'let g:netrw_ftp_list_cmd = '.g:netrw_ftp_list_cmd
put = 'let g:netrw_hide = '.g:netrw_hide
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_local_mkdir = '.g:netrw_local_mkdir
put = 'let g:netrw_local_rmdir = '.g:netrw_local_rmdir
put = 'let g:netrw_longlist = '.g:netrw_longlist
put = 'let g:netrw_maxfilenamelen = '.g:netrw_maxfilenamelen
put = 'let g:netrw_mkdir_cmd = '.g:netrw_mkdir_cmd
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
put = 'let g:netrw_rmf_cmd = '.g:netrw_rmf_cmd
put = 'let g:netrw_silent = '.g:netrw_silent
put = 'let g:netrw_sort_by = '.g:netrw_sort_by
put = 'let g:netrw_sort_direction = '.g:netrw_sort_direction
put = 'let g:netrw_sort_sequence = '.g:netrw_sort_sequence
put = 'let g:netrw_ssh_browse_reject = '.g:netrw_ssh_browse_reject
put = 'let g:netrw_timefmt = '.g:netrw_timefmt
put = 'let g:netrw_winsize = '.g:netrw_winsize
put =''
put ='+ For help, place cursor on line and press ?'
1d
silent %s/^+/"/e
res 99
silent %s/= \([^0-9].*\)$/= '\1'/e
silent %s/= $/= ''/e
1
set nomod
map <buffer> <silent> ? :call NetrwSettingHelp()<cr>
let tmpfile= tempname()
exe 'au BufWriteCmd Netrw\ Settings silent w! '.tmpfile.'|so '.tmpfile.'|call delete("'.tmpfile.'")|set nomod'
endfun
" ---------------------------------------------------------------------
" NetrwSettingHelp: {{{2
fun! NetrwSettingHelp()
" call Dfunc("NetrwSettingHelp()")
let curline = getline(".")
if curline =~ '='
let varhelp = substitute(curline,'^\s*let ','','e')
let varhelp = substitute(varhelp,'\s*=.*$','','e')
" call Decho("trying help ".varhelp)
try
exe "he ".varhelp
catch /^Vim\%((\a\+)\)\=:E149/
echo "***sorry*** no help available for <".varhelp.">"
endtry
elseif line(".") < s:netrw_settings_stop
he netrw-settings
elseif line(".") < s:netrw_protocol_stop
he netrw-externapp
elseif line(".") < s:netrw_xfer_stop
he netrw-variables
else
he netrw-browse-var
endif
" call Dret("NetrwSettingHelp")
endfun
" ---------------------------------------------------------------------
" Modelines: {{{1
" vim:ts=8 fdm=marker

View file

@ -1,79 +1,172 @@
" tar.vim: Handles browsing tarfiles
" AUTOLOAD PORTION
" Date: Nov 18, 2005
" Version: 4
" Maintainer: Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
" License: Vim License (see vim's :help license)
"
" tar.vim -- a Vim plugin for browsing tarfiles
" Copyright (c) 2002, Michael C. Toren <mct@toren.net>
" Distributed under the GNU General Public License.
" Contains many ideas from Michael Toren's <tar.vim>
"
" Version: 2
" Date: Sep 14, 2005
" Modified By: Charles E. Campbell, Jr.
"
" Updates are available from <http://michael.toren.net/code/>. If you
" find this script useful, or have suggestions for improvements, please
" let me know.
" Also look there for further comments and documentation.
"
" This part defines the functions. The autocommands are in plugin/tar.vim.
if exists("g:loaded_tar") || &cp
finish
endif
let g:loaded_tar= "v2"
" Copyright: Copyright (C) 2005 Charles E. Campbell, Jr. {{{1
" Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright
" notice is copied with it. Like anything else that's free,
" tarPlugin.vim is provided *as is* and comes with no warranty
" of any kind, either expressed or implied. By using this
" plugin, you agree that in no event will the copyright
" holder be liable for any damages resulting from the use
" of this software.
" ---------------------------------------------------------------------
" tar#Read: {{{1
fun! tar#Read(argument, cleanup)
" call Dfunc("tar#Read(argument<".a:argument."> cleanup=".a:cleanup.")")
let l:argument = a:argument
let l:argument = substitute(l:argument, '^tarfile:', '', '')
let l:argument = substitute(l:argument, '^\~', $HOME, '')
" Initialization: {{{1
let s:keepcpo= &cpo
set cpo&vim
if exists("g:loaded_tar")
finish
endif
let g:loaded_tar= "v4"
let l:tarfile = l:argument
while 1
if (l:tarfile == "" || l:tarfile == "/")
echo "***error*** (tar#Read) Could not find a readable tarfile in path:" l:argument
" call Dret("tar#Read")
return
endif
" ---------------------------------------------------------------------
" Default Settings: {{{1
if !exists("g:tar_browseoptions")
let g:tar_browseoptions= "Ptf"
endif
if !exists("g:tar_readoptions")
let g:tar_readoptions= "OPxf"
endif
if !exists("g:tar_writeoptions")
let g:tar_writeoptions= "uf"
endif
if filereadable(l:tarfile) " found it!
break
endif
" ----------------
" Functions: {{{1
" ----------------
let l:tarfile = fnamemodify(l:tarfile, ":h")
endwhile
" ---------------------------------------------------------------------
" tar#Browse: {{{2
fun! tar#Browse(tarfile)
" call Dfunc("tar#Browse(tarfile<".a:tarfile.">)")
let l:toextract = strpart(l:argument, strlen(l:tarfile) + 1)
" sanity checks
if !executable("tar")
echohl Error | echo '***error*** (tar#Browse) "tar" not available on your system'
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
" call Dret("tar#Browse")
return
endif
if !filereadable(a:tarfile)
if a:tarfile !~# '^\a\+://'
" if its an url, don't complain, let url-handlers such as vim do its thing
echohl Error | echo "***error*** (tar#Browse) File not readable<".a:tarfile.">" | echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
endif
" call Dret("tar#Browse : file<".a:tarfile."> not readable")
return
endif
if &ma != 1
set ma
endif
let w:tarfile= a:tarfile
if (l:toextract == "")
" call Dret("tar#Read")
return
endif
setlocal noswapfile
setlocal buftype=nofile
setlocal bufhidden=hide
setlocal nobuflisted
setlocal nowrap
set ft=tar
let l:cat = s:TarCatCommand(l:tarfile)
execute "r !" . l:cat . " < '" . l:tarfile . "'"
\ " | tar OPxf - '" . l:toextract . "'"
" give header
exe "$put ='".'\"'." tar.vim version ".g:loaded_tar."'"
exe "$put ='".'\"'." Browsing tarfile ".a:tarfile."'"
exe "$put ='".'\"'." Select a file with cursor and press ENTER"."'"
0d
$
if (a:cleanup)
0d "blank line
execute "doautocmd BufReadPost " . expand("%")
setlocal nomod
silent preserve
endif
" call Dret("tar#Read")
if a:tarfile =~# '\.\(gz\|tgz\)$'
exe "silent r! gzip -d -c '".a:tarfile."'| tar -".g:tar_browseoptions." - "
elseif a:tarfile =~# '\.bz2$'
exe "silent r! bzip2 -d -c '".a:tarfile."'| tar -".g:tar_browseoptions." - "
else
exe "silent r! tar -".g:tar_browseoptions." '".a:tarfile."'"
endif
%g@/$@d
setlocal noma nomod ro
noremap <silent> <buffer> <cr> :call <SID>TarBrowseSelect()<cr>
" call Dret("tar#Browse : w:tarfile<".w:tarfile.">")
endfun
" ---------------------------------------------------------------------
" tar#Write: {{{1
fun! tar#Write(argument)
" call Dfunc("tar#Write(argument<".a:argument.">)")
"
" TarBrowseSelect: {{{2
fun! s:TarBrowseSelect()
" call Dfunc("TarBrowseSelect() w:tarfile<".w:tarfile."> curfile<".expand("%").">")
let fname= getline(".")
" call Decho("fname<".fname.">")
" sanity check
if fname =~ '^"'
" call Dret("TarBrowseSelect")
return
endif
" about to make a new window, need to use w:tarfile
let tarfile= w:tarfile
let curfile= expand("%")
new
wincmd _
let s:tblfile_{winnr()}= curfile
" call Decho("exe e tarfile:".tarfile.':'.fname)
exe "e tarfile:".tarfile.':'.fname
filetype detect
" call Dret("TarBrowseSelect : s:tblfile_".winnr()."<".s:tblfile_{winnr()}.">")
endfun
" ---------------------------------------------------------------------
" tar#Read: {{{2
fun! tar#Read(fname,mode)
" call Dfunc("tar#Read(fname<".a:fname.">,mode=".a:mode.")")
let tarfile = substitute(a:fname,'tarfile:\(.\{-}\):.*$','\1','')
let fname = substitute(a:fname,'tarfile:.\{-}:\(.*\)$','\1','')
" call Decho("tarfile<".tarfile."> fname<".fname.">")
if tarfile =~# '\.\(gz\|tgz\)$'
" call Decho("exe silent r! gzip -d -c '".tarfile."'| tar -OPxf - '".fname."'")
exe "silent r! gzip -d -c '".tarfile."'| tar -".g:tar_readoptions." - '".fname."'"
elseif a:fname =~# '\.bz2$'
" call Decho("exe silent r! bzip2 -d -c '".tarfile."'| tar -".g:tar_readoptions." - '".fname."'")
exe "silent r! bzip2 -d -c '".tarfile."'| tar -".g:tar_readoptions." - '".fname."'"
else
" call Decho("exe silent r! tar -".g:tar_readoptions." '".tarfile."' '".fname."'")
exe "silent r! tar -".g:tar_readoptions." '".tarfile."' '".fname."'"
endif
let w:tarfile= a:fname
exe "file tarfile:".fname
" cleanup
0d
set nomod
" call Dret("tar#Read : w:tarfile<".w:tarfile.">")
endfun
" ---------------------------------------------------------------------
" tar#Write: {{{2
fun! tar#Write(fname)
" call Dfunc("tar#Write(fname<".a:fname.">) w:tarfile<".w:tarfile."> tblfile_".winnr()."<".s:tblfile_{winnr()}.">")
" sanity checks
if !executable("tar")
echo "***error*** (TarWrite) sorry, your system doesn't appear to have the tar pgm"
echohl Error | echo '***error*** (tar#Browse) "tar" not available on your system'
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
" call Dret("tar#Write")
return
endif
if !exists("*mkdir")
echo "***error*** (TarWrite) sorry, mkdir() doesn't work on your system"
echohl Error | echo "***error*** (tar#Write) sorry, mkdir() doesn't work on your system" | echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
" call Dret("tar#Write")
return
endif
@ -91,44 +184,104 @@ fun! tar#Write(argument)
try
exe "cd ".escape(tmpdir,' \')
catch /^Vim\%((\a\+)\)\=:E344/
echo "***error*** (TarWrite) cannot cd to temporary directory"
echohl Error | echo "***error*** (tar#Write) cannot cd to temporary directory" | Echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
" call Dret("tar#Write")
return
endtry
" call Decho("current directory now: ".getcwd())
" place temporary files under .../_TARVIM_/
if isdirectory("_TARVIM_")
call s:Rmdir("_TARVIM_")
" place temporary files under .../_ZIPVIM_/
if isdirectory("_ZIPVIM_")
call s:Rmdir("_ZIPVIM_")
endif
call mkdir("_TARVIM_")
cd _TARVIM_
call mkdir("_ZIPVIM_")
cd _ZIPVIM_
" call Decho("current directory now: ".getcwd())
let tarfile = curdir."/".substitute(a:argument,'tarfile:\([^/]\{-}\)/.*$','\1','')
let path = substitute(a:argument,'^.\{-}/','','')
let dirpath = substitute(path,'/\=[^/]\+$','','')
" call Decho("path <".path.">")
" call Decho("dirpath<".dirpath.">")
call mkdir(dirpath,"p")
exe "w! ".path
if executable("cygpath")
let path = substitute(system("cygpath ".path),'\n','','e')
let tarfile = substitute(system("cygpath ".tarfile),'\n','','e')
let tarfile = substitute(w:tarfile,'tarfile:\(.\{-}\):.*$','\1','')
let fname = substitute(w:tarfile,'tarfile:.\{-}:\(.*\)$','\1','')
" handle compressed archives
if tarfile =~# '\.gz'
call system("gzip -d ".tarfile)
let tarfile = substitute(tarfile,'\.gz','','e')
let compress= "gzip '".tarfile."'"
elseif tarfile =~# '\.tgz'
call system("gzip -d ".tarfile)
let tarfile = substitute(tarfile,'\.tgz','.tar','e')
let compress= "gzip '".tarfile."'"
let tgz = 1
elseif tarfile =~# '\.bz2'
call system("bzip2 -d ".tarfile)
let tarfile = substitute(tarfile,'\.bz2','','e')
let compress= "bzip2 '".tarfile."'"
endif
" call Decho("tar --delete -f ".tarfile." ".path)
call system("tar --delete -f ".tarfile." ".path)
if v:shell_error != 0
echo "***error*** (TarWrite) sorry, your tar pgm doesn't support deletion of ".path
echohl Error | echo "***error*** (tar#Write) sorry, unable to update ".tarfile." with ".fname | echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
else
" call Decho("tar -rf ".tarfile." ".path)
call system("tar -rf ".tarfile." ".path)
" call Decho("tarfile<".tarfile."> fname<".fname.">")
let dirpath = substitute(fname,'/[^/]\+$','','e')
if tarfile !~ '/'
let tarfile= curdir.'/'.tarfile
endif
" call Decho("tarfile<".tarfile."> fname<".fname.">")
call mkdir(dirpath,"p")
exe "w! ".fname
if executable("cygpath")
let dirpath = substitute(system("cygpath ".dirpath),'\n','','e')
let tarfile = substitute(system("cygpath ".tarfile),'\n','','e')
endif
" delete old file from tarfile
" call Decho("tar --delete -f '".tarfile."' '".fname."'")
call system("tar --delete -f '".tarfile."' '".fname."'")
if v:shell_error != 0
echohl Error | echo "***error*** (tar#Write) sorry, unable to update ".tarfile." with ".fname | echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
else
" update tarfile with new file
" call Decho("tar -".g:tar_writeoptions." '".tarfile."' '".fname."'")
call system("tar -".g:tar_writeoptions." '".tarfile."' '".fname."'")
if v:shell_error != 0
echohl Error | echo "***error*** (tar#Write) sorry, unable to update ".tarfile." with ".fname | echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
elseif exists("compress")
" call Decho("call system(".compress.")")
call system(compress)
if exists("tgz")
" call Decho("rename(".tarfile.".gz,".substitute(tarfile,'\.tar$','.tgz','e').")")
call rename(tarfile.".gz",substitute(tarfile,'\.tar$','.tgz','e'))
endif
endif
endif
" support writing tarfiles across a network
if s:tblfile_{winnr()} =~ '^\a\+://'
" call Decho("handle writing <".tarfile."> across network to <".s:tblfile_{winnr()}.">")
let tblfile= s:tblfile_{winnr()}
1split|enew
let binkeep= &binary
let eikeep = &ei
set binary ei=all
exe "e! ".tarfile
call netrw#NetWrite(tblfile)
let &ei = eikeep
let &binary = binkeep
q!
unlet s:tblfile_{winnr()}
endif
endif
" cleanup and restore current directory
cd ..
call s:Rmdir("_TARVIM_")
call s:Rmdir("_ZIPVIM_")
exe "cd ".escape(curdir,' \')
setlocal nomod
@ -136,91 +289,7 @@ fun! tar#Write(argument)
endfun
" ---------------------------------------------------------------------
" tar#Browse: {{{1
fun! tar#Browse(tarfile)
" call Dfunc("tar#Browse(tarfile<".a:tarfile.">)")
setlocal noswapfile
setlocal buftype=nofile
setlocal bufhidden=hide
setlocal filetype=
setlocal nobuflisted
setlocal buftype=nofile
setlocal wrap
setlocal syntax=tar
let l:tarfile = a:tarfile
let b:tarfile = l:tarfile
let l:cat = s:TarCatCommand(l:tarfile)
if ! filereadable(l:tarfile)
let l:tarfile = substitute(l:tarfile, '^tarfile:', '', '')
endif
if ! filereadable(l:tarfile)
echo "***error*** (tar#Browse) File not readable:" l:tarfile
" call Dret("tar#Browse")
return
endif
call s:Say("\" tar.vim version " . g:loaded_tar)
call s:Say("\" Browsing tarfile " . l:tarfile)
call s:Say("\" Hit ENTER to view a file in a new window")
call s:Say("")
silent execute "r!" . l:cat . "<'" . l:tarfile . "'| tar Ptf - "
0d "blank line
/^$/1
setlocal noma nomod ro
noremap <silent> <buffer> <cr> :call <SID>TarBrowseSelect()<cr>
" call Dret("tar#Browse")
endfun
" ---------------------------------------------------------------------
" TarBrowseSelect: {{{1
fun! s:TarBrowseSelect()
let l:line = getline(".")
if (l:line =~ '^" ')
return
endif
if (l:line =~ '/$')
echo "Please specify a file, not a directory"
return
endif
let l:selection = "tarfile:" . b:tarfile . "/" . l:line
new
wincmd _
execute "e " . l:selection
endfun
" ---------------------------------------------------------------------
" TarCatCommand: kludge to deal with compressed archives {{{1
fun! s:TarCatCommand(tarfile)
" call Dfunc("s:TarCatCommand(tarfile<".a:tarfile.">)")
if a:tarfile =~# '\.\(gz\|tgz\|Z\)$'
let l:cat = "gzip -d -c"
elseif a:tarfile =~# '\.bz2$'
let l:cat = "bzip2 -d -c"
else
let l:cat = "cat"
endif
" call Dret("s:TarCatCommand ".l:cat)
return l:cat
endfun
" ---------------------------------------------------------------------
" Say: {{{1
fun! s:Say(string)
let @" = a:string
$ put
endfun
" ---------------------------------------------------------------------
" Rmdir: {{{1
" Rmdir: {{{2
fun! s:Rmdir(fname)
" call Dfunc("Rmdir(fname<".a:fname.">)")
if has("unix")
@ -235,6 +304,8 @@ fun! s:Rmdir(fname)
" call Dret("Rmdir")
endfun
" ---------------------------------------------------------------------
" Modelines: {{{1
" vim:set ts=8 sts=4 sw=4 fdm=marker:
" ------------------------------------------------------------------------
" Modelines And Restoration: {{{1
let &cpo= s:keepcpo
unlet s:keepcpo
" vim:ts=8 fdm=marker

View file

@ -0,0 +1,428 @@
" Vim completion script
" Language: XHTML 1.0 Strict
" Maintainer: Mikolaj Machowski ( mikmach AT wp DOT pl )
" Last Change: 2005 Nov 22
" This function will create Dictionary with users namespace strings and values
" canonical (system) names of data files. Names should be lowercase,
" descriptive to avoid any future conflicts. For example 'xhtml10s' should be
" name for data of XHTML 1.0 Strict and 'xhtml10t' for XHTML 1.0 Transitional
" User interface will be provided by XMLns command defined ...
" Currently supported canonicals are:
" xhtml10s - XHTML 1.0 Strict
" xsl - XSL
function! xmlcomplete#CreateConnection(canonical, ...)
" When only one argument provided treat name as default namespace (without
" 'prefix:').
if exists("a:1")
let users = a:1
else
let users = 'DEFAULT'
endif
" Source data file. Due to suspected errors in autoload do it with
" :runtime.
" TODO: make it properly (using autoload, that is) later
exe "runtime autoload/xml/".a:canonical.".vim"
" Remove all traces of unexisting files to return [] when trying
" omnicomplete something
" TODO: give warning about non-existing canonicals - should it be?
if !exists("g:xmldata_".a:canonical)
unlet! g:xmldata_connection
return 0
endif
" We need to initialize Dictionary to add key-value pair
if !exists("g:xmldata_connection")
let g:xmldata_connection = {}
endif
let g:xmldata_connection[users] = a:canonical
endfunction
function! xmlcomplete#CreateEntConnection(...)
if a:0 > 0
let g:xmldata_entconnect = a:1
else
let g:xmldata_entconnect = 'DEFAULT'
endif
endfunction
function! xmlcomplete#CompleteTags(findstart, base)
if a:findstart
" locate the start of the word
let line = getline('.')
let start = col('.') - 1
let compl_begin = col('.') - 2
while start >= 0 && line[start - 1] =~ '\(\k\|[:.-]\)'
let start -= 1
endwhile
if start >= 0 && line[start - 1] =~ '&'
let b:entitiescompl = 1
let b:compl_context = ''
return start
endif
let b:compl_context = getline('.')[0:(compl_begin)]
let b:compl_context = matchstr(b:compl_context, '.*<\zs.*')
" Make sure we will have only current namespace
unlet! b:xml_namespace
let b:xml_namespace = matchstr(b:compl_context, '^\k*\ze:')
if b:xml_namespace == ''
let b:xml_namespace = 'DEFAULT'
endif
return start
else
" There is no connction of namespace and data file. Abandon action
if !exists("g:xmldata_connection") || g:xmldata_connection == {}
return []
endif
" Initialize base return lists
let res = []
let res2 = []
" a:base is very short - we need context
let context = b:compl_context
unlet! b:compl_context
" Make entities completion
if exists("b:entitiescompl")
unlet! b:entitiescompl
if !exists("g:xmldata_entconnect") || g:xmldata_entconnect == 'DEFAULT'
let values = g:xmldata{'_'.g:xmldata_connection['DEFAULT']}['vimxmlentities']
else
let values = g:xmldata{'_'.g:xmldata_entconnect}['vimxmlentities']
endif
" Get only lines with entity declarations but throw out
" parameter-entities - they may be completed in future
let entdecl = filter(getline(1, "$"), 'v:val =~ "<!ENTITY\\s\\+[^%]"')
if len(entdecl) > 0
let intent = map(copy(entdecl), 'matchstr(v:val, "<!ENTITY\\s\\+\\zs\\(\\k\\|[.-:]\\)\\+\\ze")')
let values = intent + values
endif
for m in values
if m =~ '^'.a:base
call add(res, m.';')
endif
endfor
return res
endif
if context =~ '>'
" Generally if context contains > it means we are outside of tag and
" should abandon action
return []
endif
" find tags matching with "a:base"
" If a:base contains white space it is attribute.
" It could be also value of attribute...
" We have to get first word to offer
" proper completions
if context == ''
let tag = ''
else
let tag = split(context)[0]
endif
" Get rid of namespace
let tag = substitute(tag, '^'.b:xml_namespace.':', '', '')
" Get last word, it should be attr name
let attr = matchstr(context, '.*\s\zs.*')
" Possible situations where any prediction would be difficult:
" 1. Events attributes
if context =~ '\s'
" If attr contains =\s*[\"'] we catched value of attribute
if attr =~ "=\s*[\"']"
" Let do attribute specific completion
let attrname = matchstr(attr, '.*\ze\s*=')
let entered_value = matchstr(attr, ".*=\\s*[\"']\\zs.*")
if tag =~ '^[?!]'
" Return nothing if we are inside of ! or ? tag
return []
else
let values = g:xmldata{'_'.g:xmldata_connection[b:xml_namespace]}[tag][1][attrname]
endif
if len(values) == 0
return []
endif
" We need special version of sbase
let attrbase = matchstr(context, ".*[\"']")
let attrquote = matchstr(attrbase, '.$')
for m in values
" This if is needed to not offer all completions as-is
" alphabetically but sort them. Those beginning with entered
" part will be as first choices
if m =~ '^'.entered_value
call add(res, m . attrquote.' ')
elseif m =~ entered_value
call add(res2, m . attrquote.' ')
endif
endfor
return res + res2
endif
if tag =~ '?xml'
" Two possible arguments for <?xml> plus variation
let attrs = ['encoding', 'version="1.0"', 'version']
elseif tag =~ '^!'
" Don't make completion at all
return []
else
let attrs = keys(g:xmldata{'_'.g:xmldata_connection[b:xml_namespace]}[tag][1])
endif
for m in sort(attrs)
if m =~ '^'.attr
if tag !~ '^[?!]' && len(g:xmldata{'_'.g:xmldata_connection[b:xml_namespace]}[tag][1][m]) > 0 && g:xmldata{'_'.g:xmldata_connection[b:xml_namespace]}[tag][1][m][0] =~ '^BOOL$'
call add(res, m)
elseif m =~ '='
call add(res, m)
else
call add(res, m.'="')
endif
elseif m =~ attr
if tag !~ '^[?!]' && len(g:xmldata{'_'.g:xmldata_connection[b:xml_namespace]}[tag][1][m]) > 0 && g:xmldata{'_'.g:xmldata_connection[b:xml_namespace]}[tag][1][m][0] =~ '^BOOL$'
call add(res, m)
elseif m =~ '='
call add(res, m)
else
call add(res2, m.'="')
endif
endif
endfor
return res + res2
endif
" Close tag
let b:unaryTagsStack = "base meta link hr br param img area input col"
if context =~ '^\/'
let opentag = xmlcomplete#GetLastOpenTag("b:unaryTagsStack")
return [opentag.">"]
endif
" Complete elements of XML structure
" TODO: #REQUIRED, #IMPLIED, #FIXED, #PCDATA - but these should be detected like
" entities - in first run
" keywords: CDATA, ID, IDREF, IDREFS, ENTITY, ENTITIES, NMTOKEN, NMTOKENS
" are hardly recognizable but keep it in reserve
" also: EMPTY ANY SYSTEM PUBLIC DATA
if context =~ '^!'
let tags = ['!ELEMENT', '!DOCTYPE', '!ATTLIST', '!ENTITY', '!NOTATION', '![CDATA[', '![INCLUDE[', '![IGNORE[']
for m in tags
if m =~ '^'.context
let m = substitute(m, '^!\[\?', '', '')
call add(res, m)
elseif m =~ context
let m = substitute(m, '^!\[\?', '', '')
call add(res2, m)
endif
endfor
return res + res2
endif
" Complete text declaration
let g:co = context
if context =~ '^?'
let tags = ['?xml']
for m in tags
if m =~ '^'.context
call add(res, substitute(m, '^?', '', ''))
elseif m =~ context
call add(res, substitute(m, '^?', '', ''))
endif
endfor
return res + res2
endif
" Deal with tag completion.
let opentag = xmlcomplete#GetLastOpenTag("b:unaryTagsStack")
let opentag = substitute(opentag, '^\k*:', '', '')
let tags = g:xmldata{'_'.g:xmldata_connection[b:xml_namespace]}[opentag][0]
let context = substitute(context, '^\k*:', '', '')
if b:xml_namespace == 'DEFAULT'
let b:xml_namespace = ''
else
let b:xml_namespace .= ':'
endif
for m in tags
if m =~ '^'.context
call add(res, b:xml_namespace.m)
elseif m =~ context
call add(res2, b:xml_namespace.m)
endif
endfor
return res + res2
endif
endfunction
" MM: This is greatly reduced closetag.vim used with kind permission of Steven
" Mueller
" Changes: strip all comments; delete error messages; add checking for
" namespace
" Author: Steven Mueller <diffusor@ugcs.caltech.edu>
" Last Modified: Tue May 24 13:29:48 PDT 2005
" Version: 0.9.1
function! xmlcomplete#GetLastOpenTag(unaryTagsStack)
let linenum=line('.')
let lineend=col('.') - 1 " start: cursor position
let first=1 " flag for first line searched
let b:TagStack='' " main stack of tags
let startInComment=s:InComment()
if exists("b:xml_namespace")
if b:xml_namespace == 'DEFAULT'
let tagpat='</\=\(\k\|[.-]\)\+\|/>'
else
let tagpat='</\='.b:xml_namespace.':\(\k\|[.-]\)\+\|/>'
endif
else
let tagpat='</\=\(\k\|[.-:]\)\+\|/>'
endif
while (linenum>0)
let line=getline(linenum)
if first
let line=strpart(line,0,lineend)
else
let lineend=strlen(line)
endif
let b:lineTagStack=''
let mpos=0
let b:TagCol=0
while (mpos > -1)
let mpos=matchend(line,tagpat)
if mpos > -1
let b:TagCol=b:TagCol+mpos
let tag=matchstr(line,tagpat)
if exists('b:closetag_disable_synID') || startInComment==s:InCommentAt(linenum, b:TagCol)
let b:TagLine=linenum
call s:Push(matchstr(tag,'[^<>]\+'),'b:lineTagStack')
endif
let lineend=lineend-mpos
let line=strpart(line,mpos,lineend)
endif
endwhile
while (!s:EmptystackP('b:lineTagStack'))
let tag=s:Pop('b:lineTagStack')
if match(tag, '^/') == 0 "found end tag
call s:Push(tag,'b:TagStack')
elseif s:EmptystackP('b:TagStack') && !s:Instack(tag, a:unaryTagsStack) "found unclosed tag
return tag
else
let endtag=s:Peekstack('b:TagStack')
if endtag == '/'.tag || endtag == '/'
call s:Pop('b:TagStack') "found a open/close tag pair
elseif !s:Instack(tag, a:unaryTagsStack) "we have a mismatch error
return ''
endif
endif
endwhile
let linenum=linenum-1 | let first=0
endwhile
return ''
endfunction
function! s:InComment()
return synIDattr(synID(line('.'), col('.'), 0), 'name') =~ 'Comment'
endfunction
function! s:InCommentAt(line, col)
return synIDattr(synID(a:line, a:col, 0), 'name') =~ 'Comment'
endfunction
function! s:SetKeywords()
let g:IsKeywordBak=&iskeyword
let &iskeyword='33-255'
endfunction
function! s:RestoreKeywords()
let &iskeyword=g:IsKeywordBak
endfunction
function! s:Push(el, sname)
if !s:EmptystackP(a:sname)
exe 'let '.a:sname."=a:el.' '.".a:sname
else
exe 'let '.a:sname.'=a:el'
endif
endfunction
function! s:EmptystackP(sname)
exe 'let stack='.a:sname
if match(stack,'^ *$') == 0
return 1
else
return 0
endif
endfunction
function! s:Instack(el, sname)
exe 'let stack='.a:sname
call s:SetKeywords()
let m=match(stack, '\<'.a:el.'\>')
call s:RestoreKeywords()
if m < 0
return 0
else
return 1
endif
endfunction
function! s:Peekstack(sname)
call s:SetKeywords()
exe 'let stack='.a:sname
let top=matchstr(stack, '\<.\{-1,}\>')
call s:RestoreKeywords()
return top
endfunction
function! s:Pop(sname)
if s:EmptystackP(a:sname)
return ''
endif
exe 'let stack='.a:sname
call s:SetKeywords()
let loc=matchend(stack,'\<.\{-1,}\>')
exe 'let '.a:sname.'=strpart(stack, loc+1, strlen(stack))'
let top=strpart(stack, match(stack, '\<'), loc)
call s:RestoreKeywords()
return top
endfunction
function! s:Clearstack(sname)
exe 'let '.a:sname."=''"
endfunction

View file

@ -1,7 +1,7 @@
" zip.vim: Handles browsing zipfiles
" AUTOLOAD PORTION
" Date: Sep 16, 2005
" Version: 2
" Date: Nov 14, 2005
" Version: 4
" Maintainer: Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
" License: Vim License (see vim's :help license)
" Copyright: Copyright (C) 2005 Charles E. Campbell, Jr. {{{1
@ -22,7 +22,7 @@ if exists("g:loaded_zip")
finish
endif
let g:loaded_zip= "v2"
let g:loaded_zip= "v4"
" ----------------
" Functions: {{{1
@ -41,9 +41,12 @@ fun! zip#Browse(zipfile)
return
endif
if !filereadable(a:zipfile)
echohl Error | echo "***error*** (zip#Browse) File not readable<".a:zipfile.">" | echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
" call Dret("zip#Browse")
if a:zipfile !~# '^\a\+://'
" if its an url, don't complain, let url-handlers such as vim do its thing
echohl Error | echo "***error*** (zip#Browse) File not readable<".a:zipfile.">" | echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
endif
" call Dret("zip#Browse : file<".a:zipfile."> not readable")
return
endif
if &ma != 1
@ -80,7 +83,7 @@ endfun
" ---------------------------------------------------------------------
" ZipBrowseSelect: {{{2
fun! s:ZipBrowseSelect()
" call Dfunc("ZipBrowseSelect() zipfile<".w:zipfile.">")
" call Dfunc("ZipBrowseSelect() zipfile<".w:zipfile."> curfile<".expand("%").">")
let fname= getline(".")
" sanity check
@ -99,13 +102,15 @@ fun! s:ZipBrowseSelect()
" get zipfile to the new-window
let zipfile= substitute(w:zipfile,'.zip$','','e')
let curfile= expand("%")
new
wincmd _
let s:zipfile_{winnr()}= curfile
exe "e zipfile:".zipfile.':'.fname
filetype detect
" call Dret("ZipBrowseSelect")
" call Dret("ZipBrowseSelect : s:zipfile_".winnr()."<".s:zipfile_{winnr()}.">")
endfun
" ---------------------------------------------------------------------
@ -128,7 +133,7 @@ endfun
" ---------------------------------------------------------------------
" zip#Write: {{{2
fun! zip#Write(fname)
" call Dfunc("zip#Write(fname<".a:fname.")")
" call Dfunc("zip#Write(fname<".a:fname.") zipfile_".winnr()."<".s:zipfile_{winnr()}.">")
" sanity checks
if !executable("zip")
@ -192,6 +197,21 @@ fun! zip#Write(fname)
if v:shell_error != 0
echohl Error | echo "***error*** (zip#Write) sorry, unable to update ".zipfile." with ".fname | echohl None
call inputsave()|call input("Press <cr> to continue")|call inputrestore()
elseif s:zipfile_{winnr()} =~ '^\a\+://'
" support writing zipfiles across a network
let netzipfile= s:zipfile_{winnr()}
" call Decho("handle writing <".zipfile.".zip> across network as <".netzipfile.">")
1split|enew
let binkeep= &binary
let eikeep = &ei
set binary ei=all
exe "e! ".zipfile.".zip"
call netrw#NetWrite(netzipfile)
let &ei = eikeep
let &binary = binkeep
q!
unlet s:zipfile_{winnr()}
endif
" cleanup and restore current directory

View file

@ -2,14 +2,8 @@
" Language: eRuby
" Maintainer: Doug Kearns <djkea2 at gus.gscit.monash.edu.au>
" Info: $Id$
" URL: http://vim-ruby.sourceforge.net
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" ----------------------------------------------------------------------------
if exists("current_compiler")

17
runtime/compiler/fpc.vim Normal file
View file

@ -0,0 +1,17 @@
" Vim compiler file
" Compiler: FPC 2.1
" Maintainer: Jaroslaw Blasiok <jaro3000@o2.pl>
" Last Change: 2005 October 07
if exists("current_compiler")
finish
endif
let current_compiler = "fpc"
if exists(":CompilerSet") != 2 " older Vim always used :setlocal
command -nargs=* CompilerSet setlocal <args>
endif
" NOTE: compiler must be runned with -vb to write whole source path, not only file
" name.
CompilerSet errorformat=%f(%l\\,%c)\ %m

View file

@ -1,8 +1,8 @@
" Vim compiler file
" Compiler: HP aCC
" Maintainer: Matthias Ulrich <matthias-ulrich@web.de>
" URL: http://www.subhome.de/vim/hp_acc.vim
" Last Change: 2004 Mar 27
" URL: http://www.subhome.de/vim/hp_acc.vim
" Last Change: 2005 Nov 19
"
" aCC --version says: "HP ANSI C++ B3910B A.03.13"
" This compiler has been tested on:
@ -10,6 +10,10 @@
"
" Tim Brown's aCC is: "HP ANSI C++ B3910B A.03.33"
" and it also works fine...
"
" Now suggestions by aCC are supported (compile flag aCC +w).
" Thanks to Tim Brown again!!
"
if exists("current_compiler")
finish
@ -21,6 +25,7 @@ if exists(":CompilerSet") != 2 " older Vim always used :setlocal
endif
CompilerSet errorformat=%A%trror\ %n\:\ \"%f\"\\,\ line\ %l\ \#\ %m,
\%A%tarning\ (suggestion)\ %n\:\ \"%f\"\\,\ line\ %l\ \#\ %m\ %#,
\%A%tarning\ %n\:\ \"%f\"\\,\ line\ %l\ \#\ %m\ %#,
\%Z\ \ \ \ %p^%.%#,
\%-C%.%#

View file

@ -5,12 +5,6 @@
" Info: $Id$
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" ----------------------------------------------------------------------------
"
" Changelog:

View file

@ -2,14 +2,8 @@
" Language: Test::Unit - Ruby Unit Testing Framework
" Maintainer: Doug Kearns <djkea2 at gus.gscit.monash.edu.au>
" Info: $Id$
" URL: http://vim-ruby.sourceforge.net
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" ----------------------------------------------------------------------------
if exists("current_compiler")

View file

@ -1,4 +1,4 @@
*autocmd.txt* For Vim version 7.0aa. Last change: 2005 Oct 10
*autocmd.txt* For Vim version 7.0aa. Last change: 2005 Nov 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -812,6 +812,10 @@ option will not cause any commands to be executed.
autocommands for that group. Note: if you use an
undefined group name, Vim gives you an error message.
After applying the autocommands the modelines are
processed, so that their overrule the settings from
autocommands, like what happens when editing a file.
*:doautoa* *:doautoall*
:doautoa[ll] [group] {event} [fname]
Like ":doautocmd", but apply the autocommands to each

View file

@ -1,4 +1,4 @@
*cmdline.txt* For Vim version 7.0aa. Last change: 2005 Sep 17
*cmdline.txt* For Vim version 7.0aa. Last change: 2005 Nov 21
VIM REFERENCE MANUAL by Bram Moolenaar
@ -562,7 +562,7 @@ argument for the command, which has a different meaning. For example:
"name"
==============================================================================
4. Ex command-line ranges *cmdline-ranges* *[range]* *E16* *E493*
4. Ex command-line ranges *cmdline-ranges* *[range]* *E16*
Some Ex commands accept a line range in front of them. This is noted as
[range]. It consists of one or more line specifiers, separated with ',' or
@ -648,11 +648,15 @@ When folds are active the line numbers are rounded off to include the whole
closed fold. See |fold-behavior|.
Reverse Range
Reverse Range *E493*
A range should have the lower line number first. If this is not the case, Vim
will ask you if it should swap the line numbers. This is not done within the
global command ":g".
will ask you if it should swap the line numbers.
Backwards range given, OK to swap ~
This is not done within the global command ":g".
You can use ":silent" before a command to avoid the question, the range will
always be swapped then.
Count and Range *N:*

View file

@ -1,4 +1,4 @@
*eval.txt* For Vim version 7.0aa. Last change: 2005 Oct 12
*eval.txt* For Vim version 7.0aa. Last change: 2005 Nov 20
VIM REFERENCE MANUAL by Bram Moolenaar
@ -5050,6 +5050,9 @@ This also works when reading a variable that has not been set yet: >
:let l = foo#bar#lvar
However, when the autoload script was already loaded it won't be loaded again
for an unknown variable.
When assigning a value to such a variable nothing special happens. This can
be used to pass settings to the autoload script before it's loaded: >

View file

@ -1,4 +1,4 @@
*if_perl.txt* For Vim version 7.0aa. Last change: 2005 Mar 29
*if_perl.txt* For Vim version 7.0aa. Last change: 2005 Oct 14
VIM REFERENCE MANUAL by Sven Verdoolaege
@ -9,6 +9,7 @@ Perl and Vim *perl* *Perl*
1. Editing Perl files |perl-editing|
2. Compiling VIM with Perl interface |perl-compiling|
3. Using the Perl interface |perl-using|
4. Dynamic loading |perl-dynamic|
{Vi does not have any of these commands}
@ -259,4 +260,22 @@ function: >
endif
Note that "EOF" must be at the start of the line.
==============================================================================
4. Dynamic loading *perl-dynamic*
On MS-Windows the Perl library can be loaded dynamically. The |:version|
output then includes |+perl/dyn|.
This means that Vim will search for the Perl DLL file only when needed. When
you don't use the Perl interface you don't need it, thus you can use Vim
without this DLL file.
To use the Perl interface the Perl DLL must be in your search path. In a
console window type "path" to see what directories are used.
The name of the DLL must match the Perl version Vim was compiled with.
Currently the name is "perl58.dll". That is for Perl 5.8. To know for
sure edit "gvim.exe" and search for "perl\d*.dll\c".
==============================================================================
vim:tw=78:ts=8:ft=help:norl:

View file

@ -1,4 +1,4 @@
*if_pyth.txt* For Vim version 7.0aa. Last change: 2005 Mar 29
*if_pyth.txt* For Vim version 7.0aa. Last change: 2005 Oct 14
VIM REFERENCE MANUAL by Paul Moore
@ -11,6 +11,7 @@ The Python Interface to Vim *python* *Python*
3. Buffer objects |python-buffer|
4. Range objects |python-range|
5. Window objects |python-window|
6. Dynamic loading |python-dynamic|
{Vi does not have any of these commands}
@ -299,5 +300,22 @@ Window attributes are:
The height attribute is writable only if the screen is split horizontally.
The width attribute is writable only if the screen is split vertically.
==============================================================================
6. Dynamic loading *python-dynamic*
On MS-Windows the Python library can be loaded dynamically. The |:version|
output then includes |+python/dyn|.
This means that Vim will search for the Python DLL file only when needed.
When you don't use the Python interface you don't need it, thus you can use
Vim without this DLL file.
To use the Python interface the Python DLL must be in your search path. In a
console window type "path" to see what directories are used.
The name of the DLL must match the Python version Vim was compiled with.
Currently the name is "python24.dll". That is for Python 2.4. To know for
sure edit "gvim.exe" and search for "python\d*.dll\c".
==============================================================================
vim:tw=78:ts=8:ft=help:norl:

View file

@ -1,4 +1,4 @@
*if_ruby.txt* For Vim version 7.0aa. Last change: 2005 Aug 31
*if_ruby.txt* For Vim version 7.0aa. Last change: 2005 Oct 14
VIM REFERENCE MANUAL by Shugo Maeda
@ -11,6 +11,7 @@ The Ruby Interface to Vim *ruby* *Ruby*
3. VIM::Buffer objects |ruby-buffer|
4. VIM::Window objects |ruby-window|
5. Global variables |ruby-globals|
6. Dynamic loading |ruby-dynamic|
{Vi does not have any of these commands}
*E266* *E267* *E268* *E269* *E270* *E271* *E272* *E273*
@ -166,12 +167,29 @@ cursor = [{row}, {col}]
Sets the cursor position to {row} and {col}.
==============================================================================
4. Global variables *ruby-globals*
5. Global variables *ruby-globals*
There are two global variables.
$curwin The current window object.
$curbuf The current buffer object.
==============================================================================
6. Dynamic loading *ruby-dynamic*
On MS-Windows the Ruby library can be loaded dynamically. The |:version|
output then includes |+ruby/dyn|.
This means that Vim will search for the Ruby DLL file only when needed. When
you don't use the Ruby interface you don't need it, thus you can use Vim
without this DLL file.
To use the Ruby interface the Ruby DLL must be in your search path. In a
console window type "path" to see what directories are used.
The name of the DLL must match the Ruby version Vim was compiled with.
Currently the name is "ruby18.dll". That is for Ruby 1.8. To know for sure
edit "gvim.exe" and search for "ruby\d*.dll\c".
==============================================================================
vim:tw=78:ts=8:ft=help:norl:

View file

@ -1,4 +1,4 @@
*if_tcl.txt* For Vim version 7.0aa. Last change: 2005 Mar 29
*if_tcl.txt* For Vim version 7.0aa. Last change: 2005 Oct 14
VIM REFERENCE MANUAL by Ingo Wilken
@ -14,6 +14,7 @@ The Tcl Interface to Vim *tcl* *Tcl* *TCL*
6. Miscellaneous; Output from Tcl |tcl-misc| |tcl-output|
7. Known bugs & problems |tcl-bugs|
8. Examples |tcl-examples|
9. Dynamic loading |tcl-dynamic|
{Vi does not have any of these commands} *E280* *E281*
@ -508,5 +509,22 @@ startup file (usually "~/.vimrc" on Unix):
tclfile ~/.vimrc.tcl
endif
==============================================================================
9. Dynamic loading *tcl-dynamic*
On MS-Windows the Tcl library can be loaded dynamically. The |:version|
output then includes |+tcl/dyn|.
This means that Vim will search for the Tcl DLL file only when needed. When
you don't use the Tcl interface you don't need it, thus you can use Vim
without this DLL file.
To use the Tcl interface the Tcl DLL must be in your search path. In a
console window type "path" to see what directories are used.
The name of the DLL must match the Tcl version Vim was compiled with.
Currently the name is "tcl83.dll". That is for Tcl 8.3. To know for sure
edit "gvim.exe" and search for "tcl\d*.dll\c".
==============================================================================
vim:tw=78:ts=8:ft=help:norl:

View file

@ -1,4 +1,4 @@
*insert.txt* For Vim version 7.0aa. Last change: 2005 Oct 02
*insert.txt* For Vim version 7.0aa. Last change: 2005 Nov 22
VIM REFERENCE MANUAL by Bram Moolenaar
@ -975,6 +975,7 @@ PmenuThumb thumb of the scrollbar |hl-PmenuThumb|
Filetype-specific remarks for omni completion *compl-omni-filetypes*
C *ft-c-omni*
Completion of C code requires a tags file. You should use Exuberant ctags,
@ -1007,7 +1008,14 @@ When the same structure name appears in multiple places all possible members
are included.
CSS *ft-css-omni*
Complete properties and their appropriate values according to CSS 2.1
specification.
(X)HTML *ft-html-omni*
*ft-xhtml-omni*
CTRL-X CTRL-O provides completion of various elements of (X)HTML files.
It is designed to support writing of XHTML 1.0 Strict files but will
@ -1019,23 +1027,124 @@ also works for other versions of HTML. Features:
a tag)
- when attribute has limited number of possible values help to complete
them
- complete names of entities
- complete values of "class" and "id" attributes with data obtained from
style tag and included CSS files
- when completing "style" attribute or working inside of "style" tag
switch to |ft-css-omni| completion
- when used after "</" CTRL-X CTRL-O will close the last opened tag
File htmlcomplete.vim provides through |autoload| mechanism
Note: When used first time completion menu will be shown with little delay
- this is time needed for loading of data file.
XML *ft-xml-omni*
Vim 7 provides mechanism to context aware completion of XML files. It depends
on special |xml-data-file| and two commands: |:XMLns| and |:XMLent|. Features
are:
- after "<" complete tag name depending on context (no div suggest
inside of an a tag)
- inside of tag complete proper attributes (no width attribute for an
a tag)
- when attribute has limited number of possible values help to complete
them
- complete names of entities (defined in |xml-data-file| and in current file
with "<!ENTITY" declarations
- when used after "</" CTRL-X CTRL-O will close the last opened tag
Format of XML data file *xml-omni-datafile*
Vim distribution provides two data files as examples (xhtml10s.vim, xsl.vim)
XML data files are stored in "autoload/xml" directory in 'runtimepath'. They
have meaningful name which will be used in commands. It should be unique name
which will not create conflicts in future. For example name xhtml10s.vim means
it is data file for XHTML 1.0 Strict.
File contains one variable with fixed name: g:xmldata_xhtml10s . It is
compound from two parts:
1. "g:xmldata_" general prefix
2. "xhtml10s" name of file and name of described XML dialect
Part two must be exactly the same as name of file.
Variable is data structure in form of |Dictionary|. Keys are tag names and
values are two element |List|. First element of List is also List with
names of possible children, second element is |Dictionary| with names of
attributes as keys and possible values of attributes as values. Example: >
let g:xmldata_crippledhtml = {
\ "html":
\ [ ["body", "head"], {"id": [], "xmlns": ["http://www.w3.org/1999/xhtml"],
\ "lang": [], "xml:lang": [], "dir": ["ltr", "rtl"]}],
\ "script":
\ [ [], {"id": [], "charset": [], "type": ["text/javascript"], "src": [],
\ "defer": ["BOOL"], "xml:space": ["preserve"]}],
\ "meta":
\ [ [], {"id": [], "http-equiv": [], "name": [], "content": [], "scheme":
\ [], "lang": [], "xml:lang": [], "dir": ["ltr", "rtl"]}]
\ "vimxmlentities": ["amp", "lt", "gt", "apos", "quot"]}
This example should be put in "autoload/xml/crippledhtml.vim" file.
In example are visible two special elements:
1. "vimxmlentities" - special key with List containing entities of this XML
dialect.
2. "BOOL" - value of attribute key showing if attribute should be inserted
bare ("defer" vs. 'defer="'). It can be the only element of List of
attribute values.
Note: Tag names in data file MUST not contain namespace description. Check
xsl.vim for example.
Commands
:XMLns {name} [{namespace}] *:XMLns*
Vim has to know which data file should be used and with which namespace. For
loading of data file and connecting data with prope namespace use |:XMLns|
command. First (obligatory) argument is name of data (xhtml10s, xsl). Second
argument is code of namespace (h, xsl). When used without second argument
dialect will be used as default - without namespace declaration. For example
to use XML completion in .xsl files: >
:XMLns xhtml10s
:XMLns xsl xsl
:XMLent {name} *:XMLent*
By default entities will be completed from data file of default
namespace. XMLent command should be used in case when there is no
default namespace: >
:XMLent xhtml10s
Usage
While used in situation (after declarations from previous part, | is
cursor position): >
<|
Will complete to appropriate XHTML tag, and in this situation: >
<xsl:|
Will complete to appropriate XSL tag.
File xmlcomplete.vim provides through |autoload| mechanism
GetLastOpenTag function which can be used in XML files to get name of
last open tag with (b:unaryTagsStack has to be defined): >
:echo htmlcomplete#GetLastOpenTag("b:unaryTagsStack")
:echo xmlcomplete#GetLastOpenTag("b:unaryTagsStack")
CSS *ft-css-omni*
Complete properties and their appropriate values according to CSS 2.1
specification.
==============================================================================

View file

@ -1,4 +1,4 @@
*map.txt* For Vim version 7.0aa. Last change: 2005 Sep 22
*map.txt* For Vim version 7.0aa. Last change: 2005 Oct 14
VIM REFERENCE MANUAL by Bram Moolenaar
@ -966,8 +966,10 @@ completion can be enabled:
-complete=custom,{func} custom completion, defined via {func}
-complete=customlist,{func} custom completion, defined via {func}
Custom completion *:command-completion-custom*
*E467* *E468*
Custom completion *:command-completion-custom*
*:command-completion-customlist*
*E467* *E468*
It is possible to define customized completion schemes via the "custom,{func}"
or the "customlist,{func}" completion argument. The {func} part should be a
function with the following prototype >
@ -981,13 +983,13 @@ For the "custom" argument, the function should return the completion
candidates one per line in a newline separated string.
For the "customlist" argument, the function should return the completion
candidates as a Vim List. Non-string items in the list are ignored.
candidates as a Vim List. Non-string items in the list are ignored.
The function arguments are:
ArgLead the leading portion of the argument currently being
completed on
CmdLine the entire command line
CursorPos the cursor position in it
CursorPos the cursor position in it (byte index)
The function may use these for determining context. For the "custom"
argument, it is not necessary to filter candidates against the (implicit
pattern in) ArgLead. Vim will do filter the candidates with its regexp engine
@ -1009,6 +1011,7 @@ the 'path' option: >
: return split(globpath(&path, a:ArgLead), "\n")
:endfun
<
Range handling *E177* *E178*
By default, user-defined commands do not accept a line number range. However,

View file

@ -1,4 +1,4 @@
*mbyte.txt* For Vim version 7.0aa. Last change: 2005 Jul 09
*mbyte.txt* For Vim version 7.0aa. Last change: 2005 Oct 14
VIM REFERENCE MANUAL by Bram Moolenaar et al.
@ -484,6 +484,12 @@ conversion needs to be done. These conversions are supported:
request a very large buffer, more than Vim is willing to provide).
Try getting another iconv() implementation.
*iconv-dynamic*
On MS-Windows Vim can be compiled with the |+iconv/dyn| feature. This means
Vim will search for the "iconv.dll" and "libiconv.dll" libraries. When
neither of them can be found Vim will still work but some conversions won't be
possible.
==============================================================================
4. Using a terminal *mbyte-terminal*

View file

@ -1,4 +1,4 @@
*options.txt* For Vim version 7.0aa. Last change: 2005 Oct 05
*options.txt* For Vim version 7.0aa. Last change: 2005 Nov 23
VIM REFERENCE MANUAL by Bram Moolenaar
@ -76,10 +76,8 @@ achieve special effects. These options come in three forms:
comma separated list, a comma is added, unless the
value was empty.
If the option is a list of flags, superfluous flags
are removed. Otherwise there is no check for doubled
values. You can avoid this by removing a value first.
Example: >
:set guioptions-=T guioptions+=T
are removed. When adding a flag that was already
present the option value doesn't change.
< Also see |:set-args| above.
{not in Vi}
@ -988,6 +986,9 @@ A jump table for the options with a short description can be found at |Q_op|.
Watch out for special characters, see |option-backslash|.
When $TMPDIR, $TMP or $TEMP is not defined, it is not used for the
default value. "/tmp/*" is only used for Unix.
Note that the default also makes sure that "crontab -e" works (when a
backup would be made by renaming the original file crontab won't see
the newly created file). Also see 'backupcopy' and |crontab|.
*'balloondelay'* *'bdlay'*
'balloondelay' 'bdlay' number (default: 600)
@ -2927,10 +2928,11 @@ A jump table for the options with a short description can be found at |Q_op|.
The name of an external program that will be used to format the lines
selected with the "gq" command. The program must take the input on
stdin and produce the output on stdout. The Unix program "fmt" is
such a program. If this option is an empty string, the internal
format function will be used |C-indenting|. Environment variables are
expanded |:set_env|. See |option-backslash| about including spaces
and backslashes.
such a program.
If this option is an empty string, the internal format function will
be used |C-indenting|.
Environment variables are expanded |:set_env|. See |option-backslash|
about including spaces and backslashes.
This option cannot be set from a |modeline| or in the |sandbox|, for
security reasons.

View file

@ -1,8 +1,8 @@
*pi_netrw.txt* For Vim version 7.0. Last change: Oct 03, 2005
*pi_netrw.txt* For Vim version 7.0. Last change: Aug 31, 2005
VIM REFERENCE MANUAL by Charles E. Campbell, Jr.
*dav* *http* *network* *rcp* *scp*
*fetch* *netrw* *Nread* *rsync* *sftp*
*ftp* *netrw.vim* *Nwrite* *netrw-file*
@ -25,7 +25,7 @@
4. Transparent File Transfer............................|netrw-transparent|
5. Ex Commands..........................................|netrw-ex|
6. Variables and Options................................|netrw-var|
7. Directory Browsing...................................|netrw-browse| {{{1
7. Directory Browser....................................|netrw-browse| {{{1
Maps...............................................|netrw-maps|
Exploring..........................................|netrw-explore-cmds|
Quick Reference Commands Table.....................|netrw-browse-cmds|
@ -194,8 +194,8 @@ file using root-relative paths, use the full path:
2. Network-Oriented File Transfer *netrw-xfer*
Network-oriented file transfer under Vim is implemented by a VimL-based script
(<netrw.vim>) using plugin techniques. It currently supports both reading and
writing across networks using rcp, scp, ftp or ftp+<.netrc>, scp, fetch,
(<netrw.vim>) using plugin techniques. It currently supports both reading
and writing across networks using rcp, scp, ftp or ftp+<.netrc>, scp, fetch,
dav/cadaver, rsync, or sftp.
http is currently supported read-only via use of wget or fetch.
@ -206,23 +206,24 @@ FileReadCmd, BufWriteCmd) to intercept reads/writes with url-like filenames. >
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
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
<netrw.vim> script will clean up.
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 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 <netrw.vim> script will
clean up.
One may modify any protocol's implementing external application by setting a
variable (ex. scp uses the variable g:netrw_scp_cmd, which is defaulted to
"scp -q").
One may modify any protocol's implementing external application
by setting a variable (ex. scp uses the variable g:netrw_scp_cmd,
which is defaulted to "scp -q").
Ftp, an old protocol, seems to be blessed by numerous implementations.
Unfortunately, some implementations are noisy (ie., add junk to the end of the
file). Thus, concerned users may decide to write a NetReadFixup() function
that will clean up after reading with their ftp. Some Unix systems (ie.,
FreeBSD) provide a utility called "fetch" which uses the ftp protocol but is
not noisy and more convenient, actually, for <netrw.vim> to use.
Unfortunately, some implementations are noisy (ie., add junk to the end
of the file). Thus, concerned users may decide to write a NetReadFixup()
function that will clean up after reading with their ftp. Some Unix systems
(ie., FreeBSD) provide a utility called "fetch" which uses the ftp protocol
but is not noisy and more convenient, actually, for <netrw.vim> to use.
Consequently, if "fetch" is executable, it will be used to do reads for
ftp://... (and http://...) . See |netrw-var| for more about this.
@ -331,9 +332,8 @@ The script attempts to get passwords for ftp invisibly using |inputsecret()|,
a built-in Vim function. See |netrw-uidpass| for how to change the password
after one has set it.
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.
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.
==============================================================================
@ -341,28 +341,21 @@ However, |netrw-listhack| can help with this problem.
Network-oriented file transfers are available by default whenever
|'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: >
set nocp
if version >= 600
filetype plugin indent on
endif
<
system's vim-plugin directory and is sourced automatically whenever you
bring up vim.
==============================================================================
4. Transparent File Transfer *netrw-transparent*
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. >
Thus one may use files across networks as if they were local. >
vim ftp://[user@]machine/path
...
:wq
See |netrw-activate| for more on how to encourage your vim to use plugins
such as netrw.
==============================================================================
5. Ex Commands *netrw-ex*
@ -376,7 +369,8 @@ additional commands available.
:[range]Nw {netfile} [{netfile}]...
Write the specified lines to the {netfile}.
:Nread Read the specified lines into the current
:Nread
Read the specified lines into the current
buffer from the file specified in
b:netrw_lastfile.
@ -407,11 +401,10 @@ additional commands available.
The script <netrw.vim> uses several variables which can affect <netrw.vim>'s
behavior. These variables typically may be set in the user's <.vimrc> file:
(also see |netrw-settings|) >
-------------
Netrw Options
-------------
>
-------------
Netrw Options
-------------
Option Meaning
-------------- -----------------------------------------------
<
@ -488,12 +481,12 @@ variables listed below, and may be modified by the user.
-------------------------------------------------------------------------
<
*netrw-ftp*
The first two options both help with certain ftp's that give trouble
otherwise. In order to best understand how to use these options if ftp is
giving you troubles, a bit of discussion follows on how netrw does ftp reads.
The first two options both help with certain ftp's that give trouble otherwise.
In order to best understand how to use these options if ftp is giving you
troubles, a bit of discussion follows on how netrw does ftp reads.
The g:netrw_..._cmd variables specify the external program to use handle the
associated protocol (rcp, ftp, etc), plus any options.
The g:netrw_..._cmd variables specify the external program to use handle
the associated protocol (rcp, ftp, etc), plus any options.
The g:netrw_list_cmd's HOSTNAME entry will be changed via substitution with
whatever the current request is for a hostname.
@ -526,8 +519,8 @@ userid and password. The transferred file is put into a temporary file.
The temporary file is then read into the main editing session window that
requested it and the temporary file deleted.
If your ftp doesn't accept the "user" command and immediately just demands a
userid, then try putting "let netrw_ftp=1" in your <.vimrc>.
If your ftp doesn't accept the "user" command and immediately just demands
a userid, then try putting "let netrw_ftp=1" in your <.vimrc>.
*netrw-cadaver*
To handle the SSL certificate dialog for untrusted servers, one may pull
@ -554,12 +547,12 @@ messages) you may write a NetReadFixup(tmpfile) function:
endif
endfunction
>
The NetReadFixup() function will be called if it exists and thus allows you to
customize your reading process. As a further example, <netrw.vim> contains
just such a function to handle Windows 95 ftp. For whatever reason, Windows
95's ftp dumps four blank lines at the end of a transfer, and so it is
desirable to automate their removal. Here's some code taken from <netrw.vim>
itself:
The NetReadFixup() function will be called if it exists and thus allows
you to customize your reading process. As a further example, <netrw.vim>
contains just such a function to handle Windows 95 ftp. For whatever
reason, Windows 95's ftp dumps four blank lines at the end of a transfer,
and so it is desirable to automate their removal. Here's some code taken
from <netrw.vim> itself:
>
if has("win95") && g:netrw_win95ftp
fun! NetReadFixup(method, line1, line2)
@ -572,7 +565,7 @@ itself:
>
==============================================================================
7. Directory Browsing *netrw-browse* *netrw-dir* *netrw-list* *netrw-help*
7. Directory Browser *netrw-browse* *netrw-dir* *netrw-list* *netrw-help*
MAPS *netrw-maps*
?................Help.......................................|netrw-help|
@ -663,13 +656,12 @@ NETRW BROWSER VARIABLES *netrw-browse-var*
: 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_hide* if true, the hiding list is used
default: =0
*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_keepdir* =1 (default) keep current directory immune from
the browsing directory.
@ -684,11 +676,16 @@ NETRW BROWSER VARIABLES *netrw-browse-var*
*g:netrw_longlist* if =1, then long listing will be default
*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_list_hide* comma separated pattern list for hiding files
default: ""
*g:netrw_local_mkdir* command for making a local directory
default: "mkdir"
default: "ssh HOSTNAME mkdir"
*g:netrw_local_rmdir* remove directory command (rmdir)
default: "rmdir"
@ -712,6 +709,9 @@ NETRW BROWSER VARIABLES *netrw-browse-var*
*g:netrw_rmf_cmd* command for removing softlinks
default: "ssh HOSTNAME rm -f"
*g:netrw_hide* if true, the hiding list is used
default: =0
*g:netrw_sort_by* sort by "name", "time", or "size"
default: "name"
@ -723,18 +723,6 @@ NETRW BROWSER VARIABLES *netrw-browse-var*
default: '[\/]$,*,\.bak$,\.o$,\.h$,
\.info$,\.swp$,\.obj$'
*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
*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_timefmt* specify format string to strftime() (%c)
default: "%c"
@ -744,7 +732,7 @@ NETRW BROWSER VARIABLES *netrw-browse-var*
INTRODUCTION TO DIRECTORY BROWSING *netrw-browse-intro*
Netrw supports the browsing of directories on the local system and on remote
hosts, including listing files and directories, entering directories, editing
hosts, including generating listing 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
@ -755,15 +743,13 @@ 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.
To use Netrw's remote directory browser, simply attempt to read a "file" with a
To enter the netrw 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/
For local directories, the trailing slash is not required.
If you'd like to avoid entering the password in for remote directory listings
with ssh or scp, see |netrw-listhack|.
If you'd like to avoid entering the password in for directory listings, scp,
ssh interaction, etc, see |netrw-listhack|.
*netrw-explore* *netrw-pexplore*
*netrw-hexplore* *netrw-sexplore*
@ -797,8 +783,7 @@ By default, these commands use the current file's directory. However, one
may explicitly provide a directory (path) to use.
(Following needs v7.0 or later) *netrw-starstar*
When Explore, Sexplore, Hexplore, or Vexplore are used with a **,
such as:
When Explore, Sexplore, Hexplore, or Vexplore are used like
>
:Explore **/filename_pattern
<
@ -812,8 +797,7 @@ The directory display is updated to show the subdirectory containing a
matching file. One may then proceed to the next (or previous) matching files'
directories by using Nexplore or Pexplore, respectively. If your console or
gui produces recognizable shift-up or shift-down sequences, then you'll likely
find using shift-downarrow and shift-uparrow convenient. They're mapped by
netrw:
find the following mappings convenient:
<s-down> == Nexplore, and
<s-up> == Pexplore.
@ -838,12 +822,11 @@ refresh a local directory by using ":e .".
GOING UP *netrw--*
To go up a directory, press "-" or press the <cr> when atop the ../ directory
To go up a directory, press - or his the <cr> when atop the ../ directory
entry in the listing.
Netrw will use the command in |g:netrw_list_cmd| to perform the directory
listing operation after changing HOSTNAME to the host specified by the
user-provided url. By default netrw provides the command as:
Netrw will modify the command in |g:netrw_list_cmd| to perform the directory
listing operation. By default the command is:
ssh HOSTNAME ls -FLa
@ -858,13 +841,7 @@ BROWSING *netrw-cr*
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.
CAVEAT: There are three 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.
protocol given in the original read request.
OBTAINING A FILE *netrw-O*
@ -872,21 +849,7 @@ OBTAINING A FILE *netrw-O*
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.
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.
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|.
available for browsing, that shouldn't be a problem).
THIN, LONG, AND WIDE LISTINGS *netrw-i*
@ -896,27 +859,21 @@ The "i" map cycles between the thin, long, and wide listing formats.
The short listing format gives just the files' and directories' names.
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.
directories or displays the filename, file size (in bytes), and the
time and date of last modification for local directories.
The wide listing format has a multi-column display of the various files in the
netrw current directory, rather like the Unix "ls" presents. In this mode the
"b" and "B" maps are not available; instead, use Nb (|netrw-Nb|) and NB
(|netrw-NB|). 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.
The wide listing format has a multi-column display of the various
files in the netrw current directory, rather like the Unix "ls" presents.
In this mode the "b" and "B" maps are not available; instead, use
Nb (|netrw-Nb|) and NB (|netrw-NB|).
MAKING A NEW DIRECTORY *netrw-d*
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
global variable g:netrw_local_mkdir). Netrw will issue a request for the new
directory's name. A bare <CR> at that point will abort the making of the
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 global variable g:netrw_local_mkdir). Netrw will issue a request for the
new directory's name. A bare <CR> at that point will abort the making of the
directory. Attempts to make a local directory that already exists (as either
a file or a directory) will be detected, reported on, and ignored.
@ -924,12 +881,12 @@ a file or a directory) will be detected, reported on, and ignored.
DELETING FILES OR DIRECTORIES *netrw-delete* *netrw-D*
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".
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".
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
@ -966,17 +923,17 @@ the V (|linewise-visual|).
HIDING FILES OR DIRECTORIES *netrw-a*
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.
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.
The g:netrw_list_hide variable holds a comma delimited list of patterns (ex.
\.obj) which specify the hiding list. (also see |netrw-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.
The g:netrw_list_hide variable holds a comma delimited list of patterns
(ex. \.obj) which specify the hiding list. (also see |netrw-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.
EDIT FILE OR DIRECTORY HIDING LIST *netrw-h* *netrw-edithide*
@ -984,8 +941,7 @@ EDIT FILE OR DIRECTORY HIDING LIST *netrw-h* *netrw-edithide*
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|).
either be hidden (ie. not shown) or be the only ones displayed (see |netrw-a|).
BROWSING WITH A HORIZONTALLY SPLIT WINDOW *netrw-o* *netrw-horiz*
@ -994,9 +950,9 @@ 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|)
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
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
@ -1005,30 +961,30 @@ in your <.vimrc>.
PREVIEW WINDOW *netrw-p* *netrw-preview*
One may use a preview window (currently only for local browsing) by using the
"p" key when the cursor is atop the desired filename to be previewed.
One may use a preview window (currently only for local browsing) by using
the "p" key when the cursor is atop the desired filename to be previewed.
SELECTING SORTING STYLE *netrw-s* *netrw-sort*
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.
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.
EDITING THE SORTING SEQUENCE *netrw-S* *netrw-sortsequence*
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:
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.
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.
REVERSING SORTING ORDER *netrw-r* *netrw-reverse*
@ -1055,13 +1011,13 @@ q map to list both the bookmarks and history. (see |netrw-q|)
BROWSING WITH A VERTICALLY SPLIT WINDOW *netrw-v*
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 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
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
let g:netrw_altv = 1
@ -1077,24 +1033,24 @@ handler varies:
* for Windows 32 or 64, the url and FileProtocolHandler dlls are used.
* for KDE (with kfmclient): kfmclient is used.
* for Gnome (with gnome-open): gnome-open is used.
* otherwise the netrwFileHandler plugin 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.
appropriate application to use to "handle" these files. Such things
as OpenOffice (*.sfx), visualization (*.jpg, *.gif, etc), and PostScript
(*.ps, *.eps) can be handled.
The netrwFileHandler applies a user-defined function to a file, based on its
The NetrwFileHandler applies a user-defined function to a file, based on its
extension. Of course, the handler function must exist for it to be called!
>
Ex. mypgm.html x ->
netrwFileHandler_html("scp://user@host/some/path/mypgm.html")
NetrwFileHandler_html("scp://user@host/some/path/mypgm.html")
<
See the <plugin/netrwFileHandlers.vim> for an example of how to handle an html
See the <plugin/NetrwFileHandlers.vim> for an example of how to handle an html
file with mozilla.
One may write custom netrwFileHandlers; please look at the
plugin/netrwFileHandlers.vim script for examples. If its likely to be
One may write custom NetrwFileHandlers; please look at the
plugin/NetrwFileHandlers.vim script for examples. If its likely to be
generally useful, please feel free to forward a copy to me for future
inclusion in the distribution.
@ -1107,8 +1063,8 @@ g:netrw_keepdir to 0 (say, in your <.vimrc>) will tell netrw to have the
currently browsed directory be the current directory.
With the default setting for g:netrw_keepdir, in order to make the two
directories the same, use the "c" map (just type c). That map will set the
current directory to the current browsing directory.
directories the same, use the "c" map (just type c). That map will set
the current directory to the current browsing directory.
BOOKMARKING A DIRECTORY *netrw-b* *netrw-bookmark* *netrw-bookmarks*
@ -1131,8 +1087,8 @@ To change directory back to a bookmarked directory, use
{cnt}B
Any count may be used to reference any of the bookmarks. See |netrw-b| on
how to bookmark a directory and |netrw-q| on how to list bookmarks.
Any count may be used to reference any of the bookmarks. See |netrw-b|
for how to bookmark a directory and |netrw-q| for how to list them.
When wide listing is in use (see |netrw-i|), then the B map is not available;
instead, use {cnt}NB.
@ -1162,9 +1118,9 @@ NETRW SETTINGS *netrw-settings*
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.
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.
==============================================================================
@ -1284,33 +1240,6 @@ which is loaded automatically at startup (assuming :set nocp).
==============================================================================
10. History *netrw-history*
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
@ -1426,7 +1355,7 @@ which is loaded automatically at startup (assuming :set nocp).
* 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.
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

View file

@ -1062,6 +1062,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
+gettext various.txt /*+gettext*
+hangul_input various.txt /*+hangul_input*
+iconv various.txt /*+iconv*
+iconv/dyn various.txt /*+iconv\/dyn*
+insert_expand various.txt /*+insert_expand*
+jumplist various.txt /*+jumplist*
+keymap various.txt /*+keymap*
@ -1090,13 +1091,16 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
+osfiletype various.txt /*+osfiletype*
+path_extra various.txt /*+path_extra*
+perl various.txt /*+perl*
+perl/dyn various.txt /*+perl\/dyn*
+postscript various.txt /*+postscript*
+printer various.txt /*+printer*
+profile various.txt /*+profile*
+python various.txt /*+python*
+python/dyn various.txt /*+python\/dyn*
+quickfix various.txt /*+quickfix*
+rightleft various.txt /*+rightleft*
+ruby various.txt /*+ruby*
+ruby/dyn various.txt /*+ruby\/dyn*
+scrollbind various.txt /*+scrollbind*
+signs various.txt /*+signs*
+smartindent various.txt /*+smartindent*
@ -1109,6 +1113,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
+tag_binary various.txt /*+tag_binary*
+tag_old_static various.txt /*+tag_old_static*
+tcl various.txt /*+tcl*
+tcl/dyn various.txt /*+tcl\/dyn*
+terminfo various.txt /*+terminfo*
+termresponse various.txt /*+termresponse*
+textobjects various.txt /*+textobjects*
@ -1663,6 +1668,8 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
:TOhtml syntax.txt /*:TOhtml*
:Vexplore pi_netrw.txt /*:Vexplore*
:X editing.txt /*:X*
:XMLent insert.txt /*:XMLent*
:XMLns insert.txt /*:XMLns*
:\bar cmdline.txt /*:\\bar*
:_! cmdline.txt /*:_!*
:_# cmdline.txt /*:_#*
@ -1839,6 +1846,7 @@ $VIMRUNTIME starting.txt /*$VIMRUNTIME*
:command map.txt /*:command*
:command-completion map.txt /*:command-completion*
:command-completion-custom map.txt /*:command-completion-custom*
:command-completion-customlist map.txt /*:command-completion-customlist*
:command-verbose map.txt /*:command-verbose*
:comment eval.txt /*:comment*
:comp quickfix.txt /*:comp*
@ -5007,6 +5015,7 @@ ft-java-syntax syntax.txt /*ft-java-syntax*
ft-ksh-syntax syntax.txt /*ft-ksh-syntax*
ft-lace-syntax syntax.txt /*ft-lace-syntax*
ft-lex-syntax syntax.txt /*ft-lex-syntax*
ft-lisp-syntax syntax.txt /*ft-lisp-syntax*
ft-lite-syntax syntax.txt /*ft-lite-syntax*
ft-lpc-syntax syntax.txt /*ft-lpc-syntax*
ft-lua-syntax syntax.txt /*ft-lua-syntax*
@ -5059,6 +5068,8 @@ ft-verilog-indent indent.txt /*ft-verilog-indent*
ft-vim-indent indent.txt /*ft-vim-indent*
ft-vim-syntax syntax.txt /*ft-vim-syntax*
ft-xf86conf-syntax syntax.txt /*ft-xf86conf-syntax*
ft-xhtml-omni insert.txt /*ft-xhtml-omni*
ft-xml-omni insert.txt /*ft-xml-omni*
ft-xml-syntax syntax.txt /*ft-xml-syntax*
ft-xpm-syntax syntax.txt /*ft-xpm-syntax*
ftdetect filetype.txt /*ftdetect*
@ -5302,6 +5313,7 @@ hebrew hebrew.txt /*hebrew*
hebrew.txt hebrew.txt /*hebrew.txt*
help various.txt /*help*
help-context help.txt /*help-context*
help-tags tags 1
help-translated various.txt /*help-translated*
help-xterm-window various.txt /*help-xterm-window*
help.txt help.txt /*help.txt*
@ -5513,6 +5525,7 @@ icon-changed version4.txt /*icon-changed*
iconise starting.txt /*iconise*
iconize starting.txt /*iconize*
iconv() eval.txt /*iconv()*
iconv-dynamic mbyte.txt /*iconv-dynamic*
ident-search tips.txt /*ident-search*
if_cscop.txt if_cscop.txt /*if_cscop.txt*
if_mzsch.txt if_mzsch.txt /*if_mzsch.txt*
@ -5658,6 +5671,7 @@ linefeed intro.txt /*linefeed*
linewise motion.txt /*linewise*
linewise-register change.txt /*linewise-register*
linewise-visual visual.txt /*linewise-visual*
lisp.vim syntax.txt /*lisp.vim*
lispindent() eval.txt /*lispindent()*
list-identity eval.txt /*list-identity*
list-index eval.txt /*list-index*
@ -6111,6 +6125,7 @@ perl-SetHeight if_perl.txt /*perl-SetHeight*
perl-SetOption if_perl.txt /*perl-SetOption*
perl-Windows if_perl.txt /*perl-Windows*
perl-compiling if_perl.txt /*perl-compiling*
perl-dynamic if_perl.txt /*perl-dynamic*
perl-editing if_perl.txt /*perl-editing*
perl-overview if_perl.txt /*perl-overview*
perl-patterns pattern.txt /*perl-patterns*
@ -6174,6 +6189,7 @@ python-buffers if_pyth.txt /*python-buffers*
python-command if_pyth.txt /*python-command*
python-commands if_pyth.txt /*python-commands*
python-current if_pyth.txt /*python-current*
python-dynamic if_pyth.txt /*python-dynamic*
python-error if_pyth.txt /*python-error*
python-eval if_pyth.txt /*python-eval*
python-examples if_pyth.txt /*python-examples*
@ -6310,6 +6326,7 @@ ruby if_ruby.txt /*ruby*
ruby-buffer if_ruby.txt /*ruby-buffer*
ruby-command if_ruby.txt /*ruby-command*
ruby-commands if_ruby.txt /*ruby-commands*
ruby-dynamic if_ruby.txt /*ruby-dynamic*
ruby-evaluate if_ruby.txt /*ruby-evaluate*
ruby-globals if_ruby.txt /*ruby-globals*
ruby-message if_ruby.txt /*ruby-message*
@ -6774,6 +6791,7 @@ tcl-buffer-windows if_tcl.txt /*tcl-buffer-windows*
tcl-bugs if_tcl.txt /*tcl-bugs*
tcl-command if_tcl.txt /*tcl-command*
tcl-commands if_tcl.txt /*tcl-commands*
tcl-dynamic if_tcl.txt /*tcl-dynamic*
tcl-ex-commands if_tcl.txt /*tcl-ex-commands*
tcl-examples if_tcl.txt /*tcl-examples*
tcl-expr if_tcl.txt /*tcl-expr*
@ -7266,6 +7284,7 @@ xim mbyte.txt /*xim*
xim-input-style mbyte.txt /*xim-input-style*
xiterm syntax.txt /*xiterm*
xml-folding syntax.txt /*xml-folding*
xml-omni-datafile insert.txt /*xml-omni-datafile*
xml.vim syntax.txt /*xml.vim*
xpm.vim syntax.txt /*xpm.vim*
xterm-8-bit term.txt /*xterm-8-bit*
@ -7337,13 +7356,6 @@ zf fold.txt /*zf*
zg spell.txt /*zg*
zh scroll.txt /*zh*
zi fold.txt /*zi*
zip zip.txt /*zip*
zip-contents zip.txt /*zip-contents*
zip-copyright zip.txt /*zip-copyright*
zip-history zip.txt /*zip-history*
zip-manual zip.txt /*zip-manual*
zip-usage zip.txt /*zip-usage*
zip.txt zip.txt /*zip.txt*
zj fold.txt /*zj*
zk fold.txt /*zk*
zl scroll.txt /*zl*

View file

@ -1,4 +1,4 @@
*tagsrch.txt* For Vim version 7.0aa. Last change: 2005 Jul 12
*tagsrch.txt* For Vim version 7.0aa. Last change: 2005 Oct 15
VIM REFERENCE MANUAL by Bram Moolenaar
@ -440,7 +440,7 @@ directory. If it is not found there, then the file "/home/user/commontags"
will be searched for the tag.
This can be switched off by including the 'd' flag in 'cpoptions', to make
it Vi compatible. "./tags" will than be the tags file in the current
it Vi compatible. "./tags" will then be the tags file in the current
directory, instead of the tags file in the directory where the current file
is.

37
runtime/doc/tar.txt Normal file
View file

@ -0,0 +1,37 @@
*tar.txt* Tar File Interface Nov 03, 2005
Author: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamily.AbizM>
(remove NOSPAM from Campbell's email first)
Copyright: The GPL (gnu public license) applies to *tar-copyright*
tarPlugin.vim, and tar.txt.
No warranty, express or implied. Use At-Your-Own-Risk.
==============================================================================
1. Contents *tar* *tar-contents*
1. Contents..................................................|tar-contents|
2. Usage.....................................................|tar-usage|
3. History...................................................|tar-history|
==============================================================================
2. Usage *tar-usage* *tar-manual*
When one edits a *.tar file, this plugin will handle displaying a
contents page. Select a file to edit by moving the cursor atop
the desired file, then hit the <return> key. After editing, one may
also write to the file. Currently, one may not make a new file in
tar archives via the plugin.
==============================================================================
3. History *tar-history*
v3 Sep 16, 2005 * handles writing files in an archive back to the
archive
Oct 18, 2005 * <amatch> used instead of <afile> in autocmds
Oct 18, 2005 * handles writing to compressed archives
Nov 03, 2005 * handles writing tarfiles across a network using
netrw#NetWrite()
v2 * converted to use Vim7's new autoload feature by
Bram Moolenaar
v1 (original release) * Michael Toren (see http://michael.toren.net/code/)
==============================================================================
vim:tw=78:ts=8:ft=help

View file

@ -1,4 +1,4 @@
*todo.txt* For Vim version 7.0aa. Last change: 2005 Oct 12
*todo.txt* For Vim version 7.0aa. Last change: 2005 Nov 23
VIM REFERENCE MANUAL by Bram Moolenaar
@ -30,18 +30,66 @@ be worked on, but only if you sponsor Vim development. See |sponsor|.
*known-bugs*
-------------------- Known bugs and current work -----------------------
Using chown() is unsafe. (Jinpeng Wei)
ex_cmds.c: viminfo tempfile: use mch_open(O_EXCL) and fdopen()
fileio.c: use fchown() instead of chown()
vim.h: define O_NOFOLLOW if needed. Not in Vim 6.4?
Go over all changes between 6.3 and 6.4 and make sure they are included in 7.
'statusline' is drawn over the Omni menu.
Cygwin and Mac OS/X may preserve case for file names but ignore case
differences. Use Amiga code?
"make unixall": remove split in floppy-size archives.
To support mapping <F4> to be used as <F4>{motion}: Add operator that
executes a user defined function. '[ and '] marks are at start and end of
text. ":map <F4> :set opfunc=MyOp<CR>gy".
Patch from Yasuhiro Matsumoto: ":e ++enc=xxx" keeps encoding for conversion
errors and illegal bytes. How about replacing bytes with '?' or not?
ccomplete:
- When an option is set: In completion mode and the user types (identifier)
characters, advance to the first match instead of removing the popup menu.
If there is no match remove the selection. (Yegappan Lakshmanan)
- Complete the longest common match instead of the first match?
- !_TAG_FILE_FORMAT and it's ilk are listed in the global completions
- When completing something that is a structure, add the "." or "->".
- When a typedef or struct is local to a file only use it in that file?
- Window resize when poup is displayed
- page-up / page-down
spelling:
- When a recognized word ends in a . don't have 'spellcapcheck" match it.
- Use KEEPCASE instead of "KEP". applies to affixes too.
- Use KEEPCASE instead of "KEP". It applies to the word including affixes
Hunspell also uses it.
- Hunspell has NOSUGGEST flag (use for obscene words?)
- Check out Hunspell 1.1.2.
- Look into hungarian dictionary:
http://magyarispell.sourceforge.net/rc3-beta2.zip
- Support breakpoint character · 0xb7 and ignore it?
- Dutch word list should be available here: http://www.woordenlijst.org/
8 Alternate Dutch word list at www.nederlandsewoorden.nl (use script to
obtain). But new Myspell wordlist will come (Hagen)
- Finding suggestions with sound folding is slow. Somehow store the
sound-folded words and link to the words it comes from?
When editing a file "a" that is a symbolic link to "b", while another Vim is
editing "b", there is no warning. Follow symlink to make swap file name?
Patch from Stefano Zacchiroli.
In diff mode deleting lines is very slow. E.g., when diffing two .po files
and then sourcing po/cleaup.vim.
7 Add plugins for formatting. Should be able to make a choice depending on
the language of a file (English/Korean/Japanese/etc.).
Setting the 'langformat' option to "chinese" would load the
"format/chinese.vim" plugin.
Edward L. Fox explains how it should be done for most Asian languages. (2005
Nov 24)
Mac unicode patch (Da Woon Jung):
- selecting proportional font breaks display
@ -52,10 +100,15 @@ Mac unicode patch (Da Woon Jung):
- With 'nopaste' pasting is wrong, with 'paste' Command-V doesn't work.
(Alan Schmitt)
Patch to add a few flags to search(). (Benji Fisher, Nov 22)
Win32: Use the free downloadable compiler 7.1. Figure out how to do debugging
(with Agide?) and describe it. (George Reilly)
Try out using the free MS compiler and debugger, using Make_mvc.mak.
Win32: Check that installer puts menu items in "all users" dir when possible,
not administrator dir.
Autoload:
- Add a Vim script in $VIMRUNTIME/tools that takes a file with a list of
script names and a help file and produces a script that can be sourced to
@ -67,7 +120,8 @@ Autoload:
helpfile doc/myscript.txt
For the "helpfile" item ":helptags" is run.
Add ":smap", Select mode mapping?
Add ":smap", Select mode mapping? Otherwise: ":sunmap", so that Visual mode
mappings for normal keys can be removed from Select mode.
Awaiting response:
- Win32: tearoff menu window should have a scrollbar when it's taller than
@ -88,6 +142,10 @@ PLANNED FOR VERSION 7.0:
make it work for all completion methods.
UI:
- Complete longest common string first, like 'wildmode' "longest:full".
- Add an "auto" mode: after typing a character (or string) completion is
done for the longest common string. plugin defines the possible
characters/strings. (Martin Stubenschrott)
- GUI implementation of the popup menu.
- When using tags, show match in preview window (function prototype,
struct member, etc.).
@ -191,9 +249,9 @@ PLANNED FOR VERSION 7.0:
For GTK Neil Bird has a patch to use Vim like a widget.
- Add COLUMN NUMBERS to ":" commands ":line1,line2[col1,col2]cmd". Block
can be selected with CTRL-V. Allow '$' (end of line) for col2.
- Add DEBUGGER INTERFACE. Implementation for gdb by Xavier de Gaye,
assisted by Mikolaj Machowski. Should work like an IDE. Try to keep it
generic. Also found here: http://skawina.eu.org/mikolaj/vimgdb
- Add DEBUGGER INTERFACE. Implementation for gdb by Xavier de Gaye.
Should work like an IDE. Try to keep it generic. Now found here:
http://clewn.sf.net.
And the idevim plugin/script.
To be able to start the debugger from inside Vim: For GUI run a program
with a netbeans connection; for console: start a program that splits the
@ -207,6 +265,7 @@ PLANNED FOR VERSION 7.0:
implement part in Java and then connect to Vim. Some hints from Alexandru
Roman, 2004 Dec 15. Should then also work with Oracle Jdeveloper, see JSR
198 standard http://www.jcp.org/en/jsr/detail?id=198.
Eclim does it: http://eclim.sourceforge.net/ (Eric Van Dewoestine)
- STICKY CURSOR: Add a way of scrolling that leaves the cursor where it is.
Especially when using the scrollbar. Typing a cursor-movement command
scrolls back to where the cursor is.
@ -353,7 +412,9 @@ Awaiting updated patches:
How does this work? Missing comments.
gettext() Translate a message. (Patch from Yasuhiro Matsumoto)
Update 2004 Sep 10
More docs. Search in 'runtimepath'?
Another patch from Edward L. Fox (2005 Nov 24)
Search in 'runtimepath'?
More docs about how to use this.
How to get the messages into the .po files?
--- did not respond (yet) --
- Patch for 'breakindent' option: repeat indent for wrapped line. (Vaclav
@ -395,7 +456,7 @@ Awaiting updated patches:
7 When 'rightleft' is set, the search pattern should be displayed right
to left as well? See patch of Dec 26. (Nadim Shaikli)
8 Lock all used memory so that it doesn't get swapped to disk (uncrypted).
Patch by Jason Holt, 2003 May 23.
Patch by Jason Holt, 2003 May 23. Uses mlock.
7 Support a stronger encryption. Jason Holt implemented AES (May 6 2003).
7 Add ! register, for shell commands. (patch from Grenie)
8 In the gzip plugin, also recognize *.gz.orig, *.gz.bak, etc. Like it's
@ -791,7 +852,16 @@ MSDOS, OS/2 and Win32:
8 OS/2: Add Extended Attributes support and define HAVE_ACL.
8 OS/2: When editing a file name "foo.txt" that is actually called FOO.txt,
writing uses "foo.txt". Should obtain the real file name.
8 Should $USERPROFILE be preferred above $HOMEDRIVE/$HOMEPATH?
8 Should $USERPROFILE be preferred above $HOMEDRIVE/$HOMEPATH? No, but it's
a good fallback, thus use:
$HOME
$HOMEDRIVE$HOMEPATH
SHGetSpecialFolderPath(NULL, lpzsPath, CSIDL_APPDATA, FALSE);
$USERPROFILE
SHGetSpecialFolderPath(NULL, lpzsPath, CSIDL_COMMON_APPDATA, FALSE);
$ALLUSERSPROFILE
$SYSTEMDRIVE\
C:\
8 Win32 console: <M-Up> and <M-Down> don't work. (Geddes) We don't have
special keys for these. Should use modifier + key.
8 Win32 console: caps-lock makes non-alpha keys work like with shift.
@ -1382,22 +1452,19 @@ Spell checking:
8 Make "en-rare" spell file? Ask Charles Campbell.
8 The English dictionaries for different regions are not consistent in their
use of words with a dash.
8 Alternate Dutch word list at www.nederlandsewoorden.nl (use script to
obtain). But new Myspell wordlist will come (Hagen)
7 Insert mode completion mechanism that uses the spell word lists.
8 Add hl groups to 'spelllang'?
:set spelllang=en_us,en-rare/SpellRare,en-math/SpellMath
More complicated: Regions with different languages? E.g., comments
in English, strings in German (po file).
8 Implement compound words when it works for Myspell. Current idea has the
problem that "foo/X" always allows "foofoo", there is no way to specify a
word can only be at the start or end, or that only certain words combine.
Diff mode:
8 Use diff mode to show the changes made in a buffer (compared to the file).
Use an unnamed buffer, like doing:
new | set bt=nofile | r # | 0d_ | diffthis | wincmd p | diffthis
Also show difference with the file when editing started? Should show what
can be undone. (Tom Popovich)
7 Add cursor-binding: when moving the cursor in one diff'ed buffer, also
move it in other diff'ed buffers, so that CTRL-W commands go to the same
location.
@ -1575,6 +1642,11 @@ Syntax highlighting:
re-insert the [] if possible.
8 Make it possible to use color of text for Visual highlight group (like for
the Cursor).
8 It would be useful to make the highlight group name an expression. Then
when there is a match, the expression would be evaluated to find out what
highlight group to use. Could be used to check if the shell used in a
password file appears in /etc/shells. (Nikolai Weibull)
syn match =s:checkShell(v:match) contained 'pattern'
8 Make it possible to only highlight a sub-expression of a match. Like
using "\1" in a ":s" command.
8 Support for deleting syntax items:
@ -3020,8 +3092,6 @@ Options:
7 There is 'titleold', why is there no 'iconold'? (Chazelas)
7 Make 'scrolloff' a global-local option, so that it can be different in the
quickfix window, for example. (Gary Holloway)
7 Add plugins for formatting. Should be able to make a choice depending on
the language of a file (English/Korean/Japanese/etc.).
External commands:
@ -3349,7 +3419,8 @@ Various improvements:
7 Add a way to define an item list with a pattern in 'formatoptions'. The
'n' flag doesn't work for "6.3" or "6a.".
8 Add 'formatexpr' option: Used for formatting operator "gq" instead of the
builtin formatting or 'formatprg'.
builtin formatting or 'formatprg'. Or use a string that starts with "="
in 'formatprg': "=MyFormat()".
8 Allow using a trailing space to signal a paragraph that continues on the
next line (MIME text/plain; format=flowed, RFC 2646). Can be used for
continuous formatting. Could use 'autoformat' option, which specifies a

View file

@ -1,4 +1,4 @@
*uganda.txt* For Vim version 7.0aa. Last change: 2005 Aug 12
*uganda.txt* For Vim version 7.0aa. Last change: 2005 Oct 15
VIM REFERENCE MANUAL by Bram Moolenaar
@ -211,9 +211,26 @@ Sending money:
Check the ICCF web site for the latest information! See |iccf| for the URL.
USA and Canada: Contact Kibaale Children's Fund (KCF) in Surrey, Canada. They
USA: The methods mentioned below can be used. Alternatively, you
can send a check to the Nehemiah Group Outreach Society
(NGOS). This will reduce banking costs and you can get an IRS
tax receipt. The NGOS forwards the funds directly to the
Kibaale project in Uganda. Checks must be made payable to
NGOS but please note on the check "donation Kibaale". Mail
checks to:
NGOS
P.O. Box 50862
Indianapolis, IN 45250
Questions regarding the Nehemiah Group Outreach Society (NGOS)
should be directed to: Ross deMerchant, Executive Director -
r.demerchant AT sbcglobal DOT net.
For sponsoring a child contact KCF in Canada (see below) and
send the check to NGOS in Indianapolis.
Canada: Contact Kibaale Children's Fund (KCF) in Surrey, Canada. They
take care of the Canadian sponsors for the children in
Kibaale. You can send them a one time donation directly.
Kibaale. KCF forwards 100% of the money to the project in
Uganda. You can send them a one time donation directly.
Please send me a note so that I know what has been donated
because of Vim. Ask KCF for information about sponsorship.
Kibaale Children's Fund c/o Pacific Academy
@ -223,12 +240,10 @@ USA and Canada: Contact Kibaale Children's Fund (KCF) in Surrey, Canada. They
Phone: 604-581-5353
If you make a donation to Kibaale Children's Fund (KCF) you
will receive a tax receipt which can be submitted with your
tax return (under the Free Trade Agreement tax receipts issued
by an organization registered in Canada are fully accepted by
the IRS in the USA, with a few conditions).
tax return.
Holland: Transfer to the account of "Stichting ICCF Holland" in Venlo.
This will allow for tax deduction (if you live in Holland)!
This will allow for tax deduction if you live in Holland.
Postbank, nr. 4548774
Germany: It is possible to make donations that allow for a tax return.
@ -252,7 +267,7 @@ Credit Card: You can use PayPal to send money with a Credit card. This is
https://www.paypal.com/affil/pal=Bram%40iccf-holland.org
The e-mail address for sending the money to is:
Bram@iccf-holland.org
For amounts above 400 Euro ($500) sending a cheque is
For amounts above 400 Euro ($500) sending a check is
preferred.
Others: Transfer to one of these accounts if possible:
@ -264,11 +279,11 @@ Others: Transfer to one of these accounts if possible:
Rabobank Venlo, account 3765.05.117
Swift code: RABO NL 2U
under the name "Bram Moolenaar", Venlo
Otherwise, send a cheque in euro or US dollars to the address
Otherwise, send a check in euro or US dollars to the address
below. Minimal amount: $70 (my bank does not accept smaller
amounts for foreign cheques, sorry)
amounts for foreign check, sorry)
Address to send cheques to:
Address to send checks to:
stichting ICCF Holland
Bram Moolenaar
Clematisstraat 30

View file

@ -1,4 +1,4 @@
*various.txt* For Vim version 7.0aa. Last change: 2005 Aug 27
*various.txt* For Vim version 7.0aa. Last change: 2005 Oct 14
VIM REFERENCE MANUAL by Bram Moolenaar
@ -295,7 +295,8 @@ N *+gettext* message translations |multi-lang|
*+GUI_Motif* Unix only: Motif |GUI|
*+GUI_Photon* QNX only: Photon |GUI|
m *+hangul_input* Hangul input support |hangul|
*+iconv* Compiled with the |iconv()| function, may have |/dyn|
*+iconv* Compiled with the |iconv()| function
*+iconv/dyn* Likewise |iconv-dynamic| |/dyn|
N *+insert_expand* |insert_expand| Insert mode completion
N *+jumplist* |jumplist|
B *+keymap* |'keymap'|
@ -325,14 +326,17 @@ m *+ole* Win32 GUI only: |ole-interface|
*+osfiletype* Support for the 'osfiletype' option and filetype
checking in automatic commands. |autocmd-osfiletypes|
N *+path_extra* Up/downwards search in 'path' and 'tags'
m *+perl* Perl interface |perl|, may have |/dyn|
m *+perl* Perl interface |perl|
m *+perl/dyn* Perl interface |perl-dynamic| |/dyn|
*+postscript* |:hardcopy| writes a PostScript file
N *+printer* |:hardcopy| command
H *+profile* |:profile| command
m *+python* Python interface |python|, may have |/dyn|
m *+python* Python interface |python|
m *+python/dyn* Python interface |python-dynamic| |/dyn|
N *+quickfix* |:make| and |quickfix| commands
B *+rightleft* Right to left typing |'rightleft'|
m *+ruby* Ruby interface |ruby|, may have |/dyn|
m *+ruby* Ruby interface |ruby|
m *+ruby/dyn* Ruby interface |ruby-dynamic| |/dyn|
N *+scrollbind* |'scrollbind'|
B *+signs* |:sign|
N *+smartindent* |'smartindent'|
@ -345,7 +349,8 @@ N *+syntax* Syntax highlighting |syntax|
N *+tag_binary* binary searching in tags file |tag-binary-search|
N *+tag_old_static* old method for static tags |tag-old-static|
m *+tag_any_white* any white space allowed in tags file |tag-any-white|
m *+tcl* Tcl interface |tcl|, may have |/dyn|
m *+tcl* Tcl interface |tcl|
m *+tcl/dyn* Tcl interface |tcl-dynamic| |/dyn|
*+terminfo* uses |terminfo| instead of termcap
N *+termresponse* support for |t_RV| and |v:termresponse|
N *+textobjects* |text-objects| selection

View file

@ -1,4 +1,4 @@
*version6.txt* For Vim version 7.0aa. Last change: 2005 Oct 09
*version6.txt* For Vim version 7.0aa. Last change: 2005 Oct 17
VIM REFERENCE MANUAL by Bram Moolenaar
@ -13863,16 +13863,36 @@ The big MS-Windows version now uses:
Changed *changed-6.4*
-------
Nothing relevant.
Removed runtime/tools/tcltags, Exuberant ctags does it better.
Added *added-6.4*
-----
Netrc syntax file. (Nikolai Weibull)
Sudoers syntax file. (Nikolai Weibull)
SMTPrc syntax file. (Kornel Kielczewski)
Esterel syntax file. (Maurizio Tranchero)
Alsaconf syntax file (Nikolai Weibull)
Eruby syntax, indent, compiler and ftplugin file (Doug Kearns)
Esterel syntax file (Maurizio Tranchero)
Mathematica indent file (Steve Layland)
Netrc syntax file (Nikolai Weibull)
PHP compiler file (Doug Kearns)
Pascal indent file (Neil Carter)
Prescribe syntax file (Klaus Muth)
Rubyunit compiler file (Doug Kearns)
SMTPrc syntax file (Kornel Kielczewski)
Sudoers syntax file (Nikolai Weibull)
TPP syntax file (Gerfried Fuchs)
VHDL ftplugin file (R. Shankar)
Verilog-AMS syntax file (S. Myles Prather)
Bulgarian keymap (Alberto Mardegan)
Canadian keymap (Eric Joanis)
Hungarian menu translations in UTF-8 (Kantra Gergely)
Ukrainian menu translations (Bohdan Vlasyuk)
Irish message translations (Kevin Patrick Scannell)
Configure also checks for tclsh8.4.
Fixed *fixed-6.4*
@ -13888,6 +13908,10 @@ GUI has started up.
Gcc would warn "dereferencing type-punned pointer will break strict -aliasing
rules". Avoid using typecasts for variable pointers.
Gcc 3.x interprets the -MM argument differently. Change "-I /path" to
"-isystem /path" for "make depend".
Patch 6.3.001
Problem: ":browse split" gives the file selection dialog twice. (Gordon
Bazeley) Same problem for ":browse diffpatch".
@ -14056,7 +14080,7 @@ Files: src/os_mswin.c
Patch 6.3.026
Problem: When ~/.vim/after/syntax/syncolor.vim contains a command that
reloads the colors an enless loop and/or a crash may occur.
reloads the colors an endless loop and/or a crash may occur.
Solution: Only free the old value of an option when it was originally
allocated. Limit recursiveness of init_highlight() to 5 levels.
Files: src/option.c, src/syntax.c
@ -14471,5 +14495,36 @@ Problem: A very big value for 'columns' or 'lines' may cause a crash.
Solution: Limit the values to 10000 and 1000.
Files: src/option.c
Patch 6.4a.001
Problem: The Unix Makefile contained too many dependencies and a few
uncommented lines.
Solution: Run "make depend" with manual changes to avoid a gcc
incompatibility. Comment a few lines.
Files: src/Makefile
Patch 6.4b.001
Problem: Vim reports "Vim 6.4a" in the ":version" output.
Solution: Change "a" to "b". (Tony Mechelynck)
Files: src/version.h
Patch 6.4b.002
Problem: In Insert mode, pasting a multi-byte character after the end of
the line leaves the cursor just before that character.
Solution: Make sure "gP" leaves the cursor in the right place when
'virtualedit' is set.
Files: src/ops.c
Patch 6.4b.003 (after 6.4b.002)
Problem: The problem still exists when 'encoding' is set to "cp936".
Solution: Fix the problem in getvvcol(), compute the coladd field correctly.
Files: src/charset.c, src/ops.c
Patch 6.4b.004
Problem: Selecting a {} block with "viB" includes the '}' when there is an
empty line before it.
Solution: Don't advance the cursor to include a line break when it's already
at the line break.
Files: src/search.c
vim:tw=78:ts=8:ft=help:norl:

View file

@ -1,4 +1,4 @@
*version7.txt* For Vim version 7.0aa. Last change: 2005 Oct 11
*version7.txt* For Vim version 7.0aa. Last change: 2005 Nov 23
VIM REFERENCE MANUAL by Bram Moolenaar
@ -429,7 +429,7 @@ Win32: The ":winpos" command now also works in the console. (Vipin Aravind)
Lakshmanan).
New functions: ~
New and extended functions: ~
|add()| append an item to a List
|append()| append List of lines to the buffer
@ -570,7 +570,7 @@ character selections can be used between two Vims. (Eckehard Berns)
Also fixes the problem that setting 'clipboard' to "unnamed" breaks using
"yyp".
Mac: GUI font selector. (Peter "Rain Dog" Cucka)
Mac: GUI font selector. (Peter Cucka)
Mac: support for multi-byte characters. (Da Woon Jung)
@ -619,6 +619,9 @@ IMPROVEMENTS *improvements-7*
Move the help for printing to a separate help file. It's quite a lot now.
When ":silent" is used and a backwards range is given for an Ex command the
range is swapped automatically instead of asking if that is OK.
The pattern matching code was changed from a recursive function to an
iterative mechanism. This avoids out-of-stack errors. State is stored in
allocated memory, running out of memory can always be detected. Allows
@ -636,7 +639,7 @@ it. (Johannes Zellner)
Added "nbsp" in 'listchars'. (David Blanchet)
Added the "acwrite" value for the 'buftype' option. This is for a buffer that
doesn not have a name that refers to a file and is written with BufWriteCmd
does not have a name that refers to a file and is written with BufWriteCmd
autocommands.
For lisp indenting and matching parenthesis: (Sergey Khorev)
@ -816,7 +819,7 @@ For command-line completion the matches for various types of arguments are now
sorted: user commands, variables, syntax names, etc.
When no locale is set, thus using the "C" locale, Vim will work with latin1
characters, using it's own isupper()/toupper()/etc. functions.
characters, using its own isupper()/toupper()/etc. functions.
When using an rxvt terminal emulator guess the value of 'background' using the
COLORFGBG environment variable. (Ciaran McCreesh)
@ -1395,4 +1398,13 @@ Limit the values of 'columns' and 'lines' to avoid an overflow in Rows *
Columns. Fixed bad effects when running out of memory (command line would be
reversed, ":qa!" resulted in ":!aq").
Motif: "gvim -iconic" opened the window anyway. (David Harrison)
There is a tiny chance that a symlink gets created between checking for an
existing file and creating a file. Use the O_NOFOLLOW for open() if it's
available.
In an empty line "ix<CTRL-O>0" moved the cursor to after the line instead of
sticking to the first column.
vim:tw=78:ts=8:ft=help:norl:

View file

@ -1,4 +1,4 @@
*zip.txt* Zip File Interface Sep 16, 2005
*zip.txt* Zip File Interface Nov 03, 2005
Author: Charles E. Campbell, Jr. <NdrOchip@ScampbellPfamily.AbizM>
(remove NOSPAM from Campbell's email first)
@ -20,12 +20,21 @@ Copyright: Copyright (C) 2005 Charles E. Campbell, Jr. {{{1 *zip-copyright*
==============================================================================
2. Usage *zip-usage* *zip-manual*
When one edits a *.zip file, this plugin will handle displaying a
contents page. Select a file to edit by moving the cursor atop
the desired file, then hit the <return> key. After editing, one may
also write to the file. Currently, one may not make a new file in
zip archives via the plugin.
==============================================================================
3. History *zip-history*
v3 Oct 18, 2005 * <amatch> used instead of <afile> in autocmds
v2 Sep 16, 2005 * silenced some commands (avoiding hit-enter prompt)
* began testing under Windows; works thus far
* filetype detection fixed
v1 Sep 15, 2005 * Initial release, had browsin, reading, and writing
Nov 03, 2005 * handles writing zipfiles across a network using
netrw#NetWrite()
v1 Sep 15, 2005 * Initial release, had browsing, reading, and writing
==============================================================================
vim:tw=78:ts=8:ft=help

View file

@ -1,7 +1,7 @@
" Vim support file to detect file types
"
" Maintainer: Bram Moolenaar <Bram@vim.org>
" Last Change: 2005 Oct 12
" Last Change: 2005 Nov 23
" Listen very carefully, I will say this only once
if exists("did_load_filetypes")
@ -1349,6 +1349,9 @@ au BufNewFile,BufRead *.rtf setf rtf
" Ruby
au BufNewFile,BufRead *.rb,*.rbw,*.gem,*.gemspec setf ruby
" Rantfile is like Ruby
au BufNewFile,BufRead [rR]antfile,*.rant setf ruby
" S-lang (or shader language!)
au BufNewFile,BufRead *.sl setf slang
@ -1612,9 +1615,19 @@ au BufNewFile,BufRead /etc/sysctl.conf setf sysctl
" Sudoers
au BufNewFile,BufRead /etc/sudoers,sudoers.tmp setf sudoers
" Tads (or Nroff)
" If the first line starts with '#' and contains 'perl' it's probably a Perl
" file.
fun! s:FTperl()
if getline(1)[0] == '#' && getline(1) =~ 'perl'
setf perl
return 1
endif
return 0
endfun
" Tads (or Nroff or Perl test file)
au BufNewFile,BufRead *.t
\ if !s:FTnroff() | setf tads | endif
\ if !s:FTnroff() && !s:FTperl() | setf tads | endif
" Tags
au BufNewFile,BufRead tags setf tags
@ -1622,8 +1635,8 @@ au BufNewFile,BufRead tags setf tags
" TAK
au BufNewFile,BufRead *.tak setf tak
" Tcl
au BufNewFile,BufRead *.tcl,*.tk,*.itcl,*.itk setf tcl
" Tcl (JACL too)
au BufNewFile,BufRead *.tcl,*.tk,*.itcl,*.itk,*.jacl setf tcl
" TealInfo
au BufNewFile,BufRead *.tli setf tli

View file

@ -2,14 +2,8 @@
" Language: eRuby
" Maintainer: Doug Kearns <djkea2 at gus.gscit.monash.edu.au>
" Info: $Id$
" URL: http://vim-ruby.sourceforge.net
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" ----------------------------------------------------------------------------
" Only do this when not done yet for this buffer

View file

@ -1,38 +1,36 @@
" Vim settings file
" Language: OCaml
" Maintainers: Mike Leary <leary@nwlink.com>
" Markus Mottl <markus@oefai.at>
" Stefano Zacchiroli <zack@bononia.it>
" URL: http://www.oefai.at/~markus/vim/ftplugin/ocaml.vim
" Last Change: 2004 Apr 12 - better .ml/.mli-switching without Python (SZ)
" 2003 Nov 21 - match_words-patterns and .ml/.mli-switching (MM)
" 2003 Oct 16 - re-entered variable 'did_ocaml_dtypes' (MM)
" 2003 Oct 15 - added Stefano Zacchirolis (SZ) Python-code for
" displaying type annotations (MM)
" Only do these settings when not done yet for this buffer
if exists("b:did_ftplugin")
finish
endif
" Don't do other file type settings for this buffer
let b:did_ftplugin = 1
" Language: OCaml
" Maintainer: David Baelde <firstname.name@ens-lyon.org>
" Mike Leary <leary@nwlink.com>
" Markus Mottl <markus.mottl@gmail.com>
" Stefano Zacchiroli <zack@bononia.it>
" URL: http://www.ocaml.info/vim/ftplugin/ocaml.vim
" Last Change: 2005 Oct 13 - removed GPL; better matchit support (MM, SZ)
"
" if exists("b:did_ftplugin")
" finish
" endif
let b:did_ftplugin=1
" Error handling -- helps moving where the compiler wants you to go
let s:cposet=&cpoptions
set cpo-=C
" Error formats
setlocal efm=
\%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d:,
\%EFile\ \"%f\"\\,\ line\ %l\\,\ character\ %c:%m,
\%+EReference\ to\ unbound\ regexp\ name\ %m,
\%Eocamlyacc:\ e\ -\ line\ %l\ of\ \"%f\"\\,\ %m,
\%Wocamlyacc:\ w\ -\ %m,
\%-Zmake%.%#,
\%C%m
\%EFile\ \"%f\"\\,\ line\ %l\\,\ characters\ %c-%*\\d:,
\%EFile\ \"%f\"\\,\ line\ %l\\,\ character\ %c:%m,
\%+EReference\ to\ unbound\ regexp\ name\ %m,
\%Eocamlyacc:\ e\ -\ line\ %l\ of\ \"%f\"\\,\ %m,
\%Wocamlyacc:\ w\ -\ %m,
\%-Zmake%.%#,
\%C%m,
\%D%*\\a[%*\\d]:\ Entering\ directory\ `%f',
\%X%*\\a[%*\\d]:\ Leaving\ directory\ `%f',
\%D%*\\a:\ Entering\ directory\ `%f',
\%X%*\\a:\ Leaving\ directory\ `%f',
\%DMaking\ %*\\a\ in\ %f
" Add mappings, unless the user didn't want this.
if !exists("no_plugin_maps") && !exists("no_ocaml_maps")
" Uncommenting
" (un)commenting
if !hasmapto('<Plug>Comment')
nmap <buffer> <LocalLeader>c <Plug>LUncomOn
vmap <buffer> <LocalLeader>c <Plug>BUncomOn
@ -41,46 +39,141 @@ if !exists("no_plugin_maps") && !exists("no_ocaml_maps")
endif
nnoremap <buffer> <Plug>LUncomOn mz0i(* <ESC>$A *)<ESC>`z
nnoremap <buffer> <Plug>LUncomOff <ESC>:s/^(\* \(.*\) \*)/\1/<CR>
nnoremap <buffer> <Plug>LUncomOff :s/^(\* \(.*\) \*)/\1/<CR>:noh<CR>
vnoremap <buffer> <Plug>BUncomOn <ESC>:'<,'><CR>`<O<ESC>0i(*<ESC>`>o<ESC>0i*)<ESC>`<
vnoremap <buffer> <Plug>BUncomOff <ESC>:'<,'><CR>`<dd`>dd`<
if !hasmapto('<Plug>Abbrev')
iabbrev <buffer> ASS (assert false)
iabbrev <buffer> ASS (assert false (* XXX *))
endif
endif
" Let % jump between structure elements (due to Issac Trotts)
let b:mw='\<let\>:\<and\>:\(\<in\>\|;;\),'
let b:mw=b:mw . '\<if\>:\<then\>:\<else\>,\<do\>:\<done\>,'
let b:mw=b:mw . '\<\(object\|sig\|struct\|begin\)\>:\<end\>'
let b:match_words=b:mw
let b:mw = ''
let b:mw = b:mw . ',\<let\>:\<and\>:\(\<in\>\|;;\)'
let b:mw = b:mw . ',\<if\>:\<then\>:\<else\>'
let b:mw = b:mw . ',\<\(for\|while\)\>:\<do\>:\<done\>,'
let b:mw = b:mw . ',\<\(object\|sig\|struct\|begin\)\>:\<end\>'
let b:mw = b:mw . ',\<\(match\|try\)\>:\<with\>'
let b:match_words = b:mw
let b:match_ignorecase=0
" switching between interfaces (.mli) and implementations (.ml)
if !exists("g:did_ocaml_switch")
let g:did_ocaml_switch = 1
map ,s :call OCaml_switch(0)<CR>
map ,S :call OCaml_switch(1)<CR>
map <LocalLeader>s :call OCaml_switch(0)<CR>
map <LocalLeader>S :call OCaml_switch(1)<CR>
fun OCaml_switch(newwin)
if (match(bufname(""), "\\.mli$") >= 0)
let fname = substitute(bufname(""), "\\.mli$", ".ml", "")
if (a:newwin == 1)
exec "new " . fname
exec "new " . fname
else
exec "arge " . fname
exec "arge " . fname
endif
elseif (match(bufname(""), "\\.ml$") >= 0)
let fname = bufname("") . "i"
if (a:newwin == 1)
exec "new " . fname
exec "new " . fname
else
exec "arge " . fname
exec "arge " . fname
endif
endif
endfun
endif
" Vim support for OCaml 3.07 .annot files (requires Vim with python support)
" Folding support
" Get the modeline because folding depends on indentation
let s:s = line2byte(line('.'))+col('.')-1
if search('^\s*(\*:o\?caml:')
let s:modeline = getline(".")
else
let s:modeline = ""
endif
if s:s > 0
exe 'goto' s:s
endif
" Get the indentation params
let s:m = matchstr(s:modeline,'default\s*=\s*\d\+')
if s:m != ""
let s:idef = matchstr(s:m,'\d\+')
elseif exists("g:omlet_indent")
let s:idef = g:omlet_indent
else
let s:idef = 2
endif
let s:m = matchstr(s:modeline,'struct\s*=\s*\d\+')
if s:m != ""
let s:i = matchstr(s:m,'\d\+')
elseif exists("g:omlet_indent_struct")
let s:i = g:omlet_indent_struct
else
let s:i = s:idef
endif
" Set the folding method
if exists("g:ocaml_folding")
setlocal foldmethod=expr
setlocal foldexpr=OMLetFoldLevel(v:lnum)
endif
" - Only definitions below, executed once -------------------------------------
if exists("*OMLetFoldLevel")
finish
endif
function s:topindent(lnum)
let l = a:lnum
while l > 0
if getline(l) =~ '\s*\%(\<struct\>\|\<sig\>\|\<object\>\)'
return indent(l)
endif
let l = l-1
endwhile
return -s:i
endfunction
function OMLetFoldLevel(l)
" This is for not merging blank lines around folds to them
if getline(a:l) !~ '\S'
return -1
endif
" We start folds for modules, classes, and every toplevel definition
if getline(a:l) =~ '^\s*\%(\<val\>\|\<module\>\|\<class\>\|\<type\>\|\<method\>\|\<initializer\>\|\<inherit\>\|\<exception\>\|\<external\>\)'
exe 'return ">' (indent(a:l)/s:i)+1 '"'
endif
" Toplevel let are detected thanks to the indentation
if getline(a:l) =~ '^\s*let\>' && indent(a:l) == s:i+s:topindent(a:l)
exe 'return ">' (indent(a:l)/s:i)+1 '"'
endif
" We close fold on end which are associated to struct, sig or object.
" We use syntax information to do that.
if getline(a:l) =~ '^\s*end\>' && synIDattr(synID(a:l, indent(a:l)+1, 0), "name") != "ocamlKeyword"
return (indent(a:l)/s:i)+1
endif
" Folds end on ;;
if getline(a:l) =~ '^\s*;;'
exe 'return "<' (indent(a:l)/s:i)+1 '"'
endif
" Comments around folds aren't merged to them.
if synIDattr(synID(a:l, indent(a:l)+1, 0), "name") == "ocamlComment"
return -1
endif
return '='
endfunction
" Vim support for OCaml .annot files (requires Vim with python support)
"
" Executing OCamlPrintType(<mode>) function will display in the Vim bottom
" line(s) the type of an ocaml value getting it from the corresponding .annot
@ -92,37 +185,15 @@ endif
" .annot files are parsed lazily the first time OCamlPrintType is invoked; is
" also possible to force the parsing using the OCamlParseAnnot() function.
"
" Hitting the <F3> key will cause OCamlPrintType function to be invoked with
" Typing ',3' will cause OCamlPrintType function to be invoked with
" the right argument depending on the current mode (visual or not).
"
" Copyright (C) <2003> Stefano Zacchiroli <zack@bononia.it>
" Copyright (C) <2003-2004> Stefano Zacchiroli <zack@bononia.it>
"
" Created: Wed, 01 Oct 2003 18:16:22 +0200 zack
" LastModified: Mon, 06 Oct 2003 11:05:39 +0200 zack
"
" This program is free software; you can redistribute it and/or modify
" it under the terms of the GNU General Public License as published by
" the Free Software Foundation; either version 2 of the License, or
" (at your option) any later version.
"
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
"
" You should have received a copy of the GNU General Public License
" along with this program; if not, write to the Free Software
" Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
"
" LastModified: Wed, 25 Aug 2004 18:28:39 +0200 zack
if !has("python")
echo "Python support not found: OCaml .annot support disabled"
finish
endif
if !exists("g:did_ocaml_dtypes")
let g:did_ocaml_dtypes = 1
else
finish
endif
@ -166,7 +237,7 @@ class Annotations:
at least two space characters.
- in each block, the two positions are respectively the start and the
- end of the range described by the block.
end of the range described by the block.
- in a position, the filename is the name of the file, the first num
is the line number, the second num is the offset of the beginning
of the line, the third num is the offset of the position itself.
@ -182,7 +253,7 @@ class Annotations:
self.__timestamp = None # last parse action timestamp
self.__annot = {}
self.__re = re.compile(
'^"[^"]+"\s+(\d+)\s+(\d+)\s+(\d+)\s+"[^"]+"\s+(\d+)\s+(\d+)\s+(\d+)$')
'^"[^"]*"\s+(\d+)\s+(\d+)\s+(\d+)\s+"[^"]*"\s+(\d+)\s+(\d+)\s+(\d+)$')
def __parse(self, fname):
try:
@ -210,7 +281,9 @@ class Annotations:
lineno += 1
if (line == ""): raise malformed_annotations(lineno)
type = string.join(type, "\n")
self.__annot[(line1, col1), (line2, col2)] = type
key = ((line1, col1), (line2, col2))
if not self.__annot.has_key(key):
self.__annot[key] = type
line = f.readline() # position line
f.close()
self.__filename = fname
@ -285,7 +358,7 @@ def parseOCamlAnnot():
EOF
fun OCamlPrintType(current_mode)
fun! OCamlPrintType(current_mode)
if (a:current_mode == "visual")
python printOCamlType("visual")
else
@ -293,9 +366,15 @@ fun OCamlPrintType(current_mode)
endif
endfun
fun OCamlParseAnnot()
fun! OCamlParseAnnot()
python parseOCamlAnnot()
endfun
map <F3> :call OCamlPrintType("normal")<RETURN>
vmap <F3> :call OCamlPrintType("visual")<RETURN>
map <LocalLeader>t :call OCamlPrintType("normal")<RETURN>
vmap <LocalLeader>t :call OCamlPrintType("visual")<RETURN>
let &cpoptions=s:cposet
unlet s:cposet
" vim:sw=2

View file

@ -2,14 +2,8 @@
" Language: Ruby
" Maintainer: Gavin Sinclair <gsinclair at soyabean.com.au>
" Info: $Id$
" URL: http://vim-ruby.sourceforge.net
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" ----------------------------------------------------------------------------
"
" Original matchit support thanks to Ned Konz. See his ftplugin/ruby.vim at

View file

@ -32,6 +32,15 @@ if exists("loaded_matchit")
\ '<\@<=\%([^ \t>/]\+\)\%(\s\+[^/>]*\|$\):/>'
endif
"
" For Omni completion, by Mikolaj Machowski.
if exists('&ofu')
setlocal ofu=xmlcomplete#CompleteTags
endif
command! -nargs=+ XMLns call xmlcomplete#CreateConnection(<f-args>)
command! -nargs=? XMLent call xmlcomplete#CreateEntConnection(<f-args>)
" Change the :browse e filter to primarily show xml-related files.
if has("gui_win32")
let b:browsefilter="XML Files (*.xml)\t*.xml\n" .

22
runtime/indent/d.vim Normal file
View file

@ -0,0 +1,22 @@
" Vim indent file for the D programming language (version 0.137).
"
" Language: D
" Maintainer: Jason Mills<jmills@cs.mun.ca>
" Last Change: 2005 Nov 22
" Version: 0.1
"
" Please email me with bugs, comments, and suggestion. Put vim in the subject
" to ensure the email will not be marked has spam.
"
" Only load this indent file when no other was loaded.
if exists("b:did_indent")
finish
endif
let b:did_indent = 1
" D indenting is a lot like the built-in C indenting.
setlocal cindent
" vim: ts=8 noet

View file

@ -2,14 +2,8 @@
" Language: Ruby
" Maintainer: Doug Kearns <djkea2 at gus.gscit.monash.edu.au>
" Info: $Id$
" URL: http://vim-ruby.rubyforge.org/
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" ----------------------------------------------------------------------------
" Only load this indent file when no other was loaded.

View file

@ -2,17 +2,19 @@
" Language: PHP
" Author: John Wellesz <John.wellesz (AT) teaser (DOT) fr>
" URL: http://www.2072productions.com/vim/indent/php.vim
" Last Change: 2005 September 22th
" Version: 1.181
"
" The change log and all the comments have been removed from this file.
"
" For a complete change log and fully commented code, download the script on
" 2072productions.com at the URI provided above.
" Last Change: 2005 Nobember 21st
" Version: 1.20
"
" The change log and all the comments have been removed from this file.
"
" For a complete change log and fully commented code, download the script on
" 2072productions.com at the URI provided above.
"
" If you find a bug, please e-mail me at John.wellesz (AT) teaser (DOT) fr
" with an example of code that breaks the algorithm.
" with an example of code that break the algorithm.
"
"
" Thanks a lot for using this script.
"
"
" NOTE: This script must be used with PHP syntax ON and with the php syntax
@ -23,6 +25,7 @@
" tags not at col 1 you'll have to indent your file 2 times (This script
" will automatically put HereDoc end tags at col 1).
"
"
" NOTE: If you are editing file in Unix file format and that (by accident)
" there are '\r' before new lines, this script won't be able to proceed
" correctly and will make many mistakes because it won't be able to match
@ -34,31 +37,36 @@
" or simply 'let' the option PHP_removeCRwhenUnix to 1 and the script will
" silently remove them when VIM load this script (at each bufread).
" Options: PHP_autoformatcomment = 0 to not enable autoformating of comment by
" default, if set to 0, this script will let the 'formatoptions' setting intact.
"
" Options: PHP_default_indenting = # of sw (default is 0), # of sw will be
" added to the indent of each line of PHP code.
" added to the indent of each line of PHP code.
"
" Options: PHP_removeCRwhenUnix = 1 to make the script automatically remove CR
" at end of lines (by default this option is unset), NOTE that you
" MUST remove CR when the fileformat is UNIX else the indentation
" won't be correct...
" at end of lines (by default this option is unset), NOTE that you
" MUST remove CR when the fileformat is UNIX else the indentation
" won't be correct...
"
" Options: PHP_BracesAtCodeLevel = 1 to indent the '{' and '}' at the same
" level than the code they contain.
" Exemple:
" Instead of:
" if ($foo)
" {
" foo();
" }
"
" You will write:
" if ($foo)
" level than the code they contain.
" Exemple:
" Instead of:
" if ($foo)
" {
" foo();
" foo();
" }
"
" NOTE: The script will be a bit slower if you use this option because
" some optimizations won't be available.
" You will write:
" if ($foo)
" {
" foo();
" }
"
" NOTE: The script will be a bit slower if you use this option because
" some optimizations won't be available.
if exists("b:did_indent")
@ -82,6 +90,11 @@ else
let b:PHP_BracesAtCodeLevel = 0
endif
if exists("PHP_autoformatcomment")
let b:PHP_autoformatcomment = PHP_autoformatcomment
else
let b:PHP_autoformatcomment = 1
endif
let b:PHP_lastindented = 0
let b:PHP_indentbeforelast = 0
@ -114,12 +127,12 @@ if &fileformat == "unix" && exists("PHP_removeCRwhenUnix") && PHP_removeCRwhenUn
endif
if exists("*GetPhpIndent")
finish " XXX
finish " XXX
endif
let s:endline= '\s*\%(//.*\|#.*\|/\*.*\*/\s*\)\=$'
let s:PHP_startindenttag = '<?\%(.*?>\)\@!\|<script[^>]*>\%(.*<\/script>\)\@!'
"setlocal debug=msg " XXX
" setlocal debug=msg " XXX
function! GetLastRealCodeLNum(startline) " {{{
@ -141,7 +154,7 @@ function! GetLastRealCodeLNum(startline) " {{{
if lastline !~ '^\*/'
call search('\*/', 'W')
endif
let lnum = searchpair('/\*', '', '\*/', s:searchpairflags)
let lnum = searchpair('/\*', '', '\*/', s:searchpairflags, 'Skippmatch2()')
let lastline = getline(lnum)
if lastline =~ '^\s*/\*'
@ -184,6 +197,17 @@ function! GetLastRealCodeLNum(startline) " {{{
return lnum
endfunction " }}}
function! Skippmatch2()
let line = getline(".")
if line =~ '\%(".*\)\@<=/\*\%(.*"\)\@=' || line =~ '\%(//.*\)\@<=/\*'
return 1
else
return 0
endif
endfun
function! Skippmatch() " {{{
let synname = synIDattr(synID(line("."), col("."), 0), "name")
if synname == "Delimiter" || synname == "phpParent" || synname == "javaScriptBraces" || synname == "phpComment" && b:UserIsTypingComment
@ -245,7 +269,7 @@ function! IslinePHP (lnum, tofind) " {{{
let cline = getline(a:lnum)
if a:tofind==""
let tofind = "^\\s*[\"']*\s*\\zs\\S"
let tofind = "^\\s*[\"']*\\s*\\zs\\S"
else
let tofind = a:tofind
endif
@ -264,17 +288,28 @@ function! IslinePHP (lnum, tofind) " {{{
endfunction " }}}
let s:notPhpHereDoc = '\%(break\|return\|continue\|exit\);'
let s:blockstart = '\%(\%(\%(}\s*\)\=else\%(\s\+\)\=\)\=if\>\|else\>\|while\>\|switch\>\|for\%(each\)\=\>\|declare\>\|class\>\|[|&]\)'
let s:blockstart = '\%(\%(\%(}\s*\)\=else\%(\s\+\)\=\)\=if\>\|else\>\|while\>\|switch\>\|for\%(each\)\=\>\|declare\>\|class\>\|interface\>\|abstract\>\|[|&]\)'
let s:autorestoptions = 0
if ! s:autorestoptions
au BufWinEnter,Syntax *.php,*.php3,*.php4,*.php5 call ResetOptions()
au BufWinEnter,Syntax *.php,*.php3,*.php4,*.php5 call ResetOptions()
let s:autorestoptions = 1
endif
function! ResetOptions()
if ! b:optionsset
setlocal formatoptions=qroc
if b:PHP_autoformatcomment
setlocal comments=s1:/*,mb:*,ex:*/,://,:#
setlocal formatoptions-=t
setlocal formatoptions+=q
setlocal formatoptions+=r
setlocal formatoptions+=o
setlocal formatoptions+=w
setlocal formatoptions+=c
setlocal formatoptions+=b
endif
let b:optionsset = 1
endif
endfunc
@ -376,7 +411,7 @@ function! GetPhpIndent()
if cline !~ '^\*/'
call search('\*/', 'W')
endif
let lnum = searchpair('/\*', '', '\*/', s:searchpairflags)
let lnum = searchpair('/\*', '', '\*/', s:searchpairflags, 'Skippmatch2()')
let b:PHP_CurrentIndentLevel = b:PHP_default_indenting
@ -493,7 +528,7 @@ function! GetPhpIndent()
if cline !~ '^\*/'
call search('\*/', 'W')
endif
let lnum = searchpair('/\*', '', '\*/', s:searchpairflags)
let lnum = searchpair('/\*', '', '\*/', s:searchpairflags, 'Skippmatch2()')
let b:PHP_CurrentIndentLevel = b:PHP_default_indenting

View file

@ -1,16 +1,10 @@
" Vim indent file
" Language: Ruby
" Maintainer: Gavin Sinclair <gsinclair at soyabean.com.au>
" Developer: Nikolai Weibull <source at pcppopper.org>
" Info: $Id$
" URL: http://vim-ruby.rubyforge.org/
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" Language: Ruby
" Maintainer: Gavin Sinclair <gsinclair at soyabean.com.au>
" Developer: Nikolai Weibull <source at pcppopper.org>
" Info: $Id$
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" ----------------------------------------------------------------------------
" 0. Initialization {{{1
@ -42,17 +36,13 @@ set cpo&vim
let s:syng_strcom = '\<ruby\%(String\|StringDelimiter\|ASCIICode' .
\ '\|Interpolation\|NoInterpolation\|Escape\|Comment\|Documentation\)\>'
" Regex of syntax group names that are strings or comments.
let s:syng_strcom2 = '\<ruby\%(String' .
\ '\|Interpolation\|NoInterpolation\|Escape\|Comment\|Documentation\)\>'
" Regex of syntax group names that are strings.
let s:syng_string =
\ '\<ruby\%(String\|Interpolation\|NoInterpolation\|Escape\)\>'
\ '\<ruby\%(String\|StringDelimiter\|Interpolation\|NoInterpolation\|Escape\)\>'
" Regex of syntax group names that are strings or documentation.
let s:syng_stringdoc =
\'\<ruby\%(String\|Interpolation\|NoInterpolation\|Escape\|Documentation\)\>'
\'\<ruby\%(String\|StringDelimiter\|Interpolation\|NoInterpolation\|Escape\|Documentation\)\>'
" Expression used to check whether we should skip a match with searchpair().
let s:skip_expr =
@ -109,11 +99,6 @@ function s:IsInStringOrComment(lnum, col)
return synIDattr(synID(a:lnum, a:col, 0), 'name') =~ s:syng_strcom
endfunction
" Check if the character at lnum:col is inside a string or comment.
function s:IsInStringOrComment2(lnum, col)
return synIDattr(synID(a:lnum, a:col, 0), 'name') =~ s:syng_strcom2
endfunction
" Check if the character at lnum:col is inside a string.
function s:IsInString(lnum, col)
return synIDattr(synID(a:lnum, a:col, 0), 'name') =~ s:syng_string
@ -134,14 +119,14 @@ function s:PrevNonBlankNonString(lnum)
let line = getline(lnum)
if line =~ '^=begin$'
if in_block
let in_block = 0
let in_block = 0
else
break
break
endif
elseif !in_block && line =~ '^=end$'
let in_block = 1
elseif !in_block && line !~ '^\s*#.*$' && !(s:IsInStringOrComment(lnum, 1)
\ && s:IsInStringOrComment(lnum, strlen(line)))
\ && s:IsInStringOrComment(lnum, strlen(line)))
break
endif
let lnum = prevnonblank(lnum - 1)
@ -160,7 +145,7 @@ function s:GetMSL(lnum)
let line = getline(lnum)
let col = match(line, s:continuation_regex2) + 1
if (col > 0 && !s:IsInStringOrComment(lnum, col))
\ || s:IsInString(lnum, strlen(line))
\ || s:IsInString(lnum, strlen(line))
let msl = lnum
else
break
@ -181,9 +166,9 @@ function s:LineHasOpeningBrackets(lnum)
if !s:IsInStringOrComment(a:lnum, pos + 1)
let idx = stridx('(){}[]', line[pos])
if idx % 2 == 0
let open_{idx} = open_{idx} + 1
let open_{idx} = open_{idx} + 1
else
let open_{idx - 1} = open_{idx - 1} - 1
let open_{idx - 1} = open_{idx - 1} - 1
endif
endif
let pos = match(line, '[][(){}]', pos + 1)
@ -246,13 +231,13 @@ function GetRubyIndent()
if s:Match(v:lnum, s:ruby_deindent_keywords)
call cursor(v:lnum, 1)
if searchpair(s:end_start_regex, s:end_middle_regex, s:end_end_regex, 'bW',
\ s:end_skip_expr) > 0
\ s:end_skip_expr) > 0
let line = getline('.')
if strpart(line, 0, col('.') - 1) =~ '=\s*$' &&
\ strpart(line, col('.') - 1, 2) !~ 'do'
let ind = virtcol('.') - 1
let ind = virtcol('.') - 1
else
let ind = indent('.')
let ind = indent('.')
endif
endif
return ind
@ -302,12 +287,12 @@ function GetRubyIndent()
if col > 0
call cursor(lnum, col)
if searchpair(s:end_start_regex, '', s:end_end_regex, 'bW',
\ s:end_skip_expr) > 0
\ s:end_skip_expr) > 0
let n = line('.')
let ind = indent('.')
let msl = s:GetMSL(n)
if msl != n
let ind = indent(msl)
let ind = indent(msl)
end
return ind
endif

View file

@ -0,0 +1,156 @@
" netrw.vim: Handles file transfer and remote directory listing across a network
" PLUGIN PORTION
" Last Change: Aug 31, 2005
" Maintainer: Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
" Version: 67
" License: Vim License (see vim's :help license)
" GetLatestVimScripts: 1075 1 :AutoInstall: netrw.vim
" Copyright: Copyright (C) 1999-2005 Charles E. Campbell, Jr. {{{1
" Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright
" notice is copied with it. Like anything else that's free,
" netrw.vim is provided *as is* and comes with no warranty
" of any kind, either expressed or implied. By using this
" plugin, you agree that in no event will the copyright
" holder be liable for any damages resulting from the use
" of this software.
"
" But be doers of the Word, and not only hearers, deluding your own selves {{{1
" (James 1:22 RSV)
" =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
" ---------------------------------------------------------------------
" Load Once: {{{1
if exists("g:loaded_netrw") || &cp
finish
endif
if v:version < 600
echoerr "***netrw*** doesn't support Vim version ".v:version
finish
endif
let g:loaded_netrw = "v67"
if v:version < 700
let loaded_explorer = 1
endif
let s:keepcpo= &cpo
set cpo&vim
" ---------------------------------------------------------------------
" Public Interface: {{{1
" Local Browsing: {{{2
augroup FileExplorer
au!
au BufEnter * call s:LocalBrowse(expand("<amatch>"))
augroup END
" Network Browsing Reading Writing: {{{2
augroup Network
au!
if has("win32") || has("win95") || has("win64") || has("win16")
au BufReadCmd file://* exe "silent doau BufReadPre ".expand("<amatch>")|exe 'e '.substitute(expand("<amatch>"),"file:/*","","")|exe "silent doau BufReadPost ".expand("<amatch>")
else
au BufReadCmd file:///* exe "silent doau BufReadPre ".expand("<amatch>")|exe 'e /'.substitute(expand("<amatch>"),"file:/*","","")|exe "silent doau BufReadPost ".expand("<amatch>")
au BufReadCmd file://localhost/* exe "silent doau BufReadPre ".expand("<amatch>")|exe 'e /'.substitute(expand("<amatch>"),"file:/*","","")|exe "silent doau BufReadPost ".expand("<amatch>")
endif
au BufReadCmd ftp://*,rcp://*,scp://*,http://*,dav://*,rsync://*,sftp://* exe "silent doau BufReadPre ".expand("<amatch>")|exe "Nread 0r ".expand("<amatch>")|exe "silent doau BufReadPost ".expand("<amatch>")
au FileReadCmd ftp://*,rcp://*,scp://*,http://*,dav://*,rsync://*,sftp://* exe "silent doau BufReadPre ".expand("<amatch>")|exe "Nread " .expand("<amatch>")|exe "silent doau FileReadPost ".expand("<amatch>")
au BufWriteCmd ftp://*,rcp://*,scp://*,dav://*,rsync://*,sftp://* exe "silent doau BufWritePre ".expand("<amatch>")|exe "Nwrite " .expand("<amatch>")|exe "silent doau BufWritePost ".expand("<amatch>")
au FileWriteCmd ftp://*,rcp://*,scp://*,dav://*,rsync://*,sftp://* exe "silent doau BufWritePre ".expand("<amatch>")|exe "'[,']Nwrite " .expand("<amatch>")|exe "silent doau FileWritePost ".expand("<amatch>")
augroup END
" Commands: :Nread, :Nwrite, :NetUserPass {{{2
com! -nargs=* Nread call netrw#NetSavePosn()<bar>call netrw#NetRead(<f-args>)<bar>call netrw#NetRestorePosn()
com! -range=% -nargs=* Nwrite call netrw#NetSavePosn()<bar><line1>,<line2>call netrw#NetWrite(<f-args>)<bar>call netrw#NetRestorePosn()
com! -nargs=* NetUserPass call NetUserPass(<f-args>)
" Commands: :Explore, :Sexplore, Hexplore, Vexplore {{{2
com! -nargs=? -bar -bang -count=0 Explore call netrw#Explore(<count>,0,0+<bang>0,<q-args>)
com! -nargs=? -bar -bang -count=0 Sexplore call netrw#Explore(<count>,1,0+<bang>0,<q-args>)
com! -nargs=? -bar -bang -count=0 Hexplore call netrw#Explore(<count>,1,2+<bang>0,<q-args>)
com! -nargs=? -bar -bang -count=0 Vexplore call netrw#Explore(<count>,1,4+<bang>0,<q-args>)
com! -nargs=? -bar -bang Nexplore call netrw#Explore(-1,0,0,<q-args>)
com! -nargs=? -bar -bang Pexplore call netrw#Explore(-2,0,0,<q-args>)
" Commands: NetrwSettings {{{2
com! -nargs=0 NetrwSettings :call NetrwSettings#NetrwSettings()
" ---------------------------------------------------------------------
" LocalBrowse: {{{2
fun! s:LocalBrowse(dirname)
" unfortunate interaction -- debugging calls can't be used here;
" the BufEnter event causes triggering when attempts to write to
" the DBG buffer are made.
if isdirectory(a:dirname)
call netrw#DirBrowse(a:dirname)
endif
" not a directory, ignore it
endfun
" ---------------------------------------------------------------------
" NetrwStatusLine: {{{1
fun! NetrwStatusLine()
" let g:stlmsg= "Xbufnr=".w:netrw_explore_bufnr." bufnr=".bufnr(".")." Xline#".w:netrw_explore_line." line#".line(".")
if !exists("w:netrw_explore_bufnr") || w:netrw_explore_bufnr != bufnr(".") || !exists("w:netrw_explore_line") || w:netrw_explore_line != line(".") || !exists("w:netrw_explore_list")
let &stl= s:netrw_explore_stl
if exists("w:netrw_explore_bufnr")|unlet w:netrw_explore_bufnr|endif
if exists("w:netrw_explore_line")|unlet w:netrw_explore_line|endif
return ""
else
return "Match ".w:netrw_explore_mtchcnt." of ".w:netrw_explore_listlen
endif
endfun
" ------------------------------------------------------------------------
" NetUserPass: set username and password for subsequent ftp transfer {{{1
" Usage: :call NetUserPass() -- will prompt for userid and password
" :call NetUserPass("uid") -- will prompt for password
" :call NetUserPass("uid","password") -- sets global userid and password
fun! NetUserPass(...)
" get/set userid
if a:0 == 0
" call Dfunc("NetUserPass(a:0<".a:0.">)")
if !exists("g:netrw_uid") || g:netrw_uid == ""
" via prompt
let g:netrw_uid= input('Enter username: ')
endif
else " from command line
" call Dfunc("NetUserPass(a:1<".a:1.">) {")
let g:netrw_uid= a:1
endif
" get password
if a:0 <= 1 " via prompt
" call Decho("a:0=".a:0." case <=1:")
let g: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
endif
" call Dret("NetUserPass")
endfun
" ------------------------------------------------------------------------
" NetReadFixup: this sort of function is typically written by the user {{{1
" to handle extra junk that their system's ftp dumps
" into the transfer. This function is provided as an
" example and as a fix for a Windows 95 problem: in my
" experience, win95's ftp always dumped four blank lines
" at the end of the transfer.
if has("win95") && g:netrw_win95ftp
fun! NetReadFixup(method, line1, line2)
" call Dfunc("NetReadFixup(method<".a:method."> line1=".a:line1." line2=".a:line2.")")
if method == 3 " ftp (no <.netrc>)
let fourblanklines= line2 - 3
silent fourblanklines.",".line2."g/^\s*/d"
endif
" call Dret("NetReadFixup")
endfun
endif
let &cpo= s:keepcpo
unlet s:keepcpo
" ------------------------------------------------------------------------
" Modelines: {{{1
" vim:ts=8 fdm=marker

View file

@ -0,0 +1,157 @@
" NetrwSettings.vim: makes netrw settings simpler
" Last Change: Aug 16, 2005
" Maintainer: Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
" Version: 3
" Copyright: Copyright (C) 1999-2005 Charles E. Campbell, Jr. {{{1
" Permission is hereby granted to use and distribute this code,
" with or without modifications, provided that this copyright
" notice is copied with it. Like anything else that's free,
" NetrwSettings.vim is provided *as is* and comes with no
" warranty of any kind, either expressed or implied. By using
" this plugin, you agree that in no event will the copyright
" holder be liable for any damages resulting from the use
" of this software.
"
" Mat 4:23 (WEB) Jesus went about in all Galilee, teaching in their {{{1
" synagogues, preaching the gospel of the kingdom, and healing
" every disease and every sickness among the people.
" Load Once: {{{1
if exists("g:loaded_NetrwSettings") || &cp
finish
endif
let g:loaded_NetrwSettings = "v3"
" ---------------------------------------------------------------------
" NetrwSettings: {{{1
fun! NetrwSettings#NetrwSettings()
" this call is here largely just to insure that netrw has been loaded
call netrw#NetSavePosn()
above wincmd s
enew
setlocal noswapfile bh=wipe
set ft=vim
file Netrw\ Settings
" these variables have the following default effects when they don't
" exist (ie. have not been set by the user in his/her .vimrc)
if !exists("g:netrw_longlist")
let g:netrw_longlist= 0
let g:netrw_list_cmd= "ssh HOSTNAME ls -FLa"
endif
if !exists("g:netrw_silent")
let g:netrw_silent= 0
endif
if !exists("g:netrw_use_nt_rcp")
let g:netrw_use_nt_rcp= 0
endif
if !exists("g:netrw_ftp")
let g:netrw_ftp= 0
endif
if !exists("g:netrw_ignorenetrc")
let g:netrw_ignorenetrc= 0
endif
put ='+ ---------------------------------------------'
put ='+ NetrwSettings: (by Charles E. Campbell, Jr.)'
put ='+ Press ? with cursor atop any line for help '
put ='+ ---------------------------------------------'
let s:netrw_settings_stop= line(".")
put =''
put ='+ Netrw Protocol Commands'
put = 'let g:netrw_dav_cmd = '.g:netrw_dav_cmd
put = 'let g:netrw_fetch_cmd = '.g:netrw_fetch_cmd
put = 'let g:netrw_ftp_cmd = '.g:netrw_ftp_cmd
put = 'let g:netrw_http_cmd = '.g:netrw_http_cmd
put = 'let g:netrw_rcp_cmd = '.g:netrw_rcp_cmd
put = 'let g:netrw_rsync_cmd = '.g:netrw_rsync_cmd
put = 'let g:netrw_scp_cmd = '.g:netrw_scp_cmd
put = 'let g:netrw_sftp_cmd = '.g:netrw_sftp_cmd
let s:netrw_protocol_stop= line(".")
put = ''
put ='+Netrw Transfer Control'
put = 'let g:netrw_cygwin = '.g:netrw_cygwin
put = 'let g:netrw_ftp = '.g:netrw_ftp
put = 'let g:netrw_ftpmode = '.g:netrw_ftpmode
put = 'let g:netrw_ignorenetrc = '.g:netrw_ignorenetrc
put = 'let g:netrw_use_nt_rcp = '.g:netrw_use_nt_rcp
put = 'let g:netrw_win95ftp = '.g:netrw_win95ftp
let s:netrw_xfer_stop= line(".")
put = ''
put ='+ Netrw Browser Control'
put = 'let g:netrw_alto = '.g:netrw_alto
put = 'let g:netrw_altv = '.g:netrw_altv
put = 'let g:netrw_dirhistmax = '.g:netrw_dirhistmax
put = 'let g:netrw_ftp_browse_reject = '.g:netrw_ftp_browse_reject
put = 'let g:netrw_ftp_list_cmd = '.g:netrw_ftp_list_cmd
put = 'let g:netrw_hide = '.g:netrw_hide
put = 'let g:netrw_keepdir = '.g:netrw_keepdir
put = 'let g:netrw_list_cmd = '.g:netrw_list_cmd
put = 'let g:netrw_list_cmd = '.g:netrw_list_cmd
put = 'let g:netrw_list_hide = '.g:netrw_list_hide
put = 'let g:netrw_local_mkdir = '.g:netrw_local_mkdir
put = 'let g:netrw_local_rmdir = '.g:netrw_local_rmdir
put = 'let g:netrw_longlist = '.g:netrw_longlist
put = 'let g:netrw_maxfilenamelen = '.g:netrw_maxfilenamelen
put = 'let g:netrw_mkdir_cmd = '.g:netrw_mkdir_cmd
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
put = 'let g:netrw_rmf_cmd = '.g:netrw_rmf_cmd
put = 'let g:netrw_silent = '.g:netrw_silent
put = 'let g:netrw_sort_by = '.g:netrw_sort_by
put = 'let g:netrw_sort_direction = '.g:netrw_sort_direction
put = 'let g:netrw_sort_sequence = '.g:netrw_sort_sequence
put = 'let g:netrw_ssh_browse_reject = '.g:netrw_ssh_browse_reject
put = 'let g:netrw_timefmt = '.g:netrw_timefmt
put = 'let g:netrw_winsize = '.g:netrw_winsize
put =''
put ='+ For help, place cursor on line and press ?'
1d
silent %s/^+/"/e
res 99
silent %s/= \([^0-9].*\)$/= '\1'/e
silent %s/= $/= ''/e
1
set nomod
map <buffer> <silent> ? :call NetrwSettingHelp()<cr>
let tmpfile= tempname()
exe 'au BufWriteCmd Netrw\ Settings silent w! '.tmpfile.'|so '.tmpfile.'|call delete("'.tmpfile.'")|set nomod'
endfun
" ---------------------------------------------------------------------
" NetrwSettingHelp: {{{2
fun! NetrwSettingHelp()
" call Dfunc("NetrwSettingHelp()")
let curline = getline(".")
if curline =~ '='
let varhelp = substitute(curline,'^\s*let ','','e')
let varhelp = substitute(varhelp,'\s*=.*$','','e')
" call Decho("trying help ".varhelp)
try
exe "he ".varhelp
catch /^Vim\%((\a\+)\)\=:E149/
echo "***sorry*** no help available for <".varhelp.">"
endtry
elseif line(".") < s:netrw_settings_stop
he netrw-settings
elseif line(".") < s:netrw_protocol_stop
he netrw-externapp
elseif line(".") < s:netrw_xfer_stop
he netrw-variables
else
he netrw-browse-var
endif
" call Dret("NetrwSettingHelp")
endfun
" ---------------------------------------------------------------------
" Modelines: {{{1
" vim:ts=8 fdm=marker

View file

@ -1,6 +1,6 @@
" netrwPlugin.vim: Handles file transfer and remote directory listing across a network
" PLUGIN PORTION
" Date: Oct 12, 2005
" Date: Oct 27, 2005
" Maintainer: Charles E Campbell, Jr <drchipNOSPAM at campbellfamily dot biz>
" GetLatestVimScripts: 1075 1 :AutoInstall: netrw.vim
" Copyright: Copyright (C) 1999-2005 Charles E. Campbell, Jr. {{{1
@ -42,15 +42,15 @@ augroup END
augroup Network
au!
if has("win32") || has("win95") || has("win64") || has("win16")
au BufReadCmd file://* exe "silent doau BufReadPre ".expand("<amatch>")|exe 'e '.substitute(expand("<amatch>"),"file:/*","","")|exe "silent doau BufReadPost ".expand("<amatch>")
au BufReadCmd file://* exe "silent doau BufReadPre ".netrw#RFC2396(expand("<amatch>"))|exe 'e '.substitute(netrw#RFC2396(expand("<amatch>")),'file://\(.*\)','\1',"")|exe "silent doau BufReadPost ".netrw#RFC2396(expand("<amatch>"))
else
au BufReadCmd file:///* exe "silent doau BufReadPre ".expand("<amatch>")|exe 'e /'.substitute(expand("<amatch>"),"file:/*","","")|exe "silent doau BufReadPost ".expand("<amatch>")
au BufReadCmd file://localhost/* exe "silent doau BufReadPre ".expand("<amatch>")|exe 'e /'.substitute(expand("<amatch>"),"file:/*","","")|exe "silent doau BufReadPost ".expand("<amatch>")
au BufReadCmd file://* exe "silent doau BufReadPre ".netrw#RFC2396(expand("<amatch>"))|exe 'e '.substitute(netrw#RFC2396(expand("<amatch>")),'file://\(.*\)','\1',"")|exe "silent doau BufReadPost ".netrw#RFC2396(expand("<amatch>"))
au BufReadCmd file://localhost/* exe "silent doau BufReadPre ".netrw#RFC2396(expand("<amatch>"))|exe 'e '.substitute(netrw#RFC2396(expand("<amatch>")),'file://localhost/\(.*\)','\1',"")|exe "silent doau BufReadPost ".netrw#RFC2396(expand("<amatch>"))
endif
au BufReadCmd ftp://*,rcp://*,scp://*,http://*,dav://*,rsync://*,sftp://* exe "silent doau BufReadPre ".expand("<amatch>")|exe "Nread 0r ".expand("<amatch>")|exe "silent doau BufReadPost ".expand("<amatch>")
au FileReadCmd ftp://*,rcp://*,scp://*,http://*,dav://*,rsync://*,sftp://* exe "silent doau BufReadPre ".expand("<amatch>")|exe "Nread " .expand("<amatch>")|exe "silent doau FileReadPost ".expand("<amatch>")
au FileReadCmd ftp://*,rcp://*,scp://*,http://*,dav://*,rsync://*,sftp://* exe "silent doau FileReadPre ".expand("<amatch>")|exe "Nread " .expand("<amatch>")|exe "silent doau FileReadPost ".expand("<amatch>")
au BufWriteCmd ftp://*,rcp://*,scp://*,dav://*,rsync://*,sftp://* exe "silent doau BufWritePre ".expand("<amatch>")|exe "Nwrite " .expand("<amatch>")|exe "silent doau BufWritePost ".expand("<amatch>")
au FileWriteCmd ftp://*,rcp://*,scp://*,dav://*,rsync://*,sftp://* exe "silent doau BufWritePre ".expand("<amatch>")|exe "'[,']Nwrite " .expand("<amatch>")|exe "silent doau FileWritePost ".expand("<amatch>")
au FileWriteCmd ftp://*,rcp://*,scp://*,dav://*,rsync://*,sftp://* exe "silent doau FileWritePre ".expand("<amatch>")|exe "'[,']Nwrite " .expand("<amatch>")|exe "silent doau FileWritePost ".expand("<amatch>")
augroup END
" Commands: :Nread, :Nwrite, :NetUserPass {{{2

View file

@ -1,34 +0,0 @@
" tar.vim -- a Vim plugin for browsing tarfiles
" Copyright (c) 2002, Michael C. Toren <mct@toren.net>
" Distributed under the GNU General Public License.
"
" Version: 1.01
" Last Change: 2005 Jul 26
"
" Updates are available from <http://michael.toren.net/code/>. If you
" find this script useful, or have suggestions for improvements, please
" let me know.
" Also look there for further comments and documentation.
"
" This part only sets the autocommands. The functions are in autoload/tar.vim.
if has("autocmd")
augroup tar
au!
au BufReadCmd tarfile:* call tar#Read(expand("<afile>"), 1)
au BufReadCmd tarfile:*/* call tar#Read(expand("<afile>"), 1)
au FileReadCmd tarfile:* call tar#Read(expand("<afile>"), 0)
au FileReadCmd tarfile:*/* call tar#Read(expand("<afile>"), 0)
au BufWriteCmd tarfile:* call tar#Write(expand("<afile>"))
au BufWriteCmd tarfile:*/* call tar#Write(expand("<afile>"))
au FileWriteCmd tarfile:* call tar#Write(expand("<afile>"))
au FileWriteCmd tarfile:*/* call tar#Write(expand("<afile>"))
au BufReadCmd *.tar call tar#Browse(expand("<afile>"))
au BufReadCmd *.tar.gz call tar#Browse(expand("<afile>"))
au BufReadCmd *.tar.bz2 call tar#Browse(expand("<afile>"))
au BufReadCmd *.tar.Z call tar#Browse(expand("<afile>"))
au BufReadCmd *.tgz call tar#Browse(expand("<afile>"))
augroup END
endif

View file

@ -9,25 +9,25 @@
"
" This part only sets the autocommands. The functions are in autoload/tar.vim.
if has("autocmd")
augroup tar
au!
au BufReadCmd tarfile:* call tar#Read(expand("<afile>"), 1)
au BufReadCmd tarfile:*/* call tar#Read(expand("<afile>"), 1)
au FileReadCmd tarfile:* call tar#Read(expand("<afile>"), 0)
au FileReadCmd tarfile:*/* call tar#Read(expand("<afile>"), 0)
augroup tar
au!
au BufReadCmd tarfile:* call tar#Read(expand("<amatch>"), 1)
au FileReadCmd tarfile:* call tar#Read(expand("<amatch>"), 0)
au BufWriteCmd tarfile:* call tar#Write(expand("<amatch>"))
au FileWriteCmd tarfile:* call tar#Write(expand("<amatch>"))
au BufWriteCmd tarfile:* call tar#Write(expand("<afile>"))
au BufWriteCmd tarfile:*/* call tar#Write(expand("<afile>"))
au FileWriteCmd tarfile:* call tar#Write(expand("<afile>"))
au FileWriteCmd tarfile:*/* call tar#Write(expand("<afile>"))
if has("unix")
au BufReadCmd tarfile:*/* call tar#Read(expand("<amatch>"), 1)
au FileReadCmd tarfile:*/* call tar#Read(expand("<amatch>"), 0)
au BufWriteCmd tarfile:*/* call tar#Write(expand("<amatch>"))
au FileWriteCmd tarfile:*/* call tar#Write(expand("<amatch>"))
endif
au BufReadCmd *.tar call tar#Browse(expand("<afile>"))
au BufReadCmd *.tar.gz call tar#Browse(expand("<afile>"))
au BufReadCmd *.tar.bz2 call tar#Browse(expand("<afile>"))
au BufReadCmd *.tar.Z call tar#Browse(expand("<afile>"))
au BufReadCmd *.tgz call tar#Browse(expand("<afile>"))
augroup END
endif
au BufReadCmd *.tar call tar#Browse(expand("<amatch>"))
au BufReadCmd *.tar.gz call tar#Browse(expand("<amatch>"))
au BufReadCmd *.tar.bz2 call tar#Browse(expand("<amatch>"))
au BufReadCmd *.tar.Z call tar#Browse(expand("<amatch>"))
au BufReadCmd *.tgz call tar#Browse(expand("<amatch>"))
augroup END
" vim: ts=8

View file

@ -22,19 +22,19 @@ set cpo&vim
" Public Interface: {{{1
augroup zip
au!
au BufReadCmd zipfile:* call zip#Read(expand("<afile>"), 1)
au FileReadCmd zipfile:* call zip#Read(expand("<afile>"), 0)
au BufWriteCmd zipfile:* call zip#Write(expand("<afile>"))
au FileWriteCmd zipfile:* call zip#Write(expand("<afile>"))
au BufReadCmd zipfile:* call zip#Read(expand("<amatch>"), 1)
au FileReadCmd zipfile:* call zip#Read(expand("<amatch>"), 0)
au BufWriteCmd zipfile:* call zip#Write(expand("<amatch>"))
au FileWriteCmd zipfile:* call zip#Write(expand("<amatch>"))
if has("unix")
au BufReadCmd zipfile:*/* call zip#Read(expand("<afile>"), 1)
au FileReadCmd zipfile:*/* call zip#Read(expand("<afile>"), 0)
au BufWriteCmd zipfile:*/* call zip#Write(expand("<afile>"))
au FileWriteCmd zipfile:*/* call zip#Write(expand("<afile>"))
au BufReadCmd zipfile:*/* call zip#Read(expand("<amatch>"), 1)
au FileReadCmd zipfile:*/* call zip#Read(expand("<amatch>"), 0)
au BufWriteCmd zipfile:*/* call zip#Write(expand("<amatch>"))
au FileWriteCmd zipfile:*/* call zip#Write(expand("<amatch>"))
endif
au BufReadCmd *.zip call zip#Browse(expand("<afile>"))
au BufReadCmd *.zip call zip#Browse(expand("<amatch>"))
augroup END
" ------------------------------------------------------------------------

View file

@ -1,4 +1,6 @@
# Aap recipe for Swedish Vim spell files.
#
# Maintainer: Stefan Karlsson <stefan.74@comhem.se>
# Use a freshly compiled Vim if it exists.
@if os.path.exists('../../../src/vim'):

View file

@ -139,3 +139,547 @@
+ SAL Ä E
+ SAL ÖG(IE)-6 ÖK # vokal+g(ie) ger ej j-ljud
+ SAL Ö Ö
*** sv_SE.orig.dic 2003-08-14 13:02:06.000000000 +0200
--- sv_SE.dic 2005-10-15 18:15:52.171875000 +0200
***************
*** 108,113 ****
--- 108,114 ----
adoption/ADHS
adoptivbarn/BDS
adoptivson/ADS
+ adr.
adrenalin/BS
adress/DHS
adressat/ADHS
***************
*** 608,613 ****
--- 609,615 ----
anlöps/S
anlöpta/JRS
anm
+ anm.
anmaning/ADGS
anmoda/ABCDEFMNPS
anmodande/ACEFS
***************
*** 973,978 ****
--- 975,981 ----
arrogant/OS
arsenal/DHS
arsenik/DS
+ art.
art/ADHOS
arta/CHJMNPS
artefakt/DHS
***************
*** 1094,1099 ****
--- 1097,1103 ----
audiens/DHS
auditorie/CIS
auditorium/JS
+ aug.
August/A
augusti/AS
auktion/ADHS
***************
*** 2376,2381 ****
--- 2380,2386 ----
bikupa/AEGS
bikupe/S
bikups/S
+ bil.
bil/ADGS
bila/EGIJOS
bilaga/EGOS
***************
*** 2490,2495 ****
--- 2495,2501 ----
Björn
björn/ADGS
Björns
+ bl.a.
bla/JS
black/DGS
blackout/DHS
***************
*** 3645,3650 ****
--- 3651,3657 ----
debut/ADHS
debutant/DHS
debutera/JMS
+ dec.
december/AS
decennie/CIS
decennium/AJS
***************
*** 4117,4122 ****
--- 4124,4130 ----
dotterson/ADS
Douglas
dov/OPS
+ dr
dra/AJS
drabant/DHS
drabba/ACMNPS
***************
*** 4315,4321 ****
duven/MS
dvala/EGJS
dvaldes/S
! dvs
dväljas/S
dväljes/S
dväljs/NS
--- 4323,4330 ----
duven/MS
dvala/EGJS
dvaldes/S
! dvs.
! d.v.s.
dväljas/S
dväljes/S
dväljs/NS
***************
*** 4463,4468 ****
--- 4472,4478 ----
Ebbas
Ecuador/A
ed/ADHS
+ e.d.
Edberg/A
eder/AJMS
Edit/A
***************
*** 4612,4617 ****
--- 4622,4628 ----
ekorre/AEGS
ekosystem/BDS
ekosändning/ADGS
+ e.Kr.
eksem/BDS
Eksjö/A
ekumenik/DS
***************
*** 4825,4830 ****
--- 4836,4842 ----
enkrona/EGS
enkät/DHS
Enköping/A
+ enl.
enlighet/S
enligt/S
enorm/OPS
***************
*** 4990,4995 ****
--- 5002,5008 ----
etanol/DS
etapp/DHS
etc
+ etc.
etcetera/S
eten/BDS
eter/ES
***************
*** 5334,5341 ****
--- 5347,5356 ----
favorisera/ACDMNPS
favorit/ADHS
favör/DHS
+ f.d.
fe/EFHS
feber/ES
+ febr.
febril/MOPS
februari/AS
federal/MOS
***************
*** 5451,5456 ****
--- 5466,5472 ----
fiffla/ACDMNS
fifflar/DJQS
fifflare/AEJS
+ fig.
figur/ADHS
figurativ/OS
figurera/ACJMNPS
***************
*** 5635,5640 ****
--- 5651,5657 ----
fjäsk/ABS
fjäska/JMS
fjättra/CMNPS
+ f.Kr.
flack/OPS
flacka/ABCDJMNS
fladder/CS
***************
*** 5913,5918 ****
--- 5930,5936 ----
fortplanta/ACMNPS
fortplantning/ADGS
fortran/S
+ forts.
fortsatt/OQS
fortskrida/KS
fortsätta/AJS
***************
*** 6075,6080 ****
--- 6093,6099 ----
fras/DHS
frasa/BDHJMS
frasering/ADS
+ fre.
fred/ADS
freda/ACJMNPS
fredag/ADGS
***************
*** 6170,6175 ****
--- 6189,6195 ----
frivol/MOS
froda/ACMNPS
frodig/OS
+ fr.o.m.
from/KLMNS
fromhet/ADS
fromt/S
***************
*** 6453,6458 ****
--- 6473,6479 ----
fästman/AFS
fästmö/AEIS
fästning/ADGS
+ f.ö.
föda/ADEJKLRS
född/OQS
födelse/AES
***************
*** 10493,10498 ****
--- 10514,10520 ----
Jan/A
Janne/A
Janos
+ jan.
januari/AS
japan/DHS
Japans
***************
*** 10520,10525 ****
--- 10542,10548 ----
jetflyg/ABS
jetmotor/EHS
jetplan/ABDS
+ jfr
jiddisch/DS
Jimmy/A
jippo/ACES
***************
*** 10870,10875 ****
--- 10893,10899 ----
kaos/BS
kaotisk/OS
Kap
+ kap.
kap/BDS
kapa/ACJMNPS
kapabel/KMS
***************
*** 11119,11124 ****
--- 11143,11149 ----
Kjell/A
kjol/ADGS
kjortel/EIS
+ kl.
kl
klack/DGS
klacka/IJMS
***************
*** 13445,13450 ****
--- 13470,13476 ----
löpning/ADGS
löpsedel/AEIS
löptid/DS
+ lör.
lördag/ADGS
lös/AORS
lösa/ABDJKLQRS
***************
*** 13783,13788 ****
--- 13809,13815 ----
Mauretanien/A
Mauritius
mausoleum/JS
+ max.
max
maxim/DHS
maximal/MOS
***************
*** 13965,13970 ****
--- 13992,13998 ----
mexikan/DHS
mexikanska/AEGS
Mexiko/A
+ m.fl.
mg
MHz
Michael/A
***************
*** 14016,14021 ****
--- 14044,14050 ----
milslång/OS
milstolpe/AEGS
mimosa/AES
+ min.
min/ACDFHS
mina/HJS
mindervärdig/OQRS
***************
*** 14136,14141 ****
--- 14165,14171 ----
mjölnar/DJQS
mjölnare/AEJS
ml
+ m.m.
mm
mo/AEGS
mobba/ACMNPS
***************
*** 14539,14544 ****
--- 14569,14575 ----
målstyrd/OS
målsättning/ADGS
måltid/ADHS
+ mån.
mån/DGQS
måna/IJMPRS
månad/ADHQS
***************
*** 14792,14797 ****
--- 14823,14830 ----
neutron/DHS
nevö/ES
New
+ ngn
+ ngt
nia/EGJQS
Nicaragua/A
nick/DGS
***************
*** 14920,14931 ****
--- 14953,14966 ----
notifikation/ADS
notis/DHS
notorisk/OS
+ nov.
nova/AES
novell/DHS
novellmagasin/ABDS
novellsamling/ADGS
november/AS
novis/DHS
+ nr.
nr
nu/BS
nubb/S
***************
*** 15243,15248 ****
--- 15278,15284 ----
obrottslig/OS
obrukbar/MOS
obruten/MS
+ obs.
obs
observant/OPS
observation/ADHS
***************
*** 15470,15475 ****
--- 15506,15512 ----
okonventionell/MOS
okritisk/OS
okryddade/OS
+ okt.
oktagon/HS
oktal/MOS
oktav/DHS
***************
*** 15741,15746 ****
--- 15778,15784 ----
onjutbar/MOS
onkel/AES
onormal/MOS
+ ons.
onsdag/ADGS
onyanserade/OS
onykter/MS
***************
*** 15977,15983 ****
--- 16015,16023 ----
ostrukturerade/OS
ostörd/OS
osund/OS
+ osv.
osv
+ o.s.v.
osvensk/OS
osviklig/OPS
osympatisk/OPQS
***************
*** 16378,16383 ****
--- 16418,16424 ----
petitum/ES
Petra/A
Pettersson/A
+ p.g.a.
pga
Philips
pi/FS
***************
*** 17457,17462 ****
--- 17498,17504 ----
resonabel/MS
resonemang/ABDS
resonera/ACMNS
+ resp.
resp/S
respekt/S
respektabel/LMS
***************
*** 18328,18333 ****
--- 18370,18376 ----
sentimentalitet/ADS
separat/OS
separera/ACMNPS
+ sept.
september/AS
seraf/DHS
serenad/DHS
***************
*** 18652,18657 ****
--- 18695,18701 ----
sjöslag/S
sjöss/S
sjåpig/OS
+ s.k.
ska/GJMPS
skada/ABCDEGJMNPS
skadedjur/BDS
***************
*** 20767,20772 ****
--- 20811,20817 ----
sömnlös/OQRS
sömnlöshet/ADS
sömnmedel/ACFS
+ sön.
söndag/ADGS
sönder/S
sönderbruten/MS
***************
*** 20832,20837 ****
--- 20877,20883 ----
såväl/S
såvärst/S
ta/AKRS
+ tab.
tabbe/S
tabell/DHS
tabernaklet/AS
***************
*** 21063,21068 ****
--- 21109,21115 ----
testar/DJQS
testare/AEJS
testning/ADGS
+ t.ex.
tex
Texas
text/DHOS
***************
*** 21336,21341 ****
--- 21383,21389 ----
tippa/ACMNPS
tips/BDS
tipsa/ACJMNPS
+ tis.
tisdag/ADGS
tistel/EIS
titan/S
***************
*** 21463,21468 ****
--- 21511,21517 ----
tolvårig/OS
tolvårs/S
Tom
+ t.o.m.
tom/LMS
Tomas
tomat/DHS
***************
*** 21513,21518 ****
--- 21562,21568 ----
torped/ADHS
torpedbåt/ADGS
torr/MOPS
+ tors.
torsdag/ADGS
torsk/DGS
Torsten/A
***************
*** 22359,22364 ****
--- 22409,22415 ----
uppkomst/DS
uppkoppling/ADGS
uppkrupen/MS
+ uppl.
upplaga/AEGOS
upplagd/OS
upplage/S
***************
*** 22639,22644 ****
--- 22690,22696 ----
utförar/DJQS
utförare/AEJS
utförlig/OPS
+ utg.
utgallra/ACMNPS
utgamla/S
utgammal/MS
***************
*** 23003,23008 ****
--- 23055,23061 ----
varannan/S
varav/S
Varberg/A
+ vard.
varda/BDS
vardag/ADGS
vardaglig/OPS
***************
*** 23091,23096 ****
--- 23144,23150 ----
Vaxholm/A
vaxljus/BDS
Vaxmora
+ vd
VD
ve/GS
veck/ABDS
***************
*** 23203,23208 ****
--- 23257,23264 ----
vettlös/OS
vev/DS
veva/ACJMNPS
+ v.g.
+ v.g.v.
vi/ACEOS
vibration/ADHS
vibrator/AES
***************
*** 23416,23421 ****
--- 23472,23478 ----
VM
vokabulär/S
vokal/DHS
+ vol.
volontär/ADHS
volt/S
Volvo/A

View file

@ -1,7 +1,7 @@
" Vim syntax file
" Language: sgml catalog file
" Maintainer: Johannes Zellner <johannes@zellner.org>
" Last Change: Tue, 27 Apr 2004 14:54:59 CEST
" Last Change: Fr, 04 Nov 2005 12:46:45 CET
" Filenames: /etc/sgml.catalog
" $Id$
@ -17,8 +17,8 @@ syn region catalogString start=+"+ skip=+\\\\\|\\"+ end=+"+ keepend
syn region catalogString start=+'+ skip=+\\\\\|\\'+ end=+'+ keepend
syn region catalogComment start=+--+ end=+--+ contains=catalogTodo
syn keyword catalogTodo TODO FIXME XXX contained display
syn keyword catalogKeyword DOCTYPE OVERRIDE PUBLIC DTDDECL ENTITY display
syn keyword catalogTodo TODO FIXME XXX NOTE contained
syn keyword catalogKeyword DOCTYPE OVERRIDE PUBLIC DTDDECL ENTITY CATALOG
" The default highlighting.

View file

@ -1,175 +1,251 @@
" Vim syntax file
" Language: ColdFusion
" Maintainer: Toby Woodwark (toby.woodwark+vim@gmail.com)
" Last Change: August 3, 2005
" ColdFusion MX 7
" Usage: Since ColdFusion has its own version of HTML comments
" (<!--- --->)
" make sure that you put 'let html_wrong_comments=1' in your .vimrc /
" _vimrc file.
" For version 5.x, clear all syntax items.
" For version 6.x, quit when a syntax file was already loaded.
if version < 600
syntax clear
elseif exists("b:current_syntax")
finish
endif
" Use all the stuff from the HTML syntax file.
if version < 600
source <sfile>:p:h/html.vim
else
runtime! syntax/html.vim
endif
" Tag names.
syn keyword cfTagName contained cfabort cfapplet cfapplication cfargument cfassociate cfbreak cfcache
syn keyword cfTagName contained cfcalendar cfcase cfcatch cfchart cfchartdata cfchartseries cfcol cfcollection
syn keyword cfTagName contained cfcomponent cfcontent cfcookie cfdefaultcase cfdirectory cfdocument
syn keyword cfTagName contained cfdocumentitem cfdocumentsection cfdump cfelse cfelseif cferror cfexecute
syn keyword cfTagName contained cfexit cffile cfflush cfform cfformgroup cfformitem cfftp cffunction cfgrid
syn keyword cfTagName contained cfgridcolumn cfgridrow cfgridupdate cfheader cfhtmlhead cfhttp cfhttpparam cfif
syn keyword cfTagName contained cfimport cfinclude cfindex cfinput cfinsert cfinvoke cfinvokeargument
syn keyword cfTagName contained cfldap cflocation cflock cflog cflogin cfloginuser cflogout cfloop cfmail
syn keyword cfTagName contained cfmailparam cfmailpart cfmodule cfNTauthenticate cfobject cfobjectcache
syn keyword cfTagName contained cfoutput cfparam cfpop cfprocessingdirective cfprocparam cfprocresult
syn keyword cfTagName contained cfproperty cfquery cfqueryparam cfregistry cfreport cfreportparam cfrethrow
syn keyword cfTagName contained cfreturn cfsavecontent cfschedule cfscript cfsearch cfselect cfset cfsetting
syn keyword cfTagName contained cfsilent cfslider cfstoredproc cfswitch cftable cftextarea cfthrow cftimer
syn keyword cfTagName contained cftrace cftransaction cftree cftreeitem cftry cfupdate cfwddx cfxml
" Tag parameters.
syn keyword cfArg contained abort accept access accessible action addnewline addtoken addtoken agentname
syn keyword cfArg contained align appendkey appletsource application applicationtimeout applicationtoken
syn keyword cfArg contained archive argumentcollection arguments asciiextensionlist attachmentpath
syn keyword cfArg contained attributecollection attributes attributes autowidth backgroundcolor
syn keyword cfArg contained backgroundvisible basetag bcc bgcolor bind bindingname blockfactor body bold
syn keyword cfArg contained border branch cachedafter cachedwithin casesensitive categories category
syn keyword cfArg contained categorytree cc cfsqltype charset chartheight chartwidth checked class
syn keyword cfArg contained clientmanagement clientstorage codebase colheaderalign colheaderbold
syn keyword cfArg contained colheaderfont colheaderfontsize colheaderitalic colheaders colheadertextcolor
syn keyword cfArg contained collection colorlist colspacing columns completepath component condition
syn keyword cfArg contained connection contentid context contextbytes contexthighlightbegin
syn keyword cfArg contained contexthighlightend contextpassages cookiedomain criteria custom1 custom2
syn keyword cfArg contained custom3 custom4 data dataalign databackgroundcolor datacollection
syn keyword cfArg contained datalabelstyle datasource date daynames dbname dbserver dbtype dbvarname debug
syn keyword cfArg contained default delete deletebutton deletefile delimiter delimiters description
syn keyword cfArg contained destination detail directory disabled display displayname disposition dn domain
syn keyword cfArg contained enablecab enablecfoutputonly enabled encoded encryption enctype enddate
syn keyword cfArg contained endrange endrow endtime entry errorcode exception existing expand expires
syn keyword cfArg contained expireurl expression extendedinfo extends extensions external failifexists
syn keyword cfArg contained failto file filefield filename filter firstdayofweek firstrowasheaders font
syn keyword cfArg contained fontbold fontembed fontitalic fontsize foregroundcolor format formfields
syn keyword cfArg contained formula from generateuniquefilenames getasbinary grid griddataalign gridlines
syn keyword cfArg contained groovecolor group groupcasesensitive header headeralign headerbold headerfont
syn keyword cfArg contained headerfontsize headeritalic headerlines headertextcolor height highlighthref
syn keyword cfArg contained hint href hrefkey hscroll hspace htmltable id idletimeout img imgopen imgstyle
syn keyword cfArg contained index inline input insert insertbutton interval isolation italic item
syn keyword cfArg contained itemcolumn key keyonly label labelformat language list listgroups locale
syn keyword cfArg contained localfile log loginstorage lookandfeel mailerid mailto marginbottom marginleft
syn keyword cfArg contained marginright marginright margintop markersize markerstyle mask maxlength maxrows
syn keyword cfArg contained message messagenumber method mimeattach mimetype mode modifytype monthnames
syn keyword cfArg contained multipart multiple name namecomplict nameconflict namespace new newdirectory
syn keyword cfArg contained notsupported null numberformat object omit onchange onclick onerror onkeydown
syn keyword cfArg contained onkeyup onload onmousedown onmouseup onreset onsubmit onvalidate operation
syn keyword cfArg contained orderby orientation output outputfile overwrite ownerpassword pageencoding
syn keyword cfArg contained pageheight pagetype pagewidth paintstyle param_1 param_2 param_3 param_4
syn keyword cfArg contained param_5 parent passive passthrough password path pattern permissions picturebar
syn keyword cfArg contained pieslicestyle port porttypename prefix preloader preservedata previouscriteria
syn keyword cfArg contained procedure protocol provider providerdsn proxybypass proxypassword proxyport
syn keyword cfArg contained proxyserver proxyuser publish query queryasroot queryposition range rebind
syn keyword cfArg contained recurse redirect referral refreshlabel remotefile replyto report requesttimeout
syn keyword cfArg contained required reset resolveurl result resultset retrycount returnasbinary returncode
syn keyword cfArg contained returntype returnvariable roles rowheaderalign rowheaderbold rowheaderfont
syn keyword cfArg contained rowheaderfontsize rowheaderitalic rowheaders rowheadertextcolor rowheaderwidth
syn keyword cfArg contained rowheight scale scalefrom scaleto scope scriptprotect scriptsrc secure
syn keyword cfArg contained securitycontext select selectcolor selected selecteddate selectedindex
syn keyword cfArg contained selectmode separator seriescolor serieslabel seriesplacement server serviceport
syn keyword cfArg contained serviceportname sessionmanagement sessiontimeout setclientcookies setcookie
syn keyword cfArg contained setdomaincookies show3d showborder showdebugoutput showerror showlegend
syn keyword cfArg contained showmarkers showxgridlines showygridlines size skin sort sortascendingbutton
syn keyword cfArg contained sortcontrol sortdescendingbutton sortxaxis source spoolenable sql src start
syn keyword cfArg contained startdate startrange startrow starttime status statuscode statust step
syn keyword cfArg contained stoponerror style subject suggestions suppresswhitespace tablename tableowner
syn keyword cfArg contained tablequalifier taglib target task template text textcolor textqualifier
syn keyword cfArg contained thread throwonerror throwonfailure throwontimeout time timeout timespan tipbgcolor tipstyle
syn keyword cfArg contained title to tooltip top toplevelvariable transfermode type uid unit url urlpath
syn keyword cfArg contained useragent username userpassword usetimezoneinfo validate validateat value
syn keyword cfArg contained valuecolumn values valuesdelimiter valuesdisplay var variable vertical visible
syn keyword cfArg contained vscroll vspace webservice width wmode wraptext wsdlfile xaxistitle xaxistype
syn keyword cfArg contained xoffset yaxistitle yaxistype yoffset
" ColdFusion Functions.
syn keyword cfFunctionName contained Abs GetFunctionList Max ACos GetGatewayHelper Mid AddSOAPRequestHeader
syn keyword cfFunctionName contained GetHttpRequestData Min AddSOAPResponseHeader GetHttpTimeString Minute
syn keyword cfFunctionName contained ArrayAppend GetLocale Month ArrayAvg GetLocaleDisplayName MonthAsString
syn keyword cfFunctionName contained ArrayClear GetMetaData Now ArrayDeleteAt GetMetricData NumberFormat
syn keyword cfFunctionName contained ArrayInsertAt GetPageContext ParagraphFormat ArrayIsEmpty GetProfileSections
syn keyword cfFunctionName contained ParseDateTime ArrayLen GetProfileString Pi ArrayMax GetSOAPRequest
syn keyword cfFunctionName contained PreserveSingleQuotes ArrayMin GetSOAPRequestHeader Quarter ArrayNew
syn keyword cfFunctionName contained GetSOAPResponse QueryAddColumn ArrayPrepend GetSOAPResponseHeader QueryAddRow
syn keyword cfFunctionName contained ArrayResize GetTempDirectory QueryNew ArraySet GetTempFile QuerySetCell
syn keyword cfFunctionName contained ArraySort GetTickCount QuotedValueList ArraySum GetTimeZoneInfo Rand ArraySwap
syn keyword cfFunctionName contained GetToken Randomize ArrayToList Hash RandRange Asc Hour REFind ASin
syn keyword cfFunctionName contained HTMLCodeFormat REFindNoCase Atn HTMLEditFormat ReleaseComObject BinaryDecode
syn keyword cfFunctionName contained IIf RemoveChars BinaryEncode IncrementValue RepeatString BitAnd InputBaseN
syn keyword cfFunctionName contained Replace BitMaskClear Insert ReplaceList BitMaskRead Int ReplaceNoCase
syn keyword cfFunctionName contained BitMaskSet IsArray REReplace BitNot IsBinary REReplaceNoCase BitOr IsBoolean
syn keyword cfFunctionName contained Reverse BitSHLN IsCustomFunction Right BitSHRN IsDate RJustify BitXor
syn keyword cfFunctionName contained IsDebugMode Round Ceiling IsDefined RTrim CharsetDecode IsLeapYear Second
syn keyword cfFunctionName contained CharsetEncode IsNumeric SendGatewayMessage Chr IsNumericDate SetEncoding
syn keyword cfFunctionName contained CJustify IsObject SetLocale Compare IsQuery SetProfileString CompareNoCase
syn keyword cfFunctionName contained IsSimpleValue SetVariable Cos IsSOAPRequest Sgn CreateDate IsStruct Sin
syn keyword cfFunctionName contained CreateDateTime IsUserInRole SpanExcluding CreateObject IsValid SpanIncluding
syn keyword cfFunctionName contained CreateODBCDate IsWDDX Sqr CreateODBCDateTime IsXML StripCR CreateODBCTime
syn keyword cfFunctionName contained IsXmlAttribute StructAppend CreateTime IsXmlDoc StructClear CreateTimeSpan
syn keyword cfFunctionName contained IsXmlElem StructCopy CreateUUID IsXmlNode StructCount DateAdd IsXmlRoot
syn keyword cfFunctionName contained StructDelete DateCompare JavaCast StructFind DateConvert JSStringFormat
syn keyword cfFunctionName contained StructFindKey DateDiff LCase StructFindValue DateFormat Left StructGet
syn keyword cfFunctionName contained DatePart Len StructInsert Day ListAppend StructIsEmpty DayOfWeek
syn keyword cfFunctionName contained ListChangeDelims StructKeyArray DayOfWeekAsString ListContains StructKeyExists
syn keyword cfFunctionName contained DayOfYear ListContainsNoCase StructKeyList DaysInMonth ListDeleteAt StructNew
syn keyword cfFunctionName contained DaysInYear ListFind StructSort DE ListFindNoCase StructUpdate DecimalFormat
syn keyword cfFunctionName contained ListFirst Tan DecrementValue ListGetAt TimeFormat Decrypt ListInsertAt
syn keyword cfFunctionName contained ToBase64 DeleteClientVariable ListLast ToBinary DirectoryExists ListLen
syn keyword cfFunctionName contained ToScript DollarFormat ListPrepend ToString Duplicate ListQualify Trim Encrypt
syn keyword cfFunctionName contained ListRest UCase Evaluate ListSetAt URLDecode Exp ListSort URLEncodedFormat
syn keyword cfFunctionName contained ExpandPath ListToArray URLSessionFormat FileExists ListValueCount Val Find
syn keyword cfFunctionName contained ListValueCountNoCase ValueList FindNoCase LJustify Week FindOneOf Log Wrap
syn keyword cfFunctionName contained FirstDayOfMonth Log10 WriteOutput Fix LSCurrencyFormat XmlChildPos FormatBaseN
syn keyword cfFunctionName contained LSDateFormat XmlElemNew GetTempDirectory LSEuroCurrencyFormat XmlFormat
syn keyword cfFunctionName contained GetAuthUser LSIsCurrency XmlGetNodeType GetBaseTagData LSIsDate XmlNew
syn keyword cfFunctionName contained GetBaseTagList LSIsNumeric XmlParse GetBaseTemplatePath LSNumberFormat
syn keyword cfFunctionName contained XmlSearch GetClientVariablesList LSParseCurrency XmlTransform
syn keyword cfFunctionName contained GetCurrentTemplatePath LSParseDateTime XmlValidate GetDirectoryFromPath
syn keyword cfFunctionName contained LSParseEuroCurrency Year GetEncoding LSParseNumber YesNoFormat GetException
syn keyword cfFunctionName contained LSTimeFormat GetFileFromPath LTrim
syn cluster htmlTagNameCluster add=cfTagName
syn cluster htmlArgCluster add=cfArg,cfFunctionName
syn region cfFunctionRegion start='#' end='#' contains=cfFunctionName
" Define the default highlighting.
" For version 5.x and earlier, only when not done already.
" For version 5.8 and later, only when an item doesn't have highlighting yet.
if version >= 508 || !exists("did_cf_syn_inits")
if version < 508
let did_cf_syn_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
HiLink cfTagName Statement
HiLink cfArg Type
HiLink cfFunctionName Function
HiLink cfFunctionRegion PreProc
delcommand HiLink
endif
let b:current_syntax = "cf"
" vim: ts=8 sw=2
" Vim syntax file
" Language: ColdFusion
" Maintainer: Toby Woodwark (toby.woodwark+vim@gmail.com)
" Last Change: 2005-11-02
" Filenames: *.cfc *.cfm
" Version: Macromedia ColdFusion MX 7
" Usage: Note that ColdFusion has its own comment syntax
" i.e. <!--- --->
" For version 5.x, clear all syntax items.
" For version 6.x+, quit if a syntax file is already loaded.
if version < 600
syntax clear
elseif exists("b:current_syntax")
finish
endif
" Use all the stuff from the HTML syntax file.
" TODO remove this; CFML is not a superset of HTML
if version < 600
source <sfile>:p:h/html.vim
else
runtime! syntax/html.vim
endif
syn sync fromstart
syn sync maxlines=200
syn case ignore
" Scopes and keywords.
syn keyword cfScope contained cgi cffile request caller this thistag cfcatch variables application server session client form url attributes arguments
syn keyword cfBool contained yes no true false
" Operator strings.
" Not exhaustive, since there are longhand equivalents.
syn keyword cfOperator contained xor eqv and or lt le lte gt ge gte eq neq not is mod contains
syn match cfOperatorMatch contained "[\+\-\*\/\\\^\&][\+\-\*\/\\\^\&]\@!"
syn cluster cfOperatorCluster contains=cfOperator,cfOperatorMatch
" Tag names.
syn keyword cfTagName contained cfabort cfapplet cfapplication cfargument cfassociate cfbreak cfcache
syn keyword cfTagName contained cfcalendar cfcase cfcatch cfchart cfchartdata cfchartseries cfcol cfcollection
syn keyword cfTagName contained cfcomponent cfcontent cfcookie cfdefaultcase cfdirectory cfdocument
syn keyword cfTagName contained cfdocumentitem cfdocumentsection cfdump cfelse cfelseif cferror cfexecute
syn keyword cfTagName contained cfexit cffile cfflush cfform cfformgroup cfformitem cfftp cffunction cfgrid
syn keyword cfTagName contained cfgridcolumn cfgridrow cfgridupdate cfheader cfhtmlhead cfhttp cfhttpparam cfif
syn keyword cfTagName contained cfimport cfinclude cfindex cfinput cfinsert cfinvoke cfinvokeargument
syn keyword cfTagName contained cfldap cflocation cflock cflog cflogin cfloginuser cflogout cfloop cfmail
syn keyword cfTagName contained cfmailparam cfmailpart cfmodule cfNTauthenticate cfobject cfobjectcache
syn keyword cfTagName contained cfoutput cfparam cfpop cfprocessingdirective cfprocparam cfprocresult
syn keyword cfTagName contained cfproperty cfquery cfqueryparam cfregistry cfreport cfreportparam cfrethrow
syn keyword cfTagName contained cfreturn cfsavecontent cfschedule cfscript cfsearch cfselect cfset cfsetting
syn keyword cfTagName contained cfsilent cfslider cfstoredproc cfswitch cftable cftextarea cfthrow cftimer
syn keyword cfTagName contained cftrace cftransaction cftree cftreeitem cftry cfupdate cfwddx cfxml
" Tag parameters.
syn keyword cfArg contained abort accept access accessible action addnewline addtoken addtoken agentname
syn keyword cfArg contained align appendkey appletsource application applicationtimeout applicationtoken
syn keyword cfArg contained archive argumentcollection arguments asciiextensionlist attachmentpath
syn keyword cfArg contained attributecollection attributes attributes autowidth backgroundcolor
syn keyword cfArg contained backgroundvisible basetag bcc bgcolor bind bindingname blockfactor body bold
syn keyword cfArg contained border branch cachedafter cachedwithin casesensitive categories category
syn keyword cfArg contained categorytree cc cfsqltype charset chartheight chartwidth checked class
syn keyword cfArg contained clientmanagement clientstorage codebase colheaderalign colheaderbold
syn keyword cfArg contained colheaderfont colheaderfontsize colheaderitalic colheaders colheadertextcolor
syn keyword cfArg contained collection colorlist colspacing columns completepath component condition
syn keyword cfArg contained connection contentid context contextbytes contexthighlightbegin
syn keyword cfArg contained contexthighlightend contextpassages cookiedomain criteria custom1 custom2
syn keyword cfArg contained custom3 custom4 data dataalign databackgroundcolor datacollection
syn keyword cfArg contained datalabelstyle datasource date daynames dbname dbserver dbtype dbvarname debug
syn keyword cfArg contained default delete deletebutton deletefile delimiter delimiters description
syn keyword cfArg contained destination detail directory disabled display displayname disposition dn domain
syn keyword cfArg contained enablecab enablecfoutputonly enabled encoded encryption enctype enddate
syn keyword cfArg contained endrange endrow endtime entry errorcode exception existing expand expires
syn keyword cfArg contained expireurl expression extendedinfo extends extensions external failifexists
syn keyword cfArg contained failto file filefield filename filter firstdayofweek firstrowasheaders font
syn keyword cfArg contained fontbold fontembed fontitalic fontsize foregroundcolor format formfields
syn keyword cfArg contained formula from generateuniquefilenames getasbinary grid griddataalign gridlines
syn keyword cfArg contained groovecolor group groupcasesensitive header headeralign headerbold headerfont
syn keyword cfArg contained headerfontsize headeritalic headerlines headertextcolor height highlighthref
syn keyword cfArg contained hint href hrefkey hscroll hspace htmltable id idletimeout img imgopen imgstyle
syn keyword cfArg contained index inline input insert insertbutton interval isolation italic item
syn keyword cfArg contained itemcolumn key keyonly label labelformat language list listgroups locale
syn keyword cfArg contained localfile log loginstorage lookandfeel mailerid mailto marginbottom marginleft
syn keyword cfArg contained marginright marginright margintop markersize markerstyle mask maxlength maxrows
syn keyword cfArg contained message messagenumber method mimeattach mimetype mode modifytype monthnames
syn keyword cfArg contained multipart multiple name namecomplict nameconflict namespace new newdirectory
syn keyword cfArg contained notsupported null numberformat object omit onchange onclick onerror onkeydown
syn keyword cfArg contained onkeyup onload onmousedown onmouseup onreset onsubmit onvalidate operation
syn keyword cfArg contained orderby orientation output outputfile overwrite ownerpassword pageencoding
syn keyword cfArg contained pageheight pagetype pagewidth paintstyle param_1 param_2 param_3 param_4
syn keyword cfArg contained param_5 parent passive passthrough password path pattern permissions picturebar
syn keyword cfArg contained pieslicestyle port porttypename prefix preloader preservedata previouscriteria
syn keyword cfArg contained procedure protocol provider providerdsn proxybypass proxypassword proxyport
syn keyword cfArg contained proxyserver proxyuser publish query queryasroot queryposition range rebind
syn keyword cfArg contained recurse redirect referral refreshlabel remotefile replyto report requesttimeout
syn keyword cfArg contained required reset resolveurl result resultset retrycount returnasbinary returncode
syn keyword cfArg contained returntype returnvariable roles rowheaderalign rowheaderbold rowheaderfont
syn keyword cfArg contained rowheaderfontsize rowheaderitalic rowheaders rowheadertextcolor rowheaderwidth
syn keyword cfArg contained rowheight scale scalefrom scaleto scope scriptprotect scriptsrc secure
syn keyword cfArg contained securitycontext select selectcolor selected selecteddate selectedindex
syn keyword cfArg contained selectmode separator seriescolor serieslabel seriesplacement server serviceport
syn keyword cfArg contained serviceportname sessionmanagement sessiontimeout setclientcookies setcookie
syn keyword cfArg contained setdomaincookies show3d showborder showdebugoutput showerror showlegend
syn keyword cfArg contained showmarkers showxgridlines showygridlines size skin sort sortascendingbutton
syn keyword cfArg contained sortcontrol sortdescendingbutton sortxaxis source spoolenable sql src start
syn keyword cfArg contained startdate startrange startrow starttime status statuscode statustext step
syn keyword cfArg contained stoponerror style subject suggestions suppresswhitespace tablename tableowner
syn keyword cfArg contained tablequalifier taglib target task template text textcolor textqualifier
syn keyword cfArg contained thread throwonerror throwonfailure throwontimeout time timeout timespan tipbgcolor tipstyle
syn keyword cfArg contained title to tooltip top toplevelvariable transfermode type uid unit url urlpath
syn keyword cfArg contained useragent username userpassword usetimezoneinfo validate validateat value
syn keyword cfArg contained valuecolumn values valuesdelimiter valuesdisplay var variable vertical visible
syn keyword cfArg contained vscroll vspace webservice width wmode wraptext wsdlfile xaxistitle xaxistype
syn keyword cfArg contained xoffset yaxistitle yaxistype yoffset
" ColdFusion Functions.
syn keyword cfFunctionName contained Abs GetFunctionList Max ACos GetGatewayHelper Mid AddSOAPRequestHeader
syn keyword cfFunctionName contained GetHttpRequestData Min AddSOAPResponseHeader GetHttpTimeString Minute
syn keyword cfFunctionName contained ArrayAppend GetLocale Month ArrayAvg GetLocaleDisplayName MonthAsString
syn keyword cfFunctionName contained ArrayClear GetMetaData Now ArrayDeleteAt GetMetricData NumberFormat
syn keyword cfFunctionName contained ArrayInsertAt GetPageContext ParagraphFormat ArrayIsEmpty GetProfileSections
syn keyword cfFunctionName contained ParseDateTime ArrayLen GetProfileString Pi ArrayMax GetSOAPRequest
syn keyword cfFunctionName contained PreserveSingleQuotes ArrayMin GetSOAPRequestHeader Quarter ArrayNew
syn keyword cfFunctionName contained GetSOAPResponse QueryAddColumn ArrayPrepend GetSOAPResponseHeader QueryAddRow
syn keyword cfFunctionName contained ArrayResize GetTempDirectory QueryNew ArraySet GetTempFile QuerySetCell
syn keyword cfFunctionName contained ArraySort GetTickCount QuotedValueList ArraySum GetTimeZoneInfo Rand ArraySwap
syn keyword cfFunctionName contained GetToken Randomize ArrayToList Hash RandRange Asc Hour REFind ASin
syn keyword cfFunctionName contained HTMLCodeFormat REFindNoCase Atn HTMLEditFormat ReleaseComObject BinaryDecode
syn keyword cfFunctionName contained IIf RemoveChars BinaryEncode IncrementValue RepeatString BitAnd InputBaseN
syn keyword cfFunctionName contained Replace BitMaskClear Insert ReplaceList BitMaskRead Int ReplaceNoCase
syn keyword cfFunctionName contained BitMaskSet IsArray REReplace BitNot IsBinary REReplaceNoCase BitOr IsBoolean
syn keyword cfFunctionName contained Reverse BitSHLN IsCustomFunction Right BitSHRN IsDate RJustify BitXor
syn keyword cfFunctionName contained IsDebugMode Round Ceiling IsDefined RTrim CharsetDecode IsLeapYear Second
syn keyword cfFunctionName contained CharsetEncode IsNumeric SendGatewayMessage Chr IsNumericDate SetEncoding
syn keyword cfFunctionName contained CJustify IsObject SetLocale Compare IsQuery SetProfileString CompareNoCase
syn keyword cfFunctionName contained IsSimpleValue SetVariable Cos IsSOAPRequest Sgn CreateDate IsStruct Sin
syn keyword cfFunctionName contained CreateDateTime IsUserInRole SpanExcluding CreateObject IsValid SpanIncluding
syn keyword cfFunctionName contained CreateODBCDate IsWDDX Sqr CreateODBCDateTime IsXML StripCR CreateODBCTime
syn keyword cfFunctionName contained IsXmlAttribute StructAppend CreateTime IsXmlDoc StructClear CreateTimeSpan
syn keyword cfFunctionName contained IsXmlElem StructCopy CreateUUID IsXmlNode StructCount DateAdd IsXmlRoot
syn keyword cfFunctionName contained StructDelete DateCompare JavaCast StructFind DateConvert JSStringFormat
syn keyword cfFunctionName contained StructFindKey DateDiff LCase StructFindValue DateFormat Left StructGet
syn keyword cfFunctionName contained DatePart Len StructInsert Day ListAppend StructIsEmpty DayOfWeek
syn keyword cfFunctionName contained ListChangeDelims StructKeyArray DayOfWeekAsString ListContains StructKeyExists
syn keyword cfFunctionName contained DayOfYear ListContainsNoCase StructKeyList DaysInMonth ListDeleteAt StructNew
syn keyword cfFunctionName contained DaysInYear ListFind StructSort DE ListFindNoCase StructUpdate DecimalFormat
syn keyword cfFunctionName contained ListFirst Tan DecrementValue ListGetAt TimeFormat Decrypt ListInsertAt
syn keyword cfFunctionName contained ToBase64 DeleteClientVariable ListLast ToBinary DirectoryExists ListLen
syn keyword cfFunctionName contained ToScript DollarFormat ListPrepend ToString Duplicate ListQualify Trim Encrypt
syn keyword cfFunctionName contained ListRest UCase Evaluate ListSetAt URLDecode Exp ListSort URLEncodedFormat
syn keyword cfFunctionName contained ExpandPath ListToArray URLSessionFormat FileExists ListValueCount Val Find
syn keyword cfFunctionName contained ListValueCountNoCase ValueList FindNoCase LJustify Week FindOneOf Log Wrap
syn keyword cfFunctionName contained FirstDayOfMonth Log10 WriteOutput Fix LSCurrencyFormat XmlChildPos FormatBaseN
syn keyword cfFunctionName contained LSDateFormat XmlElemNew GetTempDirectory LSEuroCurrencyFormat XmlFormat
syn keyword cfFunctionName contained GetAuthUser LSIsCurrency XmlGetNodeType GetBaseTagData LSIsDate XmlNew
syn keyword cfFunctionName contained GetBaseTagList LSIsNumeric XmlParse GetBaseTemplatePath LSNumberFormat
syn keyword cfFunctionName contained XmlSearch GetClientVariablesList LSParseCurrency XmlTransform
syn keyword cfFunctionName contained GetCurrentTemplatePath LSParseDateTime XmlValidate GetDirectoryFromPath
syn keyword cfFunctionName contained LSParseEuroCurrency Year GetEncoding LSParseNumber YesNoFormat GetException
syn keyword cfFunctionName contained LSTimeFormat GetFileFromPath LTrim
syn cluster htmlTagNameCluster add=cfTagName
syn cluster htmlArgCluster add=cfArg,cfHashRegion,cfScope
syn cluster htmlPreproc add=cfHashRegion
syn cluster cfExpressionCluster contains=cfFunctionName,cfScope,@cfOperatorCluster,cfScriptStringD,cfScriptStringS,cfScriptNumber,cfBool
" Evaluation; skip strings ( this helps with cases like nested IIf() )
syn region cfHashRegion start=+#+ skip=+"[^"]*"\|'[^']*'+ end=+#+ contains=@cfExpressionCluster,cfScriptParenError
" <cfset>, <cfif>, <cfelseif>, <cfreturn> are analogous to hashmarks (implicit evaluation) and has 'var'
syn region cfSetRegion start="<cfset " start="<cfreturn " start="<cfelseif " start="<cfif " end='>' keepend contains=@cfExpressionCluster,cfSetLHSRegion,cfSetTagEnd,cfScriptType
syn region cfSetLHSRegion contained start="<cfreturn" start="<cfelseif" start="<cfif" start="<cfset" end=" " keepend contains=cfTagName,htmlTag
syn match cfSetTagEnd contained '>'
" CF comments: similar to SGML comments
syn region cfComment start='<!---' end='--->' keepend contains=cfCommentTodo
syn keyword cfCommentTodo contained TODO FIXME XXX TBD WTF
" CFscript
syn match cfScriptLineComment contained "\/\/.*$" contains=cfCommentTodo
syn region cfScriptComment contained start="/\*" end="\*/" contains=cfCommentTodo
" in CF, quotes are escaped by doubling
syn region cfScriptStringD contained start=+"+ skip=+\\\\\|""+ end=+"+ extend contains=@htmlPreproc,cfHashRegion
syn region cfScriptStringS contained start=+'+ skip=+\\\\\|''+ end=+'+ extend contains=@htmlPreproc,cfHashRegion
syn match cfScriptNumber contained "-\=\<\d\+L\=\>"
syn keyword cfScriptConditional contained if else
syn keyword cfScriptRepeat contained while for in
syn keyword cfScriptBranch contained break switch case try catch continue
syn keyword cfScriptFunction contained function
syn keyword cfScriptType contained var
syn match cfScriptBraces contained "[{}]"
syn keyword cfScriptStatement contained return
syn cluster cfScriptCluster contains=cfScriptParen,cfScriptLineComment,cfScriptComment,cfScriptStringD,cfScriptStringS,cfScriptFunction,cfScriptNumber,cfScriptRegexpString,cfScriptBoolean,cfScriptBraces,cfHashRegion,cfFunctionName,cfScope,@cfOperatorCluster,cfScriptConditional,cfScriptRepeat,cfScriptBranch,cfScriptType,@cfExpressionCluster,cfScriptStatement
" Errors caused by wrong parenthesis; skip strings
syn region cfScriptParen contained transparent skip=+"[^"]*"\|'[^']*'+ start=+(+ end=+)+ contains=@cfScriptCluster
syn match cfScrParenError contained +)+
syn region cfscriptBlock matchgroup=NONE start="<cfscript>" end="<\/cfscript>"me=s-1 keepend contains=@cfScriptCluster,cfscriptTag,cfScrParenError
syn region cfscriptTag contained start='<cfscript' end='>' keepend contains=cfTagName,htmlTag
" Define the default highlighting.
if version >= 508 || !exists("did_cf_syn_inits")
if version < 508
let did_cf_syn_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
HiLink cfTagName Statement
HiLink cfArg Type
HiLink cfFunctionName Function
HiLink cfHashRegion PreProc
HiLink cfComment Comment
HiLink cfCommentTodo Todo
HiLink cfOperator Operator
HiLink cfOperatorMatch Operator
HiLink cfScope Title
HiLink cfBool Constant
HiLink cfscriptBlock Special
HiLink cfscriptTag htmlTag
HiLink cfSetRegion PreProc
HiLink cfSetLHSRegion htmlTag
HiLink cfSetTagEnd htmlTag
HiLink cfScriptLineComment Comment
HiLink cfScriptComment Comment
HiLink cfScriptStringS String
HiLink cfScriptStringD String
HiLink cfScriptNumber cfScriptValue
HiLink cfScriptConditional Conditional
HiLink cfScriptRepeat Repeat
HiLink cfScriptBranch Conditional
HiLink cfScriptType Type
HiLink cfScriptStatement Statement
HiLink cfScriptBraces Function
HiLink cfScriptFunction Function
HiLink cfScriptError Error
HiLink cfScrParenError cfScriptError
delcommand HiLink
endif
let b:current_syntax = "cf"
" vim: ts=8 sw=2

View file

@ -2,7 +2,7 @@
" Language: Cascading Style Sheets
" Maintainer: Claudio Fleiner <claudio@fleiner.com>
" URL: http://www.fleiner.com/vim/syntax/css.vim
" Last Change: 2004 Mar 30
" Last Change: 2005 Nov 23
" CSS2 by Nikolai Weibull
" Full CSS2, HTML4 support by Yeti
@ -38,7 +38,12 @@ syn match cssSelectorOp "[+>.]"
syn match cssSelectorOp2 "[~|]\?=" contained
syn region cssAttributeSelector matchgroup=cssSelectorOp start="\[" end="]" transparent contains=cssUnicodeEscape,cssSelectorOp2,cssStringQ,cssStringQQ
try
syn match cssIdentifier "#[A-Za-zÀ-ÿ_@][A-Za-zÀ-ÿ0-9_@-]*"
catch /^.*/
syn match cssIdentifier "#[A-Za-z_@][A-Za-z0-9_@-]*"
endtry
syn match cssMedia "@media\>" nextgroup=cssMediaType skipwhite skipnl
syn keyword cssMediaType contained screen print aural braile embosed handheld projection ty tv all nextgroup=cssMediaComma,cssMediaBlock skipwhite skipnl
@ -270,5 +275,6 @@ if main_syntax == 'css'
unlet main_syntax
endif
" vim: ts=8

View file

@ -1,9 +1,12 @@
" Vim syntax file for the D programming language (version 0.116).
" Vim syntax file for the D programming language (version 0.137).
"
" Language: D
" Maintainer: Jason Mills<jmills@cs.mun.ca>
" Last Change: 2005 Mar 09
" Version: 0.12
" Last Change: 2005 Oct 29
" Version: 0.14
"
" Please email me with bugs, comments, and suggestion. Put vim in the subject
" to ensure the email will not be marked has spam.
"
" Options:
" d_comment_strings - set to highlight strings and numbers in comments
@ -21,6 +24,8 @@
"
" - Mark contents of the asm statement body as special
"
" - Highlight the string prefix r and and postfixes c,w,d
"
" Quit when a syntax file was already loaded
if exists("b:current_syntax")
@ -30,7 +35,7 @@ endif
" Keyword definitions
"
syn keyword dExternal import package module extern
syn keyword dConditional if else switch
syn keyword dConditional if else switch iftype
syn keyword dBranch goto break continue
syn keyword dRepeat while for do foreach
syn keyword dBoolean true false
@ -41,7 +46,7 @@ syn keyword dStructure template interface class enum struct union
syn keyword dOperator new delete typeof typeid cast align is
syn keyword dOperator this super
if exists("d_hl_operator_overload")
syn keyword dOpOverload opNeg opCom opPostInc opPostDec opAdd opSub opSub_r
syn keyword dOpOverload opNeg opCom opPostInc opPostDec opCast opAdd opSub opSub_r
syn keyword dOpOverload opMul opDiv opDiv_r opMod opMod_r opAnd opOr opXor
syn keyword dOpOverload opShl opShl_r opShr opShr_r opUShr opUShr_r opCat
syn keyword dOpOverload opCat_r opEquals opEquals opCmp opCmp opCmp opCmp
@ -49,7 +54,7 @@ if exists("d_hl_operator_overload")
syn keyword dOpOverload opModAssign opAndAssign opOrAssign opXorAssign
syn keyword dOpOverload opShlAssign opShrAssign opUShrAssign opCatAssign
syn keyword dOpOverload opIndex opIndexAssign opCall opSlice opPos
syn keyword dOpOverload opAdd_r opMul_r opAnd_r opOr_r opXor_r
syn keyword dOpOverload opAdd_r opMul_r opAnd_r opOr_r opXor_r
endif
syn keyword dType ushort int uint long ulong float
syn keyword dType void byte ubyte double bit char wchar ucent cent
@ -135,7 +140,7 @@ syn match dUnicode "\\u\d\{4\}"
"
syn region dString start=+"+ end=+"+ contains=dEscSequence,@Spell
syn region dRawString start=+`+ skip=+\\`+ end=+`+ contains=@Spell
syn region dRawString start=+r"+ skip=+\\"+ end=+"+ contains=@Spell
"syn region dRawString start=+r"+ skip=+\\"+ end=+"+ contains=@Spell
syn region dHexString start=+x"+ skip=+\\"+ end=+"+
" Numbers
@ -220,4 +225,4 @@ hi def link dPragma PreProc
let b:current_syntax = "d"
" vim: ts=8
" vim: ts=8 noet

View file

@ -2,14 +2,9 @@
" Language: eRuby
" Maintainer: Doug Kearns <djkea2 at gus.gscit.monash.edu.au>
" Info: $Id$
" URL: http://vim-ruby.sourceforge.net
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" ----------------------------------------------------------------------------
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded

View file

@ -2,7 +2,7 @@
" Language: Java
" Maintainer: Claudio Fleiner <claudio@fleiner.com>
" URL: http://www.fleiner.com/vim/syntax/java.vim
" Last Change: 2004 Nov 12
" Last Change: 2005 Nov 04
" Please check :help java.vim for comments on some of the options available.
@ -58,8 +58,11 @@ syn match javaTypedef "\.\s*\<class\>"ms=s+1
syn keyword javaClassDecl enum
syn match javaClassDecl "^class\>"
syn match javaClassDecl "[^.]\s*\<class\>"ms=s+1
syn match javaAnnotation "@[_$a-zA-Z][_$a-zA-Z0-9_]*\>"
syn match javaClassDecl "@interface\>"
syn keyword javaBranch break continue nextgroup=javaUserLabelRef skipwhite
syn match javaUserLabelRef "\k\+" contained
syn match javaVarArg "\.\.\."
syn keyword javaScopeDecl public protected private abstract
if exists("java_highlight_java_lang_ids") || exists("java_highlight_java_lang") || exists("java_highlight_all")
@ -130,7 +133,7 @@ if !exists("java_allow_cpp_keywords")
endif
" The following cluster contains all java groups except the contained ones
syn cluster javaTop add=javaExternal,javaError,javaError,javaBranch,javaLabelRegion,javaLabel,javaConditional,javaRepeat,javaBoolean,javaConstant,javaTypedef,javaOperator,javaType,javaType,javaStatement,javaStorageClass,javaAssert,javaExceptions,javaMethodDecl,javaClassDecl,javaClassDecl,javaClassDecl,javaScopeDecl,javaError,javaError2,javaUserLabel,javaLangObject
syn cluster javaTop add=javaExternal,javaError,javaError,javaBranch,javaLabelRegion,javaLabel,javaConditional,javaRepeat,javaBoolean,javaConstant,javaTypedef,javaOperator,javaType,javaType,javaStatement,javaStorageClass,javaAssert,javaExceptions,javaMethodDecl,javaClassDecl,javaClassDecl,javaClassDecl,javaScopeDecl,javaError,javaError2,javaUserLabel,javaLangObject,javaAnnotation,javaVarArg
" Comments
@ -283,6 +286,7 @@ if version >= 508 || !exists("did_java_syn_inits")
let did_java_syn_inits = 1
endif
JavaHiLink javaFuncDef Function
JavaHiLink javaVarArg Function
JavaHiLink javaBraces Function
JavaHiLink javaBranch Conditional
JavaHiLink javaUserLabelRef javaUserLabel
@ -314,6 +318,7 @@ if version >= 508 || !exists("did_java_syn_inits")
JavaHiLink javaConstant Constant
JavaHiLink javaTypedef Typedef
JavaHiLink javaTodo Todo
JavaHiLink javaAnnotation PreProc
JavaHiLink javaCommentTitle SpecialComment
JavaHiLink javaDocTags Special

View file

@ -1,8 +1,13 @@
" Vim syntax file
" Language: JavaScript
" Maintainer: Claudio Fleiner <claudio@fleiner.com>
" Updaters: Scott Shattuck (ss) <ss@technicalpursuit.com>
" URL: http://www.fleiner.com/vim/syntax/javascript.vim
" Last Change: 2005 Jul 13
" Changes: (ss) added keywords, reserved words, and other identifiers
" (ss) repaired several quoting and grouping glitches
" (ss) fixed regex parsing issue with multiple qualifiers [gi]
" (ss) additional factoring of keywords, globals, and members
" Last Change: 2005 Nov 12 (ss)
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
@ -27,23 +32,33 @@ syn case ignore
syn keyword javaScriptCommentTodo TODO FIXME XXX TBD contained
syn match javaScriptLineComment "\/\/.*$" contains=javaScriptCommentTodo
syn match javaScriptLineComment "\/\/.*" contains=javaScriptCommentTodo
syn match javaScriptCommentSkip "^[ \t]*\*\($\|[ \t]\+\)"
syn region javaScriptComment start="/\*" end="\*/" contains=javaScriptCommentTodo
syn match javaScriptSpecial "\\\d\d\d\|\\."
syn region javaScriptStringD start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=javaScriptSpecial,@htmlPreproc
syn region javaScriptStringS start=+'+ skip=+\\\\\|\\'+ end=+'+ contains=javaScriptSpecial,@htmlPreproc
syn region javaScriptStringD start=+"+ skip=+\\\\\|\\"+ end=+"\|$+ contains=javaScriptSpecial,@htmlPreproc
syn region javaScriptStringS start=+'+ skip=+\\\\\|\\'+ end=+'\|$+ contains=javaScriptSpecial,@htmlPreproc
syn match javaScriptSpecialCharacter "'\\.'"
syn match javaScriptNumber "-\=\<\d\+L\=\>\|0[xX][0-9a-fA-F]\+\>"
syn region javaScriptRegexpString start=+/[^/*]+me=e-1 skip=+\\\\\|\\/+ end=+/[gi]\?\s*$+ end=+/[gi]\?\s*[;.,)]+me=e-1 contains=@htmlPreproc oneline
syn keyword javaScriptConditional if else
syn keyword javaScriptRepeat while for
syn keyword javaScriptBranch break continue switch case default
syn keyword javaScriptOperator new in
syn keyword javaScriptType this var const
syn region javaScriptRegexpString start=+/[^/*]+me=e-1 skip=+\\\\\|\\/+ end=+/[gi]\{0,2\}\s*$+ end=+/[gi]\{0,2\}\s*[;.,)]+me=e-1 contains=@htmlPreproc oneline
syn keyword javaScriptConditional if else switch
syn keyword javaScriptRepeat while for do in
syn keyword javaScriptBranch break continue
syn keyword javaScriptOperator new delete instanceof typeof
syn keyword javaScriptType Array Boolean Date Function Number Object String RegExp
syn keyword javaScriptStatement return with
syn keyword javaScriptBoolean true false
syn keyword javaScriptNull null
syn keyword javaScriptNull null undefined
syn keyword javaScriptIdentifier arguments this var
syn keyword javaScriptLabel case default
syn keyword javaScriptException try catch finally throw
syn keyword javaScriptMessage alert confirm prompt status
syn keyword javaScriptGlobal self window top parent
syn keyword javaScriptMember document event location
syn keyword javaScriptDeprecated escape unescape
syn keyword javaScriptReserved abstract boolean byte char class const debugger double enum export extends final float goto implements import int interface long native package private protected public short static super synchronized throws transient volatile
if exists("javaScript_fold")
syn match javaScriptFunction "\<function\>"
@ -56,17 +71,13 @@ if exists("javaScript_fold")
setlocal foldtext=getline(v:foldstart)
else
syn keyword javaScriptFunction function
syn match javaScriptBraces "[{}]"
syn match javaScriptBraces "[{}\[\]]"
syn match javaScriptParens "[()]"
endif
syn sync fromstart
syn sync maxlines=100
" catch errors caused by wrong parenthesis
syn region javaScriptParen transparent start="(" end=")" contains=javaScriptParen,javaScriptComment,javaScriptSpecial,javaScriptStringD,javaScriptStringS,javaScriptSpecialCharacter,javaScriptNumber,javaScriptRegexpString,javaScriptBoolean,javaScriptBraces,javaScriptFunction,javaScriptFunctionFold,javaScriptConditional,javaScriptRepeat,javaScriptBranch,javaScriptOperator,javaScriptType,javaScriptStatement,javaScriptBoolean,javaScriptConstant
" syn region javaScriptParen transparent start="(" end=")" contains=javaScriptParen,javaScriptComment,javaScriptSpecial,javaScriptStringD,javaScriptStringS,javaScriptSpecialCharacter,javaScriptNumber,javaScriptRegexpString,javaScriptBoolean,javaScriptBraces
syn match javaScrParenError ")"
if main_syntax == "javascript"
syn sync ccomment javaScriptComment
endif
@ -103,6 +114,18 @@ if version >= 508 || !exists("did_javascript_syn_inits")
HiLink javaScriptNull Keyword
HiLink javaScriptBoolean Boolean
HiLink javaScriptRegexpString String
HiLink javaScriptIdentifier Identifier
HiLink javaScriptLabel Label
HiLink javaScriptException Exception
HiLink javaScriptMessage Keyword
HiLink javaScriptGlobal Keyword
HiLink javaScriptMember Keyword
HiLink javaScriptDeprecated Exception
HiLink javaScriptReserved Keyword
HiLink javaScriptDebug Debug
HiLink javaScriptConstant Label
delcommand HiLink
endif

View file

@ -2,19 +2,13 @@
" Language: Lisp
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: Oct 12, 2005
" Version: 16
" Version: 17a
" URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
"
" Thanks to F Xavier Noria for a list of 978 Common Lisp symbols
" taken from the HyperSpec
"
" Options:
" g:lisp_instring : if it exists, then "(...") strings are highlighted
" as if the contents were lisp. Useful for AutoLisp.
" Put
" let g:lisp_instring=1
" into your <.vimrc> if you want this option.
" ---------------------------------------------------------------------
" Load Once: {{{1
" For vim-version 5.x: Clear all syntax items
" For vim-version 6.x: Quit when a syntax file was already loaded
@ -30,6 +24,7 @@ else
set iskeyword=42,43,45,47-58,60-62,64-90,97-122,_
endif
" ---------------------------------------------------------------------
" Clusters: {{{1
syn cluster lispAtomCluster contains=lispAtomBarSymbol,lispAtomList,lispAtomNmbr0,lispComment,lispDecl,lispFunc,lispLeadWhite
syn cluster lispBaseListCluster contains=lispAtom,lispAtomBarSymbol,lispAtomMark,lispBQList,lispBarSymbol,lispComment,lispConcat,lispDecl,lispFunc,lispKey,lispList,lispNumber,lispSpecial,lispSymbol,lispVar,lispLeadWhite
@ -39,6 +34,7 @@ else
syn cluster lispListCluster contains=@lispBaseListCluster,lispString
endif
" ---------------------------------------------------------------------
" Lists: {{{1
syn match lispSymbol contained ![^()'`,"; \t]\+!
syn match lispBarSymbol contained !|..\{-}|!
@ -58,6 +54,7 @@ else
syn region lispBQList matchgroup=PreProc start="`(" skip="|.\{-}|" matchgroup=PreProc end=")" contains=@lispListCluster
endif
" ---------------------------------------------------------------------
" Atoms: {{{1
syn match lispAtomMark "'"
syn match lispAtom "'("me=e-1 contains=lispAtomMark nextgroup=lispAtomList
@ -68,6 +65,7 @@ syn region lispAtomList contained matchgroup=Special start="(" s
syn match lispAtomNmbr contained "\<\d\+"
syn match lispLeadWhite contained "^\s\+"
" ---------------------------------------------------------------------
" Standard Lisp Functions and Macros: {{{1
syn keyword lispFunc * find-method pprint-indent
syn keyword lispFunc ** find-package pprint-linear
@ -386,6 +384,7 @@ syn keyword lispFunc find-if-not pprint-fill
syn match lispFunc "\<c[ad]\+r\>"
" ---------------------------------------------------------------------
" Lisp Keywords (modifiers): {{{1
syn keyword lispKey :abort :from-end :overwrite
syn keyword lispKey :adjustable :gensym :predicate
@ -414,6 +413,7 @@ syn keyword lispKey :error :output :verbose
syn keyword lispKey :escape :output-file :version
syn keyword lispKey :external
" ---------------------------------------------------------------------
" Standard Lisp Variables: {{{1
syn keyword lispVar *applyhook* *load-pathname* *print-pprint-dispatch*
syn keyword lispVar *break-on-signals* *load-print* *print-pprint-dispatch*
@ -434,6 +434,7 @@ syn keyword lispVar *evalhook* *print-lines* *standard-output*
syn keyword lispVar *features* *print-miser-width* *terminal-io*
syn keyword lispVar *gensym-counter* *print-miser-width* *trace-output*
" ---------------------------------------------------------------------
" Strings: {{{1
syn region lispString start=+"+ skip=+\\\\\|\\"+ end=+"+
if exists("g:lisp_instring")
@ -441,6 +442,7 @@ if exists("g:lisp_instring")
syn region lispInStringString start=+\\"+ skip=+\\\\+ end=+\\"+ contained
endif
" ---------------------------------------------------------------------
" Shared with Xlisp, Declarations, Macros, Functions: {{{1
syn keyword lispDecl defmacro do-all-symbols labels
syn keyword lispDecl defsetf do-external-symbols let
@ -448,6 +450,7 @@ syn keyword lispDecl deftype do-symbols locally
syn keyword lispDecl defun dotimes macrolet
syn keyword lispDecl do* flet multiple-value-bind
" ---------------------------------------------------------------------
" Numbers: supporting integers and floating point numbers {{{1
syn match lispNumber "-\=\(\.\d\+\|\d\+\(\.\d*\)\=\)\(e[-+]\=\d\+\)\="
@ -463,6 +466,7 @@ syn match lispSpecial !#([^()'`,"; \t]\+)!
syn match lispConcat "\s\.\s"
syn match lispParenError ")"
" ---------------------------------------------------------------------
" Comments: {{{1
syn cluster lispCommentGroup contains=lispTodo,@Spell
syn match lispComment ";.*$" contains=@lispCommentGroup
@ -471,19 +475,16 @@ syn case ignore
syn keyword lispTodo contained combak combak: todo todo:
syn case match
" ---------------------------------------------------------------------
" Synchronization: {{{1
syn sync lines=100
" ---------------------------------------------------------------------
" Define Highlighting: {{{1
" For version 5.7 and earlier: only when not done already
" For version 5.8 and later: only when an item doesn't have highlighting yet
if version >= 508 || !exists("did_lisp_syntax_inits")
if version < 508
let did_lisp_syntax_inits = 1
command -nargs=+ HiLink hi link <args>
else
command -nargs=+ HiLink hi def link <args>
endif
if version >= 508
command -nargs=+ HiLink hi def link <args>
HiLink lispCommentRegion lispComment
HiLink lispAtomNmbr lispNumber
@ -508,27 +509,27 @@ if version >= 508 || !exists("did_lisp_syntax_inits")
if exists("g:lisp_rainbow") && g:lisp_rainbow != 0
if &bg == "dark"
hi hlLevel0 ctermfg=red guifg=red1
hi hlLevel1 ctermfg=yellow guifg=orange1
hi hlLevel2 ctermfg=green guifg=yellow1
hi hlLevel3 ctermfg=cyan guifg=greenyellow
hi hlLevel4 ctermfg=magenta guifg=green1
hi hlLevel5 ctermfg=red guifg=springgreen1
hi hlLevel6 ctermfg=yellow guifg=cyan1
hi hlLevel7 ctermfg=green guifg=slateblue1
hi hlLevel8 ctermfg=cyan guifg=magenta1
hi hlLevel9 ctermfg=magenta guifg=purple1
hi def hlLevel0 ctermfg=red guifg=red1
hi def hlLevel1 ctermfg=yellow guifg=orange1
hi def hlLevel2 ctermfg=green guifg=yellow1
hi def hlLevel3 ctermfg=cyan guifg=greenyellow
hi def hlLevel4 ctermfg=magenta guifg=green1
hi def hlLevel5 ctermfg=red guifg=springgreen1
hi def hlLevel6 ctermfg=yellow guifg=cyan1
hi def hlLevel7 ctermfg=green guifg=slateblue1
hi def hlLevel8 ctermfg=cyan guifg=magenta1
hi def hlLevel9 ctermfg=magenta guifg=purple1
else
hi hlLevel0 ctermfg=red guifg=red3
hi hlLevel1 ctermfg=darkyellow guifg=orangered3
hi hlLevel2 ctermfg=darkgreen guifg=orange2
hi hlLevel3 ctermfg=blue guifg=yellow3
hi hlLevel4 ctermfg=darkmagenta guifg=olivedrab4
hi hlLevel5 ctermfg=red guifg=green4
hi hlLevel6 ctermfg=darkyellow guifg=paleturquoise3
hi hlLevel7 ctermfg=darkgreen guifg=deepskyblue4
hi hlLevel8 ctermfg=blue guifg=darkslateblue
hi hlLevel9 ctermfg=darkmagenta guifg=darkviolet
hi def hlLevel0 ctermfg=red guifg=red3
hi def hlLevel1 ctermfg=darkyellow guifg=orangered3
hi def hlLevel2 ctermfg=darkgreen guifg=orange2
hi def hlLevel3 ctermfg=blue guifg=yellow3
hi def hlLevel4 ctermfg=darkmagenta guifg=olivedrab4
hi def hlLevel5 ctermfg=red guifg=green4
hi def hlLevel6 ctermfg=darkyellow guifg=paleturquoise3
hi def hlLevel7 ctermfg=darkgreen guifg=deepskyblue4
hi def hlLevel8 ctermfg=blue guifg=darkslateblue
hi def hlLevel9 ctermfg=darkmagenta guifg=darkviolet
endif
endif
@ -537,4 +538,5 @@ endif
let b:current_syntax = "lisp"
" ---------------------------------------------------------------------
" vim: ts=8 nowrap fdm=marker

View file

@ -1,7 +1,8 @@
" MUSHcode syntax file
" Maintainer: Bek Oberin <gossamer@tertius.net.au>
" Last updated by Rimnal on Mon Aug 20 08:28:56 MDT 2001
" Maintainer: Rick Bird <nveid@nveid.com>
" Based on vim Syntax file by: Bek Oberin <gossamer@tertius.net.au>
" Last Updated: Fri Nov 04 20:28:15 2005
"
" For version 5.x: Clear all syntax items
" For version 6.x: Quit when a syntax file was already loaded
if version < 600
@ -12,57 +13,115 @@ endif
" regular mush functions
syntax keyword mushFunction contained abs acos add after and andflags aposs
syntax keyword mushFunction contained asin atan before capstr cat ceil center
syntax keyword mushFunction contained comp con conn controls convsecs convtime
syntax keyword mushFunction contained cos default delete dist2d dist3d div e
syntax keyword mushFunction contained edefault edit elements elock eq escape
syntax keyword mushFunction contained exit exp extract fdiv filter first flags
syntax keyword mushFunction contained floor fold foreach findable fullname get
syntax keyword mushFunction contained get_eval grab gt gte hasattr hasflag
syntax keyword mushFunction contained home idle index insert isdbref isnum
syntax keyword mushFunction contained isword iter last lattr lcon lcstr
syntax keyword mushFunction contained ldelete left lexits ljust ln lnum loc
syntax keyword mushFunction contained locate lock log lpos lt lte lwho map
syntax keyword mushFunction contained match matchall max member merge mid min
syntax keyword mushFunction contained mix mod money mudname mul munge name
syntax keyword mushFunction contained nearby neq next not num obj objeval
syntax keyword mushFunction contained objmem or orflags owner parent parse pi
syntax keyword mushFunction contained ports pos poss power r rand remove repeat
syntax keyword mushFunction contained replace rest reverse revwords right
syntax keyword mushFunction contained rjust rloc room round s scramble search
syntax keyword mushFunction contained secs secure setdiff setinter setq
syntax keyword mushFunction contained setunion shuffle sign sin sort sortby
syntax keyword mushFunction contained space splice sqrt squish starttime stats
syntax keyword mushFunction contained strlen strmatch sub subj switch tan time
syntax keyword mushFunction contained trim trunc type u ucstr udefault ulocal
syntax keyword mushFunction contained v version visible where wordpos words
syntax keyword mushFunction contained xcon xor
" only highligh functions when they have an in-bracket immediately after
syntax match mushFunctionBrackets "\i\I*(" contains=mushFunction
syntax keyword mushFunction contained @@ abs accent accname acos add after align
syntax keyword mushFunction contained allof alphamax alphamin and andflags
syntax keyword mushFunction contained andlflags andlpowers andpowers ansi aposs art
syntax keyword mushFunction contained asin atan atan2 atrlock attrcnt band baseconv
syntax keyword mushFunction contained beep before blank2tilde bnand bnot bor bound
syntax keyword mushFunction contained brackets break bxor cand cansee capstr case
syntax keyword mushFunction contained caseall cat ceil center checkpass children
syntax keyword mushFunction contained chr clone cmds cnetpost comp con config conn
syntax keyword mushFunction contained controls convsecs convtime convutcsecs cor
syntax keyword mushFunction contained cos create ctime ctu dec decrypt default
syntax keyword mushFunction contained delete die dig digest dist2d dist3d div
syntax keyword mushFunction contained division divscope doing downdiv dynhelp e
syntax keyword mushFunction contained edefault edit element elements elist elock
syntax keyword mushFunction contained emit empire empower encrypt endtag entrances
syntax keyword mushFunction contained eq escape etimefmt eval exit exp extract fdiv
syntax keyword mushFunction contained filter filterbool findable first firstof
syntax keyword mushFunction contained flags flip floor floordiv fmod fold
syntax keyword mushFunction contained folderstats followers following foreach
syntax keyword mushFunction contained fraction fullname functions get get_eval grab
syntax keyword mushFunction contained graball grep grepi gt gte hasattr hasattrp
syntax keyword mushFunction contained hasattrpval hasattrval hasdivpower hasflag
syntax keyword mushFunction contained haspower haspowergroup hastype height hidden
syntax keyword mushFunction contained home host hostname html idle idlesecs
syntax keyword mushFunction contained idle_average idle_times idle_total if ifelse
syntax keyword mushFunction contained ilev iname inc index indiv indivall insert
syntax keyword mushFunction contained inum ipaddr isdaylight isdbref isint isnum
syntax keyword mushFunction contained isword itemize items iter itext last lattr
syntax keyword mushFunction contained lcon lcstr ldelete ldivisions left lemit
syntax keyword mushFunction contained level lexits lflags link list lit ljust lmath
syntax keyword mushFunction contained ln lnum loc localize locate lock loctree log
syntax keyword mushFunction contained lparent lplayers lports lpos lsearch lsearchr
syntax keyword mushFunction contained lstats lt lte lthings lvcon lvexits lvplayers
syntax keyword mushFunction contained lvthings lwho mail maildstats mailfrom
syntax keyword mushFunction contained mailfstats mailstats mailstatus mailsubject
syntax keyword mushFunction contained mailtime map match matchall max mean median
syntax keyword mushFunction contained member merge mid min mix mod modulo modulus
syntax keyword mushFunction contained money mtime mudname mul munge mwho name nand
syntax keyword mushFunction contained nattr ncon nearby neq nexits next nor not
syntax keyword mushFunction contained nplayers nsemit nslemit nsoemit nspemit
syntax keyword mushFunction contained nsremit nszemit nthings null num nvcon
syntax keyword mushFunction contained nvexits nvplayers nvthings obj objeval objid
syntax keyword mushFunction contained objmem oemit ooref open or ord orflags
syntax keyword mushFunction contained orlflags orlpowers orpowers owner parent
syntax keyword mushFunction contained parse pcreate pemit pi pickrand playermem
syntax keyword mushFunction contained pmatch poll ports pos poss power powergroups
syntax keyword mushFunction contained powers powover program prompt pueblo quitprog
syntax keyword mushFunction contained quota r rand randword recv regedit regeditall
syntax keyword mushFunction contained regeditalli regediti regmatch regmatchi
syntax keyword mushFunction contained regrab regraball regraballi regrabi regrep
syntax keyword mushFunction contained regrepi remainder remit remove repeat replace
syntax keyword mushFunction contained rest restarts restarttime reswitch
syntax keyword mushFunction contained reswitchall reswitchalli reswitchi reverse
syntax keyword mushFunction contained revwords right rjust rloc rnum room root
syntax keyword mushFunction contained round s scan scramble search secs secure sent
syntax keyword mushFunction contained set setdiff setinter setq setr setunion sha0
syntax keyword mushFunction contained shl shr shuffle sign signal sin sort sortby
syntax keyword mushFunction contained soundex soundlike soundslike space spellnum
syntax keyword mushFunction contained splice sql sqlescape sqrt squish ssl
syntax keyword mushFunction contained starttime stats stddev step strcat strinsert
syntax keyword mushFunction contained stripaccents stripansi strlen strmatch
syntax keyword mushFunction contained strreplace sub subj switch switchall t table
syntax keyword mushFunction contained tag tagwrap tan tel terminfo textfile
syntax keyword mushFunction contained tilde2blank time timefmt timestring tr
syntax keyword mushFunction contained trigger trim trimpenn trimtiny trunc type u
syntax keyword mushFunction contained ucstr udefault ufun uldefault ulocal updiv
syntax keyword mushFunction contained utctime v vadd val valid vcross vdim vdot
syntax keyword mushFunction contained version visible vmag vmax vmin vmul vsub
syntax keyword mushFunction contained vtattr vtcount vtcreate vtdestroy vtlcon
syntax keyword mushFunction contained vtloc vtlocate vtmaster vtname vtref vttel
syntax keyword mushFunction contained vunit wait where width wipe wordpos words
syntax keyword mushFunction contained wrap xcon xexits xget xor xplayers xthings
syntax keyword mushFunction contained xvcon xvexits xvplayers xvthings zemit zfun
syntax keyword mushFunction contained zmwho zone zwho
" only highligh functions when they have an in-bracket immediately after
syntax match mushFunctionBrackets "\i*(" contains=mushFunction
"
" regular mush commands
syntax keyword mushAtCommandList contained @alias @chown @clone @create
syntax keyword mushAtCommandList contained @decompile @destroy @doing @dolist
syntax keyword mushAtCommandList contained @drain @edit @emit @entrances @femit
syntax keyword mushAtCommandList contained @force @fpose @fsay @halt @last
syntax keyword mushAtCommandList contained @link @list @listmotd @lock @mudwho
syntax keyword mushAtCommandList contained @mvattr @name @notify @oemit @parent
syntax keyword mushAtCommandList contained @password @pemit @ps @quota @robot
syntax keyword mushAtCommandList contained @search @set @stats @sweep @switch
syntax keyword mushAtCommandList contained @teleport @trigger @unlink @unlock
syntax keyword mushAtCommandList contained @verb @wait @wipe
syntax keyword mushAtCommandList contained @ALLHALT @ALLQUOTA @ASSERT @ATRCHOWN @ATRLOCK @ATTRIBUTE @BOOT
syntax keyword mushAtCommandList contained @BREAK @CEMIT @CHANNEL @CHAT @CHOWN @CHOWNALL @CHZONE @CHZONEALL
syntax keyword mushAtCommandList contained @CLOCK @CLONE @COBJ @COMMAND @CONFIG @CPATTR @CREATE @CRPLOG @DBCK
syntax keyword mushAtCommandList contained @DECOMPILE @DESTROY @DIG @DISABLE @DIVISION @DOING @DOLIST @DRAIN
syntax keyword mushAtCommandList contained @DUMP @EDIT @ELOCK @EMIT @EMPOWER @ENABLE @ENTRANCES @EUNLOCK @FIND
syntax keyword mushAtCommandList contained @FIRSTEXIT @FLAG @FORCE @FUNCTION @EDIT @GREP @HALT @HIDE @HOOK @KICK
syntax keyword mushAtCommandList contained @LEMIT @LEVEL @LINK @LIST @LISTMOTD @LOCK @LOG @LOGWIPE @LSET @MAIL @MALIAS
syntax keyword mushAtCommandList contained @MAP @MOTD @MVATTR @NAME @NEWPASSWORD @NOTIFY @NSCEMIT @NSEMIT @NSLEMIT
syntax keyword mushAtCommandList contained @NSOEMIT @NSPEMIT @NSPEMIT @NSREMIT @NSZEMIT @NUKE @OEMIT @OPEN @PARENT @PASSWORD
syntax keyword mushAtCommandList contained @PCREATE @PEMIT @POLL @POOR @POWERLEVEL @PROGRAM @PROMPT @PS @PURGE @QUOTA
syntax keyword mushAtCommandList contained @READCACHE @RECYCLE @REJECTMOTD @REMIT @RESTART @SCAN @SEARCH @SELECT @SET
syntax keyword mushAtCommandList contained @SHUTDOWN @SITELOCK @SNOOP @SQL @SQUOTA @STATS @SWITCH @SWEEP @SWITCH @TELEPORT
syntax keyword mushAtCommandList contained @TRIGGER @ULOCK @UNDESTROY @UNLINK @UNLOCK @UNRECYCLE @UPTIME @UUNLOCK @VERB
syntax keyword mushAtCommandList contained @VERSION @WAIT @WALL @WARNINGS @WCHECK @WHEREIS @WIPE @ZCLONE @ZEMIT
syntax match mushCommand "@\i\I*" contains=mushAtCommandList
syntax keyword mushCommand drop enter examine get give goto help inventory
syntax keyword mushCommand kill leave look news page pose say score use
syntax keyword mushCommand version whisper DOING LOGOUT OUTPUTPREFIX
syntax keyword mushCommand OUTPUTSUFFIX QUIT SESSION WHO
syntax keyword mushCommand AHELP ANEWS ATTRIB_SET BRIEF BRIEF BUY CHANGES DESERT
syntax keyword mushCommand DISMISS DROP EMPTY ENTER EXAMINE FOLLOW GET GIVE GOTO
syntax keyword mushCommand HELP HUH_COMMAND INVENTORY INVENTORY LOOK LEAVE LOOK
syntax keyword mushCommand GOTO NEWS PAGE PAGE POSE RULES SAY SCORE SEMIPOSE
syntax keyword mushCommand SPECIALNEWS TAKE TEACH THINK UNFOLLOW USE WHISPER WHISPER
syntax keyword mushCommand WARN_ON_MISSING WHISPER WITH
syntax match mushSpecial "\*\|!\|=\|-\|\\\|+"
syntax match mushSpecial2 contained "\*"
syn region mushString start=+L\="+ skip=+\\\\\|\\"+ end=+"+ contains=mushSpecial,mushSpecial2,@Spell
syntax match mushIdentifier "&[^ ]\+"
syntax match mushVariable "%r\|%t\|%cr\|%[A-Za-z0-9]\+\|%#\|##\|here"
@ -73,9 +132,32 @@ syntax match mushNumber +[0-9]\++
" A comment line starts with a or # or " at the start of the line
" or an @@
syntax keyword mushTodo contained TODO FIXME XXX
syntax match mushComment +^\s*@@.*$+ contains=mushTodo
syntax match mushComment +^".*$+ contains=mushTodo
syntax match mushComment +^#.*$+ contains=mushTodo
syntax cluster mushCommentGroup contains=mushTodo
syntax match mushComment "^\s*@@.*$" contains=mushTodo
syntax match mushComment "^#[^define|^ifdef|^else|^pragma|^ifndef|^echo|^elif|^undef|^warning].*$" contains=mushTodo
syntax match mushComment "^#$" contains=mushTodo
syntax region mushComment matchgroup=mushCommentStart start="/@@" end="@@/" contains=@mushCommentGroup,mushCommentStartError,mushCommentString,@Spell
syntax region mushCommentString contained start=+L\=\\\@<!"+ skip=+\\\\\|\\"+ end=+"+ end=+@@/+me=s-1 contains=mushCommentSkip
syntax match mushCommentSkip contained "^\s*@@\($\|\s\+\)"
syntax match mushCommentStartError display "/@@"me=e-1 contained
" syntax match mushComment +^".*$+ contains=mushTodo
" Work on this one
" syntax match mushComment +^#.*$+ contains=mushTodo
syn region mushPreCondit start="^\s*\(%:\|#\)\s*\(if\|ifdef\|ifndef\|elif\)\>" skip="\\$" end="$" end="//"me=s-1 contains=mushComment
syn match mushPreCondit display "^\s*\(%:\|#\)\s*\(else\|endif\)\>"
syn cluster mushPreProcGroup contains=mushPreCondit,mushIncluded,mushInclude,mushDefine,mushSpecial,mushString,mushCommentSkip,mushCommentString,@mushCommentGroup,mushCommentStartError
syn region mushIncluded display contained start=+"+ skip=+\\\\\|\\"+ end=+"+
syn match mushIncluded display contained "<[^>]*>"
syn match mushInclude display "^\s*\(%:\|#\)\s*include\>\s*["<]" contains=mushIncluded
syn region mushDefine start="^\s*\(%:\|#\)\s*\(define\|undef\)\>" skip="\\$" end="$" end="//"me=s-1 contains=ALLBUT,@mushPreProcGroup,@Spell
syn region mushPreProc start="^\s*\(%:\|#\)\s*\(pragma\>\|line\>\|warning\>\|warn\>\|error\>\)" skip="\\$" end="$" keepend contains=ALLBUT,@mushPreProcGroup
syntax region mushFuncBoundaries start="\[" end="\]" contains=mushFunction,mushFlag,mushAttributes,mushNumber,mushCommand,mushVariable,mushSpecial2
@ -114,7 +196,6 @@ if version >= 508 || !exists("did_mush_syntax_inits")
" The default methods for highlighting. Can be overridden later
HiLink mushAttribute Constant
HiLink mushCommand Function
HiLink mushComment Comment
HiLink mushNumber Number
HiLink mushSetting PreProc
HiLink mushFunction Statement
@ -123,6 +204,20 @@ if version >= 508 || !exists("did_mush_syntax_inits")
HiLink mushTodo Todo
HiLink mushFlag Special
HiLink mushIdentifier Identifier
HiLink mushDefine Macro
HiLink mushPreProc PreProc
HiLink mushPreProcGroup PreProc
HiLink mushPreCondit PreCondit
HiLink mushIncluded cString
HiLink mushInclude Include
" Comments
HiLink mushCommentStart mushComment
HiLink mushComment Comment
HiLink mushCommentString mushString
delcommand HiLink
endif

View file

@ -1,7 +1,7 @@
" Vim syntax file
" Language: Perl
" Maintainer: Nick Hibma <n_hibma@van-laarhoven.org>
" Last Change: 2005 Oct 06
" Last Change: 2005 October 18
" Location: http://www.van-laarhoven.org/vim/syntax/perl.vim
"
" Please download most recent version first before mailing
@ -47,18 +47,18 @@ if exists("perl_include_pod")
syn include @Pod syntax/pod.vim
unlet b:current_syntax
if exists("perl_fold")
syn region perlPOD start="^=[a-z]" end="^=cut" contains=@Pod,perlTodo keepend fold
syn region perlPOD start="^=[a-z]" end="^=cut" contains=@Pod,@Spell,perlTodo keepend fold
syn region perlPOD start="^=cut" end="^=cut" contains=perlTodo keepend fold
else
syn region perlPOD start="^=[a-z]" end="^=cut" contains=@Pod,perlTodo keepend
syn region perlPOD start="^=[a-z]" end="^=cut" contains=@Pod,@Spell,perlTodo keepend
syn region perlPOD start="^=cut" end="^=cut" contains=perlTodo keepend
endif
else
" Use only the bare minimum of rules
if exists("perl_fold")
syn region perlPOD start="^=[a-z]" end="^=cut" fold
syn region perlPOD start="^=[a-z]" end="^=cut" contains=@Spell fold
else
syn region perlPOD start="^=[a-z]" end="^=cut"
syn region perlPOD start="^=[a-z]" end="^=cut" contains=@Spell
endif
endif
@ -87,8 +87,8 @@ else
endif
syn keyword perlOperator defined undef and or not bless ref
if exists("perl_fold")
" if BEGIN/END would be a keyword the perlBEGINENDFold does not work
syn match perlControl "\<BEGIN\|CHECK\|INIT\|END\>" contained
" if BEGIN/END is a keyword the perlBEGINENDFold does not work
syn match perlControl "\<BEGIN\|END\|CHECK\|INIT\>" contained
else
syn keyword perlControl BEGIN END CHECK INIT
endif
@ -108,8 +108,8 @@ syn keyword perlStatementFiles chdir chmod chown chroot glob link mkdir readlin
syn match perlStatementFiles "-[rwxoRWXOezsfdlpSbctugkTBMAC]\>"
syn keyword perlStatementFlow caller die dump eval exit wantarray
syn keyword perlStatementInclude require
syn match perlStatementInclude "\(use\|no\)\s\+\(integer\>\|strict\>\|lib\>\|sigtrap\>\|subs\>\|vars\>\|warnings\>\|utf8\>\|byte\>\)\="
syn keyword perlStatementScope import
syn match perlStatementInclude "\<\(use\|no\)\s\+\(\(attributes\|autouse\|base\|big\(int\|num\|rat\)\|blib\|bytes\|charnames\|constant\|diagnostics\|encoding\|fields\|filetest\|if\|integer\|less\|lib\|locale\|open\|ops\|overload\|re\|sigtrap\|sort\|strict\|subs\|threads\(::shared\)\=\|utf8\|vars\|vmsish\|warnings\(::register\)\=\)\>\)\="
syn keyword perlStatementProc alarm exec fork getpgrp getppid getpriority kill pipe setpgrp setpriority sleep system times wait waitpid
syn keyword perlStatementSocket accept bind connect getpeername getsockname getsockopt listen recv send setsockopt shutdown socket socketpair
syn keyword perlStatementIPC msgctl msgget msgrcv msgsnd semctl semget semop shmctl shmget shmread shmwrite
@ -118,8 +118,11 @@ syn keyword perlStatementPword getpwuid getpwnam getpwent setpwent endpwent get
syn keyword perlStatementTime gmtime localtime time times
syn keyword perlStatementMisc warn formline reset scalar delete prototype lock
syn keyword perlStatementNew new
if !exists("perl_no_semi_keywords")
syn keyword perlStatementScope import
syn keyword perlStatementNew new
syn keyword perlStatementCarp carp confess croak
endif
syn keyword perlTodo TODO TBD FIXME XXX contained
" Perl Identifiers.
@ -134,14 +137,16 @@ syn keyword perlTodo TODO TBD FIXME XXX contained
" Special variables first ($^A, ...) and ($|, $', ...)
syn match perlVarPlain "$^[ADEFHILMOPSTWX]\="
syn match perlVarPlain "$[\\\"\[\]'&`+*.,;=%~!?@$<>(-]"
syn match perlVarPlain "$\(0\|[1-9][0-9]*\)"
syn match perlVarPlain "$[\\\"\[\]'&`+*.,;=%~?@$<>(-]"
syn match perlVarPlain "$\(0\|[1-9]\d*\)"
" Same as above, but avoids confusion in $::foo (equivalent to $main::foo)
syn match perlVarPlain "$:[^:]"
" These variables are not recognized within matches.
syn match perlVarNotInMatches "$[|)]"
" This variable is not recognized within matches delimited by m//.
" This variable is not recognized within matches delimited by '/'.
syn match perlVarSlash "$/"
" This variable is not recognized within matches delimited by '!'.
syn match perlVarBang "$!"
" And plain identifiers
syn match perlPackageRef "\(\h\w*\)\=\(::\|'\)\I"me=e-1 contained
@ -159,7 +164,7 @@ else
endif
if !exists("perl_no_extended_vars")
syn cluster perlExpr contains=perlStatementScalar,perlStatementRegexp,perlStatementNumeric,perlStatementList,perlStatementHash,perlStatementFiles,perlStatementTime,perlStatementMisc,perlVarPlain,perlVarNotInMatches,perlVarSlash,perlVarBlock,perlShellCommand,perlFloat,perlNumber,perlStringUnexpanded,perlString,perlQQ
syn cluster perlExpr contains=perlStatementScalar,perlStatementRegexp,perlStatementNumeric,perlStatementList,perlStatementHash,perlStatementFiles,perlStatementTime,perlStatementMisc,perlVarPlain,perlVarNotInMatches,perlVarSlash,perlVarBang,perlVarBlock,perlShellCommand,perlFloat,perlNumber,perlStringUnexpanded,perlString,perlQQ
syn region perlVarBlock matchgroup=perlVarPlain start="\($#\|[@%$]\)\$*{" skip="\\}" end="}" contains=@perlExpr nextgroup=perlVarMember,perlVarSimpleMember
syn region perlVarBlock matchgroup=perlVarPlain start="&\$*{" skip="\\}" end="}" contains=@perlExpr
syn match perlVarPlain "\\\=\(\$#\|[@%&$]\)\$*{\I\i*}" nextgroup=perlVarMember,perlVarSimpleMember
@ -174,17 +179,18 @@ endif
syn match perlFiledescRead "[<]\h\w\+[>]"
syn match perlFiledescStatementComma "(\=\s*\u\w*\s*,"me=e-1 transparent contained contains=perlFiledescStatement
syn match perlFiledescStatementNocomma "(\=\s*\u\w*\s*[^, \t]"me=e-1 transparent contained contains=perlFiledescStatement
syn match perlFiledescStatementNocomma "(\=\s*\u\w*\s*[^,[:space:]]"me=e-1 transparent contained contains=perlFiledescStatement
syn match perlFiledescStatement "\u\w*" contained
" Special characters in strings and matches
syn match perlSpecialString "\\\(\d\+\|[xX]\x\+\|c\u\|.\)" contained
syn match perlSpecialStringU "\\['\\]" contained
syn match perlSpecialMatch "{\d\+\(,\(\d\+\)\=\)\=}" contained
syn match perlSpecialMatch "{\d\+\(,\d*\)\=}" contained
syn match perlSpecialMatch "\[\(\]\|-\)\=[^\[\]]*\(\[\|\-\)\=\]" contained
syn match perlSpecialMatch "[+*()?.]" contained
syn match perlSpecialMatch "(?[#:=!]" contained
syn match perlSpecialMatch "(?<[=!]" contained
syn match perlSpecialMatch "(?[imsx]\+)" contained
" FIXME the line below does not work. It should mark end of line and
" begin of line as perlSpecial.
@ -201,13 +207,13 @@ syn match perlNotEmptyLine "^\s\+$" contained
" Variable interpolation
"
" These items are interpolated inside "" strings and similar constructs.
syn cluster perlInterpDQ contains=perlSpecialString,perlVarPlain,perlVarNotInMatches,perlVarSlash,perlVarBlock
syn cluster perlInterpDQ contains=perlSpecialString,perlVarPlain,perlVarNotInMatches,perlVarSlash,perlVarBang,perlVarBlock
" These items are interpolated inside '' strings and similar constructs.
syn cluster perlInterpSQ contains=perlSpecialStringU
" These items are interpolated inside m// matches and s/// substitutions.
syn cluster perlInterpSlash contains=perlSpecialString,perlSpecialMatch,perlVarPlain,perlVarBlock,perlSpecialBEOM
" These items are interpolated inside m## matches and s### substitutions.
syn cluster perlInterpMatch contains=@perlInterpSlash,perlVarSlash
syn cluster perlInterpMatch contains=@perlInterpSlash,perlVarSlash,perlVarBang
" Shell commands
syn region perlShellCommand matchgroup=perlMatchStartEnd start="`" end="`" contains=@perlInterpDQ
@ -233,8 +239,7 @@ syn region perlMatch matchgroup=perlMatchStartEnd start=+[m!]!+ end=+![cgimosx]*
" Below some hacks to recognise the // variant. This is virtually impossible to catch in all
" cases as the / is used in so many other ways, but these should be the most obvious ones.
"syn region perlMatch matchgroup=perlMatchStartEnd start=+^split /+lc=5 start=+[^$@%]\<split /+lc=6 start=+^if /+lc=2 start=+[^$@%]if /+lc=3 start=+[!=]\~\s*/+lc=2 start=+[(~]/+lc=1 start=+\.\./+lc=2 start=+\s/[^= \t0-9$@%]+lc=1,me=e-1,rs=e-1 start=+^/+ skip=+\\/+ end=+/[cgimosx]*+ contains=@perlInterpSlash
syn region perlMatch matchgroup=perlMatchStartEnd start=+^split /+lc=5 start=+[^$@%]\<split /+lc=6 start=+^while /+lc=5 start=+[^$@%]while /+lc=6 start=+^if /+lc=2 start=+[^$@%]if /+lc=3 start=+[!=]\~\s*/+lc=2 start=+[(~]/+lc=1 start=+\.\./+lc=2 start=+\s/[^= \t0-9$@%]+lc=1,me=e-1,rs=e-1 start=+^/+ skip=+\\/+ end=+/[cgimosx]*+ contains=@perlInterpSlash
syn region perlMatch matchgroup=perlMatchStartEnd start=+^split /+lc=5 start=+[^$@%&]\<split /+lc=6 start=+^while /+lc=5 start=+[^$@%&]while /+lc=6 start=+^if /+lc=2 start=+[^$@%&]if /+lc=3 start=+[!=]\~\s*/+lc=2 start=+[(~]/+lc=1 start=+\.\./+lc=2 start=+\s/[^=[:space:][:digit:]$@%&]+lc=1,me=e-1,rs=e-1 start=+^/+ skip=+\\/+ end=+/[cgimosx]*+ contains=@perlInterpSlash
" Substitutions
@ -253,7 +258,7 @@ syn region perlSubstitutionHash matchgroup=perlMatchStartEnd start=+#+ end=+#[
syn region perlSubstitutionBracket matchgroup=perlMatchStartEnd start=+\[+ end=+\][ecgimosx]*+ contained contains=@perlInterpDQ
syn region perlSubstitutionCurly matchgroup=perlMatchStartEnd start=+{+ end=+}[ecgimosx]*+ contained contains=@perlInterpDQ
" A special case for m!!x which allows for comments and extra whitespace in the pattern
" A special case for s!!!x which allows for comments and extra whitespace in the pattern
syn region perlMatch matchgroup=perlMatchStartEnd start=+\<s!+ end=+!+me=e-1 contains=@perlInterpSlash,perlComment nextgroup=perlSubstitutionPling
syn region perlSubstitutionPling matchgroup=perlMatchStartEnd start=+!+ end=+![ecgimosx]*+ contained contains=@perlInterpDQ
@ -280,24 +285,24 @@ syn match perlString "\<\I\i*\s*=>"me=e-2
" Strings and q, qq, qw and qr expressions
" Brackets in qq()
syn region perlBrackets start=+(+ end=+)+ contained transparent contains=perlBrackets,@perlStringSQ
" Parentheses in qq()
syn region perlParens start=+(+ end=+)+ contained transparent contains=perlParens,@perlStringSQ
syn region perlStringUnexpanded matchgroup=perlStringStartEnd start="'" end="'" contains=@perlInterpSQ
syn region perlString matchgroup=perlStringStartEnd start=+"+ end=+"+ contains=@perlInterpDQ
syn region perlStringUnexpanded matchgroup=perlStringStartEnd start="'" end="'" contains=@Spell,@perlInterpSQ
syn region perlString matchgroup=perlStringStartEnd start=+"+ end=+"+ contains=@Spell,@perlInterpDQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q#+ end=+#+ contains=@perlInterpSQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q|+ end=+|+ contains=@perlInterpSQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q(+ end=+)+ contains=@perlInterpSQ,perlBrackets
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q(+ end=+)+ contains=@perlInterpSQ,perlParens
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q{+ end=+}+ contains=@perlInterpSQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q/+ end=+/+ contains=@perlInterpSQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q[qx]#+ end=+#+ contains=@perlInterpDQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q[qx]|+ end=+|+ contains=@perlInterpDQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q[qx](+ end=+)+ contains=@perlInterpDQ,perlBrackets
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q[qx](+ end=+)+ contains=@perlInterpDQ,perlParens
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q[qx]{+ end=+}+ contains=@perlInterpDQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<q[qx]/+ end=+/+ contains=@perlInterpDQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<qw#+ end=+#+ contains=@perlInterpSQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<qw|+ end=+|+ contains=@perlInterpSQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<qw(+ end=+)+ contains=@perlInterpSQ,perlBrackets
syn region perlQQ matchgroup=perlStringStartEnd start=+\<qw(+ end=+)+ contains=@perlInterpSQ,perlParens
syn region perlQQ matchgroup=perlStringStartEnd start=+\<qw{+ end=+}+ contains=@perlInterpSQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<qw/+ end=+/+ contains=@perlInterpSQ
syn region perlQQ matchgroup=perlStringStartEnd start=+\<qr#+ end=+#[imosx]*+ contains=@perlInterpMatch
@ -362,7 +367,7 @@ endif
" All other # are comments, except ^#!
syn match perlComment "#.*" contains=perlTodo
syn match perlComment "#.*" contains=@Spell,perlTodo
syn match perlSharpBang "^#!.*"
" Formats
@ -391,8 +396,8 @@ if exists("perl_fold")
syn region perlBEGINENDFold start="^\z(\s*\)\<\(BEGIN\|END\|CHECK\|INIT\)\>.*[^};]$" end="^\z1}\s*$" transparent fold keepend
if exists("perl_fold_blocks")
syn region perlIfFold start="^\z(\s*\)\(if\|unless\|for\|while\|until\)\s*(.*)\s*{\s*$" start="^\z(\s*\)foreach\s*\(\(my\|our\)\=\s*\S\+\s*\)\=(.*)\s*{\s*$" end="^\z1}\s*;\=$" transparent fold keepend
syn region perlIfFold start="^\z(\s*\)do\s*{\s*$" end="^\z1}\s*while" end="^\z1}\s*;\=$" transparent fold keepend
syn region perlIfFold start="^\z(\s*\)\(if\|unless\|for\|while\|until\)\s*(.*)\(\s*{\)\=\s*$" start="^\z(\s*\)foreach\s*\(\(my\|our\)\=\s*\S\+\s*\)\=(.*)\(\s*{\)\=\s*$" start="\z(\s*\)else\s*{\s*$" end="^\z1}\s*;\=$" transparent fold keepend
syn region perlIfFold start="^\z(\s*\)do\(\s*{\)\=\s*$" end="^\z1}\s*while" end="^\z1}\s*;\=$" transparent fold keepend
endif
setlocal foldmethod=syntax
@ -445,6 +450,7 @@ if version >= 508 || !exists("did_perl_syn_inits")
HiLink perlVarSimpleMemberName perlString
HiLink perlVarNotInMatches perlIdentifier
HiLink perlVarSlash perlIdentifier
HiLink perlVarBang perlIdentifier
HiLink perlQQ perlString
if version >= 600
HiLink perlHereDoc perlString
@ -454,7 +460,7 @@ if version >= 508 || !exists("did_perl_syn_inits")
HiLink perlUntilEOFSQ perlString
HiLink perlUntilEmptyDQ perlString
HiLink perlUntilEmptySQ perlString
HiLink perlUntilEOF perlString
HiLink perlUntilEOF perlString
endif
HiLink perlStringUnexpanded perlString
HiLink perlSubstitutionSQ perlString
@ -490,7 +496,7 @@ if version >= 508 || !exists("did_perl_syn_inits")
HiLink perlStatementFiles perlStatement
HiLink perlStatementFlow perlStatement
HiLink perlStatementScope perlStatement
HiLink perlStatementInclude perlStatement
HiLink perlStatementInclude perlInclude
HiLink perlStatementProc perlStatement
HiLink perlStatementSocket perlStatement
HiLink perlStatementIPC perlStatement
@ -511,9 +517,9 @@ if version >= 508 || !exists("did_perl_syn_inits")
HiLink perlSpecialMatch perlSpecial
HiLink perlSpecialBEOM perlSpecial
HiLink perlDATA perlComment
HiLink perlBrackets Error
HiLink perlParens Error
" Possible errors
HiLink perlNotEmptyLine Error
HiLink perlElseIfError Error

View file

@ -2,14 +2,8 @@
" Language: Ruby
" Maintainer: Doug Kearns <djkea2 at gus.gscit.monash.edu.au>
" Info: $Id$
" URL: http://vim-ruby.sourceforge.net
" URL: http://vim-ruby.rubyforge.org
" Anon CVS: See above site
" Licence: GPL (http://www.gnu.org)
" Disclaimer:
" This program is distributed in the hope that it will be useful,
" but WITHOUT ANY WARRANTY; without even the implied warranty of
" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
" GNU General Public License for more details.
" ----------------------------------------------------------------------------
"
" Previous Maintainer: Mirko Nasato

View file

@ -2,21 +2,22 @@
" Language: shell (sh) Korn shell (ksh) bash (sh)
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Previous Maintainer: Lennart Schultz <Lennart.Schultz@ecmwf.int>
" Last Change: Sep 06, 2005
" Version: 77
" Last Change: Oct 18, 2005
" Version: 78
" URL: http://mysite.verizon.net/astronaut/vim/index.html#vimlinks_syntax
"
" Using the following VIM variables: {{{1
" b:is_kornshell if defined, enhance with kornshell syntax
" b:is_kornshell if defined, enhance with kornshell/POSIX syntax
" b:is_bash if defined, enhance with bash syntax
" is_kornshell if neither b:is_kornshell or b:is_bash is
" defined, then if is_kornshell is set
" b:is_kornshell is default
" is_bash if none of the previous three variables are
" defined, then if is_bash is set b:is_bash is default
" g:is_kornshell if neither b:is_kornshell or b:is_bash is
" defined, then if g:is_kornshell is set
" enhance with kornshell/POSIX syntax highlighting
" g:is_bash if none of the previous three variables are
" defined, then if g:is_bash is set enhance with
" bash syntax highlighting
" g:sh_fold_enabled if non-zero, syntax folding is enabled
" sh_minlines sets up syn sync minlines (default: 200)
" sh_maxlines sets up syn sync maxlines (default: twice sh_minlines)
" g:sh_minlines sets up syn sync minlines (dflt: 200)
" g:sh_maxlines sets up syn sync maxlines (dflt: 2x sh_minlines)
"
" This file includes many ideas from Éric Brunet (eric.brunet@ens.fr)
@ -385,7 +386,7 @@ if exists("b:is_bash")
" bash : ${parameter//pattern/string}
" bash : ${parameter//pattern}
syn match shDerefPPS contained '/\{1,2}' nextgroup=shDerefPPSleft
syn region shDerefPPSleft contained start='.' skip=@\%(\\\)\/@ matchgroup=shDerefOp end='/' nextgroup=shDerefPPSright contains=@shCommandSubList
syn region shDerefPPSleft contained start='.' skip=@\%(\\\)\/@ matchgroup=shDerefOp end='/' end='\ze}' nextgroup=shDerefPPSright contains=@shCommandSubList
syn region shDerefPPSright contained start='.' end='\ze}' contains=@shCommandSubList
endif

View file

@ -1,8 +1,8 @@
" Vim syntax file
" Language: Vim 7.0 script
" Maintainer: Dr. Charles E. Campbell, Jr. <NdrOchipS@PcampbellAfamily.Mbiz>
" Last Change: October 12, 2005
" Version: 7.0-17
" Last Change: Nov 18, 2005
" Version: 7.0-20
" Automatically generated keyword lists: {{{1
" Quit when a syntax file was already loaded {{{2
@ -123,11 +123,11 @@ syn keyword vimPattern contained start skip end
" Operators: {{{2
" =========
syn cluster vimOperGroup contains=vimOper,vimOperParen,vimNumber,vimString,vimOperOk,vimRegister
syn cluster vimOperGroup contains=vimOper,vimOperParen,vimNumber,vimString,vimOperOk,vimRegister,vimContinue
syn match vimOper "\(==\|!=\|>=\|<=\|=\~\|!\~\|>\|<\|=\)[?#]\{0,2}" skipwhite nextgroup=vimString,vimSpecFile
syn match vimOper "||\|&&\|[-+.]" skipwhite nextgroup=vimString,vimSpecFile
syn region vimOperParen oneline matchgroup=vimOper start="(" end=")" contains=@vimOperGroup
syn region vimOperParen oneline matchgroup=vimSep start="{" end="}" contains=@vimOperGroup nextgroup=vimVar
syn region vimOperParen matchgroup=vimSep start="{" end="}" contains=@vimOperGroup nextgroup=vimVar
syn match vimOperOk "\<[aiAIrR][()]"
if !exists("g:vimsyntax_noerror")
syn match vimOperError ")"
@ -217,7 +217,7 @@ syn match vimCollClassErr contained "\[:.\{-\}:\]"
syn match vimCollClass contained transparent "\[:\(alnum\|alpha\|blank\|cntrl\|digit\|graph\|lower\|print\|punct\|space\|upper\|xdigit\|return\|tab\|escape\|backspace\):\]"
syn match vimSubstSubstr contained "\\z\=\d"
syn match vimSubstTwoBS contained "\\\\"
syn match vimSubstFlagErr contained "[^< \t\r]\+" contains=vimSubstFlags
syn match vimSubstFlagErr contained "[^< \t\r|]\+" contains=vimSubstFlags
syn match vimSubstFlags contained "[&cegiIpr]\+"
" 'String': {{{2

View file

@ -0,0 +1,821 @@
===============================================================================
= V i t a j t e v o V I M T u t o r i a l i - Verzia 1.5 =
===============================================================================
Vim je veľmi výkonný editor, ktorý má príliž veľa príkazov na to aby
mohli byt všetky popísané vo výuke akou je táto. Táto výuka
popisuje dostatočné množstvo príkazov nato aby bolo možné používať
Vim ako viacúčelový editor.
Približný čas potrebný na prebratie tejto výuky je 25-30 minút,
závisí na tom, koľko je stráveného času s preskúšavaním.
Príkazy v lekciách modifikujú text. Vytvor kópiu tohto súboru aby
sa mohlo precvičovať na ňom (pri štarte "vimtutor" je toto kópia).
Je dôležité zapamätať si, že táto výuka je vytvorená pre výuku
používaním. To znamená, že je potrebné si príkazy vyskúšať, aby bolo
učenie správne. Ak len čitas text, príkazy zabudneš!
Presvedč sa, že Shift-Lock NIEJE stlačený a stlačt klávesu
j niekoľko krát, aby sa kurzor posunul natoľko, že lekcia 1.1
celkom zaplní obrazovku.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 1.1: POHYB KURZOROM
** Pre pohyb kurzorum stlač klávesy h,j,k,l ako je znázornené. **
^
k Funkcia: Klávesa h je naľavo a vykoná pohyb doľava.
< h l > Klávesa l je napravo a vykoná pohyb doprava.
j Klávesa j vyzerá ako šípka dole
v
1. Pohybuj kurzorom po obrazovke, kým si na to nezvykneš.
2. Drž stlačenú klávesu pre pohyb dole (j), kým sa jej funkcia nezopakuje.
---> Teraz sa už vieš pohybovať na nasledujúcu lekciu.
3. Použitím klávesy pre pohyb dole prejdi na Lekciu 1.2.
Poznámka: Ak si niesi istý tým čo si napísal, stlač <ESC>
na prechod do normálneho módu.
Poznámka: Kurzorové klávesy sú tiež funkčné. Ale používaním hjkl sa budeš
schopný pohybovať rýchlejšie, keď si zvykneš ich používať.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LEKCIA 1.2: SPÚŠŤANIE A ZATVÁRANIE VIMU
!! POZNÁMKA: Pred vykonaním týchto krokov si prečítaj celú túto lekciu !!
1. Stlač klávesu <ESC> (aby si sa učite nachádzal v normálnom móde)
2. Napíš: :q! <ENTER>.
---> Tým ukončíš prácu s editorom BEZ uloženia zmien, ktoré si vykonal.
Ak chceš uložiť vykonané zmeny a ukončiť prácu s editorom napíš:
:wq <ENTER>
3. Keď sa dostaneš na príkazový riadok, napíš príkaz, ktorým sa dostaneš
speť do tejto výuky. To môže byť: vimtutor <ENTER>
Zvyčajne sa používa: vim tutor <ENTER>
---> 'vim' znamená spustenie editora vim, 'tutor' je názov súboru, ktorý
chceš editovať.
4. Ak si si tieto kroky spoľahlivo zapamätal, vykonaj kroky 1 až 3, pre
ukončenie a znovu spustenie editora. Potom presuň kurzor dole na
lekciu 1.3.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 1.3: EDITÁCIA TEXTU - MAZANIE
** Stlačenie klávesy x v normálnom móde zmaže znak na mieste kurzora. **
1. Presuň kurzor nižšie na riadok označený značkou --->.
2. Aby si mohol odstrániť chyby, pohybuj kurzorom kým neprejde na znak,
ktorý chceš zmazať.
3. Stlač klávesu x aby sa zmazal nechcený znak.
4. Zopakuj kroky 2 až 4 až kým veta nieje správna.
---> Kraava skoočilla ccezz mesiiac.
5. Ak je veta správna, prejdi na lekciu 1.4.
POZNÁMKA: Neskúšaj si zapametäť obsah tejto výuky, ale sa uč používaním.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 1.4: EDITÁCIA TEXTU - VKLADANIE
** Stlačenie klávesy i v normálnom móde umožňuje vkladanie textu. **
1. Presuň kurzor nižšie na prvý riadok za značku --->.
2. Pre upravenie prvého riadku do rovnakého tvaru ako je druhý riadok,
presuň kurzor na prvý znak za misto, kde má byť text vložený.
3. Stlač klávesu i a napíš potrebný text.
4. Po opravení každej chyby, stlač <ESC> pre návrat do normálneho módu.
Zopakuj kroky 2 až 4 kým nieje veta správna.
---> Tu je text chýbajúci tejto.
---> Tu je nejaký text chýbajúci od tejto čiary.
5. Keď sa dostatočne naučíš vkladať text, prejdi na nasledujúce zhrnutie.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
ZHRNUTIE LEKCIE 1
1. Kurzor sa pohybuje použitím kláves so šípkami alebo klávesmi hjkl.
h (do lava) j (dole) k (hore) l (doprava)
2. Pre spustenie Vimu (z príkazového riadku) napíš: vim FILENAME <ENTER>
3. Na ukončenie Vimu napíš: <ESC> :q! <ENTER> pre zrušenie všetkých zmien
alebo napíš: <ESC> :wq <ENTER> pre uloženie zmien.
4. Na zmazanie znaku na mieste kurzora napíš v normálnom móde: x
5. Pre vloženie textu na mieste kurzora v normálnom móde napíš:
i vkladaný text <ESC>
POZNÁMKA: Stlačenie <ESC> ťa premiestní do normálneho módu alebo zruší
nejaký nechcený a čiastočne dokončený príkaz.
Teraz pokračuj lekciou 2.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 2.1: Mazacie príkazy
** Napísanie príkazu dw zmaže znaky do konca slova. **
1. Stlač <ESC> aby si bol bezpečne v normálnom móde.
2. Presuň kurzor nižšie na riadok označený značkou --->.
3. Presuň kurzor na začiatok slova, ktoré je potrebné zmazať.
4. Napíš dw aby slovo zmizlo.
POZNÁMKA: Písmená dw sa zobrazia na poslednom riadku obrazovky tak ako ich
píšeš. Ak píšeš niečo zle, stlač <ESC> a začni znova.
---> Tu je niekoľko slov zábava, ktoré nie patria list do tejto vety.
5. Zopakuj kroky 3 až 4 kým veta nieje správna a prejdi na lekciu 2.2.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 2.2: VIAC MAZACÍCH PRÍKAZOV
** Napísanie príkazu d$ zmaže znaky do konca riadku **
1. Stlač <ESC> aby si bol bezpečne v normálnom móde.
2. Presuň kurzor nižšie na riadok označený značkou --->.
3. Presuň kurzor na koniec správnej vety (ZA prvú bodku).
4. Napíš d$ aby sa zmazali znaky do konca riadku.
---> Niekto napísal koniec tohto riadku dvakrát. koniec tohot riadku dvakrát.
5. Prejdi na lekciu 2.3 pre pochopenie toho čo sa stalo.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 2.3: ROZŠIROVACIE PRÍKAZY A OBJEKTY
Formát mazacieho príkazu d je nasledovný:
[číslo] d objekt ALEBO d [číslo] objekt
Kde:
číslo - udáva koľko krát sa príkaz vykoná (voliteľné, implicitne=1)
d - je príkaz pre mazanie
objekt - udáva na čom sa príkaz vykonáva (vypísané nižšie)
Krátky výpis objektov:
w - od kurzora do konca slova, vrátanie medzier
e - od kurzora do konca slova, BEZ medzier
$ - od kurzora do konca riadku.
POZNÁMKA: Ak stlačíš klávesu objektu v normálnom móde bez príkazu, kurzor
sa presunie na miesto špecifikované vo výpise objektov.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 2.4: VÝNIMKA V 'PRÍKAZOVOM OBJEKTE'
** Napísanie príkazu dd zmaže celý riadok. **
Vzhľadom na frekvenciu mazania celého riadku, sa autori Vimu rozhodli,
že bude jednoduchšie mazať celý riadok napísaním dvoch písmen d.
1. Presuň kurzor na druhý riadok v texte na spodu.
2. Napíš dd aby si zmazal riadok.
3. Prejdi na štvrtý riadok.
4. Napíš 2dd (pametaj si číslo-príkaz-objekt) aby si zmazal dva riadky.
1) Ruže sú červené,
2) Blato je zábavné,
3) Fialky sú modré,
4) Mám auto,
5) Hodinky ukazujú čas,
6) Cukor je sladký,
7) A to si ty.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 2.5: PRÍKAZ UNDO
** Stlač u pre vrátenie posledného príkazu, U pre úpravu celého riadku. **
1. Presuň kurzor nižšie na riadok označený značkou ---> a premiestni ho na
prvú chybu.
2. Napíš x pre zmazanie prvého nechceného riadku.
3. Teraz napíš u čím vrátíš späť posledne vykonaný príkaz.
4. Teraz oprav všetky chyby na riadku použitím príkazu x .
5. Teraz napíš veľké U čím vrátíš riadok do pôvodného stavu.
6. Teraz napíš u niekoľko krát, čím vrátíš späť príkaz U.
7. Teraz napíš CTRL-R (drž klávesu CTRL stlačenú kým stláčaš R) niekoľko
krát, čím vrátíš späť predtým vrátené príkazy (redo).
---> Opprav chybby nna toomto riadku a zmeeň ich pommocou undo.
8. Tieto príkazy sú často používané. Teraz prejdi na zhrnutie lekcie 2.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LEKCIA 2 ZHRNUTIE
1. Pre zmazanie znakov od kurzora do konca slova napíš: dw
2. Pre zmazanie znakov od kurzora do konca riadku napíš: d$
3. Pre zmazanie celého riadku napíš: dd
4. Formát pre píkaz v norálnom móde je:
[číslo] príkaz objekt ALEBO príkaz [číslo] objekt
kde:
číslo - udáva koľko krát sa príkaz zopakuje
príkaz - udáva vykonávaný príkaz, ako napríklad d pre mazanie
objekt - udáva rozsah príkazu, ako napríklad w(slovo),
$ (do konca riadku), atď.
5. Pre vrátenie späť predošlej operácie napíš: u (malé u)
Pre vrátenie všetkých úprav na riadku napíš: U (veľké U)
Pre vrátenie vrátených úprav napíš: CTRL-R
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 3.1: PRÍKAZ VLOŽIŤ
** Napísanie príkazu p vloží psledný výmaz za kurzor. **
1. Presuň kurzor nižšie na prvý riadok textu.
2. Napíš dd čím zmažeš riadok a uložíš ho do buffera editora Vim.
3. Presuň kurzor vyššie tam, kam zmazaný riadok patrí.
4. Ak napíšeš v normálnom móde p zmazaný riadk sa vloží.
5. Zopakuj kroky 2 až 4, kým riadky niesú v správnom poradí.
d) Tiež sa dokážeš vzdelávať?
b) Fialky sú modré,
c) Inteligencia sa vzdeláva,
a) Ruže sú červené,
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 3.2: PRÍKAZ NAHRADENIA
** Napísaním r a znaku sa nahradí znak na mieste kurzora. **
1. Presuň kurzor nižšie na prví riadok textu označeného značkou --->.
2. Presuň kurzor na začiatok prvej chyby.
3. napíš r a potom znak, ktorý nahradí chybu.
4. Zopakuj kroky 2 a 3, kým prvý riadok nieje správny.
---> Kaď bol tento riasok píaaný, niekro stlašil nesprábne klávesy!
---> Keď bol tento riadok písaný, niekto stlačil nesprávne klávesy!
5. Teraz prejdi na lekciu 3.2.
POZNÁMKA: Pamätaj si, že naučiť sa môžeš len používanim, nie pamätaním.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 3.3. PRÍKAZ ÚPRAVY
** Ak chceš zmeniť časť slova alebo celé slovo, napíš cw . **
1. Presuň kurzor nižšie na prvý riadok označený značkou --->.
2. Umiestni kurzor na písmeno o v slove rosfpl.
3. Napíš cw a oprav slovo (v tomto prípade napíš 'iadok'.)
4. Stlač <ESC> a prejdi na ďalšiu chybu (prvý znak, ktorý treba zmeniť.)
5. Zopakuj kroky 3 a 4, kým prvá veta nieje rovnaká ako druhá.
---> Tento rosfpl má niekoľko skic, ktoré je pirewvbí zmeniť piyťučán príkazu.
---> Tento riadok má niekoľko slov, ktoré je potrebné zmeniť použitím príkazu.
Poznámka, že cw nielen nahrádza slovo, ale ťa aj premiestní do vkladania.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 3.4: VIAC ZMIEN POUŽITÍM c
** Príkaz pre úpravy sa používa s rovnakými objektami ako pre mazanie **
1. Príkaz pre úpravy pracuje rovnako ako pre mazanie. Formát je:
[číslo] c objekt ALEBO c [číslo] objekt
2. Objekty sú rovnaké, ako napríklad w (slovo), $ (koniec riadku), atď.
3. Presuň kurzor nižšie na prvý riadok označený značkou --->.
4. Presuň kurzor na prvú chybu.
5. napíš c$ aby si mohol upraviť zvyšok riadku podľa druhého
a stlač <ESC>.
---> Koniec tohto riadku potrebuje pomoc, aby bol ako druhy.
---> Koniec tohto riadku potrebuje opraviť použitím príkazu c$ .
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LEKCIA 3 ZHRNUTIE
1. Na vloženie textu, ktorý už bol zmazaný, napíš p . To vloží zmazaný
text ZA kurzor (ak bol riadok zmazaný prejde na riadok pod kurzorom).
2. Pre naradenie znaku na mieste kurzora, napíš r a potom znak, ktorý
nahradí pôvodný znak.
3. Príkaz na upravenie umožňuje zmeniť špecifikovaný objekt od kurzora
až po koniec objektu. napr. Napíš cw čím zmníš text od pozície
kurzora do konca slova, c$ zmení text do konca riadku.
4. Format pre nahradenie je:
[číslo] c objekt ALEBO c [číslo] objekt
Teraz prejdi na nalsedujúcu lekciu.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 4.1: POZÍCIA A STATUS SÚBORU
** Stlač CTRL-g pre zobrazenie svojej pozície v súbore a statusu súboru.
Stlač SHIFT-G pre prechod na riadok v súbore. **
Poznámka: Prečítaj si celú túto lekciu skôr ako začneš vykonávať kroky!!
1. Drž stlačenú klávesu Ctrl a stlač g . Na spodu obrazovky sa zobrazí
stavový riadok s názvom súboru a riadkom na ktorom práve si. Zapamätaj
si si číslo riadku pre krok 3.
2. Stlač Shift-G čím sa dostaneš na spodok súboru.
3. Napíš číslo riadku na ktorom si sa nachádzal a stlač Shift-G. To ťa
vráti na riadok, na ktorom si prvý krát stlačil Ctrl-g.
(Keď píšeš čísla, tieto sa nezobrazujú na obrazovke.)
4. Ak sa cítíš schopný vykonať teto kroky, vykonaj kroky 1 až 3.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 4.2: PRÍKAZ VYHĽADÁVANIA
** Napíš / nasledované reťazcom pre vyhľadanie príslušného reťazca. **
1. Napíš znak / v normálnom móde. Poznámka, že tento znak sa spolu
s kurzorom zobrazí v dolnej časti obrazovky ako s : príkazom.
2. Teraz napíš 'errroor' <ENTER>. To je slovo, ktoré chceš vyhľadať.
3. Pre vyhľadanie ďalšieho výskytu rovnakého reťazca, stlač jednoducho n.
Pre vyhľadanie ďalšieho výskytu rovnakého reťazca opačným smerom,
napíš Shift-N.
4. Ak chceš vyhľadať reťazec v spätnom smere, použí príkaz ? miesto
príkazu /.
---> Keď vyhľadávanie dosiahne koniec tohto súboru, bude pokračovať na
začiatku.
"errroor" nie je spôsob ako nahradiť error; errroor je error.
POZNÁMKA: Keď vyhľadávanie dosiahne koniec súboru, bude pokračovať na jeho
začiatku.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 4.3: VYHĽADÁVANIE ZODPOVEDAJÚCICH ZÁTAVORIEK
** Napíš % pre vyhľadanie príslušného znaku ),], alebo } . **
1. Premiestni kurzor na hocaký zo znakov (, [, alebo { v riadku nižšie
označeného značkou --->.
2. Teraz napíš znak % .
3. Kurzor sa premiestni na zodpovedajúcu zátvorku.
4. Napíš % pre presun kurzoru späť na otvárajúcu zátvorku.
---> Toto ( je testovací riadok s ('s, ['s ] a {'s } v riadku. ))
Poznámka: Toto je veľmi výhodné použíť pri ladení programu s chýbajúcimi
uzatvárajúcimi zátvorkami.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 4.4: SPOSOB AKO ZMENIŤ CHYBY
** Napíš :s/starý/nový/g pre nahradenie slova 'starý' za slovo 'nový'. **
1. Presuň kurzor nižšie na riadok označený značkou --->.
2. Napíš :s/thee/the <ENTER> . Poznamka, že tento príkaz zmení len prvý
výskyt v riadku.
3. Teraz napíš :s/thee/the/g čo znamená celkové nahradenie v riadku.
Toto nahradí všetky výskyty v riadku.
---> Thee best time to see thee flowers in thee spring.
4. Pre zmenu všetkých výskytov daného reťazca medzi dvomi ridakami,
napíš :#,#s/starý/nový/g kde #,# sú čísla dvoch riadkov.
napíš :%s/starý/nový/g pre zmenu všetkých výskytov v celom riadku
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LEKCIA 4 ZHRNUTIE
1. Ctrl-g vypíše tvoju pozíciu v súbore a status súboru.
Shift-g ťa premiestni na koniec riadku. Číslo riadku nasledované
Shift-g ťa presunie na dané číslo riadku.
2. Napísanie / nasledované reťazcom vyhľadá reťazec smerom DOPREDU.
Napísanie ? nasledované reťazcom vyhľada reťazec smerom DOZADU.
Napísanie n po vyhľadávaní, vyhľadá nasledujúci výskyt reťazca
v rovnakom smere, pričom Shift-N vyhľadá v opačnom smere.
3. Napísanie % keď kurzor je na (,),[,],{, alebo } nájde zodpovdajúcu
párú zátvorku.
4. Pre nahradenie nového za prvý starý v riadku napíš :s/nový/starý
Pre nahradenie nového za všetky staré v riadku napíš :s/nový/starý/g
Pre nahradenie reťazcov medzi dvoma riadkami 3 napíš :#,#/nový/starý/g
Pre nahradenie všetkých výskytov v súbore napíš :%s/starý/nový/g
Pre potvrdenie každého nahradenia pridaj 'c' :%s/nový/starý/gc
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 5.1 AKO SPUSTIŤ VONKAJŠÍ PRÍKAZ
** Napíš príkaz :! nasledovaný vonkajším príkazom pre spustenie príkazu **
1. Napíš obvyklý píkaz : ktorý nastaví kurzor na spodok obrazovky.
To umožní napísať príkaz.
2. Teraz napíš ! (výkričník). To umožní spustiť hociaký vonkajší príkaz
z príkazového riadku.
3. Ako príklad napíš ls za ! a stlač <ENTER>. Tento príkaz
zobrazí obsah tvojho adresára rovnako ako na príkazovom riadku.
Alebo použi :!dir ak ls nefunguje.
Poznámka: Takto je možné spustiť hociaký vonkajší príkaz.
Poznámka: Všetky príkazy : musia byť dokončené stlačením <ENTER>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 5.2: VIAC O UKLADANÍ SÚBOROV
** Pre uloženie zmien v súbore, napíš :w FILENAME. **
1. Napíš :!dir alebo :!ls pre výpis aktuálneho adresára.
Už vieš, že musíš za týmto stlačiť <ENTER> .
2. Vyber názov súboru, ktorý EŠTE neexistuje.
3. Teraz napíš: :w TEST (kde TEST je názov vybratého súboru.)
4. To uloží celý súbor (Vim Tutor) pod názovm TEST.
Pre overenie napíš :!dir , čím zobrazíš obsah adresára.
Poznámka: že ak ukončíš prácu s editorom Vim a znovu ho spustíš s názvom
súboru TEST, súbor bude kópia výuky, keď si ho uložil.
5. Teraz odstráň súbor napísaním (MS-DOS): :!del TEST
alebo (Unix): :!rm TEST
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 5.3 VÝBEROVÝ PRÍKAZ PRE ULOŽENIE
** Pre uloženie časti súboru, napíš :#,# w FILENAME **
1. Znovu napíš :!dir alebo :!ls pre zobrazenie obsahu aktuálneho
adresára a vyber vhodný súbor ako TEST.
2. Presuň kurzor na vrch tejto strany a napíš Ctrl-g pre vyhľadanie čísla
tohto riadku. PAMETAJ SI TOTO ČÍSLO!
3. Teraz prejdi na spodok strany a napíš Ctrl-g znovu. ZAPAMETAJ SI ČÍSLO
AJ TOHTO RIADKU!
4. Pre uloženie LEN časti súboru, napíš :#,# w TEST kde #,# sú dve čísla
zapamätaných riadkov (vrch, spodok) a TEST je názov súboru.
5. Znova sa pozri, či tam ten súbor je pomocou príkazu :!dir ale
NEODSTRAŇUJ ho.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 5.4: VÝBER A ZLUČOVANIE SÚBOROV
** Pre vloženie obsahu súboru, napíš :r FILENAME **
1. Napíš :!dir aby si sa presvedčil, že súbor TEST stále existuje.
2. Presuň kurzor na vrch tejto strany.
POZNÁMKA: Po vykonaní kroku 3 uvidíš Lekciu 5.3. Potom sa presuň dole
na túto lekciu.
3. Teraz vlož súbor TEST použitím príkazu :r TEST kde TEST je názov
súboru.
POZNÁMKA: Súbor, ktorý si vložil sa vloží od miesta, kde sa nachádza kurzor.
4. Pre kontrolu vloženia súboru, presuň kurzor späť a všimni si, že teraz
máš dve kópie lekcie 5.3, originál a súborovú verziu.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LEKCIA 5 ZHRNUTIE
1. :!príkaz spustí vonkajší príkaz.
Niektoré využiteľné príklady sú:
(MS_DOS) (UNIX)
:!dir :!ls - zobrazí obsah adresára
:!del FILENAME :!rm FILENAME - odstráni súbor FILENAME
2. :w FILENAME uloží aktuálny súbor na disk pod menom FILENAME.
3. :#,#w FILENAME uloží riadky od # do # do súboru FILENAME.
4. :r FILENAME vyberie z disku súbor FILENAME a vloží ho do aktuálneho
súboru za pozíciou kurzora.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 6.1: PRÍKAZ OTVORIŤ
** Napíš o pre vloženie riadku pod kurzor a prepnutie do vkladacieho módu **
1. Presuň kurzor nižšie na riadok označený značkou --->.
2. Napíš o (malé písmeno) pre vloženie čistého riadku pod kurzorm
a prepnutie do vkladacieho módu.
3. Teraz skopíruj riadok označený ---> a stlač <ESC> pre ukončenie
vkladacieho módu.
---> Po napísaní o sa kurzor premiestní na vložený riadok do vkladacieho
módu.
4. Pre otvorenie riadku nad kurzorom, jednotucho napíš veľké O , namiesto
malého o. Vyskúšaj si to na nasledujúcom riadku.
Vlož riadok nad týmto napísaním Shift-O, keď kurzor je na tomto riadku.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 6.2: PRÍKAZ PRIDAŤ
** Napíš a pre vloženie textu ZA kurzor. **
1. Presuň kurzor nižšie na koniec prvého riadku označeného značkou --->
napísaním $ v normálnom móde.
2. Napíš a (malé písmeno) pre pridanie textu ZA znakom na mieste
kurzora. (Veľké A pridá na koniec riadku.)
Poznámka: Toto obchádza písanie i , posledný znak, text na vloženie, <ESC>,
kurzor doprava, a nakoniec, x , na pridávanie na koniec riadku!
3. Teraz dokonči prvý riadok. Poznámka, že pridávanie je vlastne rovnaké
ako vkladací mód, okrem miesta, kde sa text vkladá.
---> Tento riadok ti dovoľuje nácvik
---> Tento riadok ti dovoľuje nácvik pridávania textu na koniec riadku.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 6.3: INÝ SPOSOB NAHRADZOVANIA
** Napíš veľké R pre nahradenie viac ako jedného znaku. **
1. Presuň kurzor nižšie na prvý riadok označený značkou --->.
2. Premiestni kurzor na začiatok prvého slova, ktoré je odlišné od druhého
riadku označeného ---> (slovo 'posledná').
3. Teraz napíš R a nahraď zvyšok textu na prvom riadku písaním cez starý
text tak, aby prvý riadok bol rovnaký ako druhý.
---> Na úpravu prvého riadku do tvaru ako je posledný na strane použi klávesy.
---> Na úpravu prvého riadku do tavru ako je druhý, napíš R a nový text.
4. Poznámka, že ak stlačíš <ESC> pre ukončenie, všetok nezmenený text
zostane.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Lekcia 6.4: NASTAVENIE MOŽNOSTÍ
** Nastav možnosti, takže vyhľadávanie alebo nahradzovanie ignoruje
rozlišovanie **
1. Vyhľadaj reťazec 'ignore' napísaním:
/ignore
Zopakuj vyhľadávanie niekoľko krát stlačením klávesy n
2. Nastav možnosť 'ic' (Ignore case) napísaním príkazu:
:set ic
3. Teraz vyhľadaj reťazec 'ingore' znova stlačením klávesy: n
Zopakuj vyhľadávanie niekoľko krát stlačením klávesy n
4. Nastav možnosťi 'hlsearch' a 'incsearch':
:set hls is
5. Teraz spusti vyhľadávací príkaz znovu, a pozri čo sa stalo:
/ignore
6. Na odstránenie zvýraznenia výrazov napíš:
:nohlsearch
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LEKCIA 6 ZHRNUTIE
1. Napísaním o sa otvorí nový riadok pod kurzorom a premiestni sa kurzor
na vložený riadok do vkladacieho módu.
napísaním veľkého O sa otvorí riadok nad aktuálnym riadkom s kurzorom.
2. Napíš a pre vkladanie textu ZA znak na pozícii kurzoru.
Napísaním veľkého A sa text automatický pridáva na koniec riadku.
3. Napísanie veľkého R prepne do nahradzovacieho módu, kým nieje
stlačené <ESC> pre ukončenie nahradzovacieho módu.
4. Napísanie ":set xxx" nastaví možnosť "xxx".
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LEKCIA 7: PRÍKAZY ON-LINE NÁPOVEDY
** Používaj on-line systém nápovedy **
Vim má obsiahly on-line systém nápovedy. Pre odštartovanie, vyskúšaj jeden
z týchto troch:
- stlač klávesu <HELP> (ak nejakú máš)
- stlač klávesu <F1> (ak nejakú máš)
- napíš :help <ENTER>
Napíš :q <ENTER> čím zatvoríš okno nápovedy.
Môžeš nájsť help ku hociakej téme pridaním argumentu ku príkazu ":help".
Vyskúšaj tieto (nezabudni stlačiť <ENTER>):
:help w
:help c_<T
:help insert-index
:help user-manual
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
LEKCIA 8: VYTVORENIE ŠTARTOVACIEHO SKRIPTU
** Zapni funkcie editora Vim **
Vim má omnoho viac funkcii než Vi, ale večšina z nich je implicitne
vypnutá. Pre používanie viac Vim funkcii vytvor "vimrc" súbor.
1. Začni editovať "vimrc" súbor, to závisí na použitom systéme:
:edit ~/.vimrc pre Unix
:edit $VIM/_vimrc pre MS-Windows
2. Teraz si prečítaj text príkladu "vimrc" súboru:
:read $VIMRUNTIME/vimrc_example.vim
3. Ulož súbor:
:write
Pri nasledujúcom štarte editora Vim sa použije zvýrazňovanie syntaxe.
Do "vimrc" súboru môžeš pridať všetky svoje uprednostňované nastavenia.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Toto vymedzuje výuku Vimu. Toto je určené pre strucný prehľad o editore
Vim, úplne postačujúce pre ľahké a obstojné používanie tohto editora.
Táto výuka je ďaleko od kompletnosti, pretože Vim má omnoho viacej príkazov.
Ako ďalšie si prečítaj užívatľský manuál: ":help user-manual".
Pre ďalšie čítanie a štúdium je odporúčaná kniha:
Vim - Vi Improved - od Steve Oualline
Vydavateľ: New Riders
Prvá kniha určená pre Vim. Špeciálne vhodná pre začiatočníkov.
Obsahuje množstvo príkladov a obrázkov.
Pozri na http://iccf-holland.org/click5.html
Táto kniha je staršia a je viac o Vi ako o Vim, ale je tiež odporúčaná:
Learning the Vi Editor - od Linda Lamb
Vydavateľ: O'Reilly & Associates Inc.
Je to dobrá kniha pre získanie vedomostí o práci s editorom Vi.
Šieste vydanie obsahuje tiež informácie o editore Vim.
Táto výuka bola napísaná autormi Michael C. Pierce a Robert K. Ware,
Colorado School of Mines s použitím myšlienok dodanými od Charles Smith,
Colorado State University. E-mail: bware@mines.colorado.edu.
Modifikované pre Vim od Bram Moolenaar.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Preklad do Slovenčiny: Ľuboš Čelko
e-mail: celbos@inmail.sk
Last Change: 2004 Apr 29
encoding: cp1250

View file

@ -1,6 +1,6 @@
" Vim tutor support file
" Author: Eduardo F. Amatria <eferna1@platea.pntic.mec.es>
" Last Change: 2005 Mar 15
" Last Change: 2005 Oct 16
" This small source file is used for detecting if a translation of the
" tutor file exist, i.e., a tutor.xx file, where xx is the language.
@ -83,6 +83,15 @@ if s:ext =~? '\.pl'
endif
endif
" The Turkish tutor is available in two encodings, guess which one to use
if s:ext =~? '\.tr'
if &enc == "utf-8"
let s:ext = ".tr.utf-8"
elseif &enc == "iso-8859-9"
let s:ext = ".tr.iso9"
endif
endif
" The Greek tutor is available in two encodings, guess which one to use
if s:ext =~? '\.gr' && &enc =~ 737
let s:ext = ".gr.cp737"

View file

@ -149,7 +149,7 @@
# make -n uninstall
# }}}
#
### This Makefile has been succesfully tested on many systems. {{{
### This Makefile has been successfully tested on many systems. {{{
### Only the ones that require special options are mentioned here.
### Check the (*) column for remarks, listed below.
### Later code changes may cause small problems, otherwise Vim is supposed to
@ -296,7 +296,7 @@ CClink = $(CC)
# below. As shipped, this file contains a target that causes to run
# configure. Once configure was run, this file contains a list of
# make variables with predefined values instead. Thus any second invocation
# of make, will buid Vim.
# of make, will build Vim.
# CONFIGURE - configure arguments {{{1
# You can give a lot of options to configure.
@ -374,6 +374,7 @@ CClink = $(CC)
# Uncomment this when you want to include the Python interface.
# NOTE: This may cause threading to be enabled, which has side effects (such
# as using different libraries and debugging becomes more difficult).
# NOTE: Using this together with Perl may cause a crash in initialization.
#CONF_OPT_PYTHON = --enable-pythoninterp
# TCL
@ -420,10 +421,10 @@ CClink = $(CC)
# though configure can find support for it.
#CONF_OPT_NLS = --disable-nls
# XIM - X Input Method. Special character input support for X11 (chinese,
# japanese, special symbols, etc). Also needed for dead-key support.
# XIM - X Input Method. Special character input support for X11 (Chinese,
# Japanese, special symbols, etc). Also needed for dead-key support.
# When omitted it's automatically enabled for the X-windows GUI.
# HANGUL - Input Hangul (korean) language using internal routines.
# HANGUL - Input Hangul (Korean) language using internal routines.
# Uncomment one of these when you want to input a multibyte language.
#CONF_OPT_INPUT = --enable-xim
#CONF_OPT_INPUT = --disable-xim
@ -462,7 +463,7 @@ CClink = $(CC)
#CONF_OPT_X = --without-x
# X WINDOWS DIRECTORY - specify X directories
# If configure can't find you X stuff, or if you have multiple X11 derivates
# If configure can't find you X stuff, or if you have multiple X11 derivatives
# installed, you may wish to specify which one to use.
# Select nothing to let configure choose.
# This here selects openwin (as found on sun).

19
src/auto/configure vendored
View file

@ -2801,8 +2801,8 @@ if test -z "$CFLAGS"; then
fi
if test "$GCC" = yes; then
gccversion=`"$CC" --version | sed -e '2,$d;s/^[^0-9]*\([0-9]\.[0-9.]*\).*$/\1/g'`
if test "$gccversion" = "3.0.1" -o "$gccversion" = "3.0.2"; then
echo 'GCC 3.0.x has a bug in the optimizer, disabling "-O#"'
if test "$gccversion" = "3.0.1" -o "$gccversion" = "3.0.2" -o "$gccversion" = "4.0.1"; then
echo 'GCC 34.0.12 has a bug in the optimizer, disabling "-O#"'
CFLAGS=`echo "$CFLAGS" | sed 's/-O[23456789]/-O/'`
else
if test "$gccversion" = "3.1" -o "$gccversion" = "3.2" -o "$gccversion" = "3.2.1" && `echo "$CFLAGS" | grep -v fno-strength-reduce >/dev/null`; then
@ -4516,7 +4516,7 @@ echo $ECHO_N "checking for location of tclConfig.sh script... $ECHO_C" >&6
echo "${ECHO_T}$try/tclConfig.sh" >&6
. $try/tclConfig.sh
TCL_LIBS=`eval echo "$TCL_LIB_SPEC $TCL_LIBS"`
TCL_DEFS=`echo $TCL_DEFS | sed -e 's/\ /\X/' | tr ' ' '\012' | sed -e '/^-[^D]/d' -e '/-D[^_]/d' -e 's/-D_/ -D_/' | tr -d '\012'`
TCL_DEFS=`echo $TCL_DEFS | sed -e 's/\\ /\\X/' | tr ' ' '\012' | sed -e '/^-[^D]/d' -e '/-D[^_]/d' -e 's/-D_/ -D_/' | tr -d '\012'`
break
fi
done
@ -16048,13 +16048,22 @@ echo "${ECHO_T}no" >&6
fi
fi
echo "$as_me:$LINENO: checking for GCC 3 or later" >&5
echo $ECHO_N "checking for GCC 3 or later... $ECHO_C" >&6
DEPEND_CFLAGS_FILTER=
if test "$GCC" = yes; then
gccmajor=`"$CC" --version | sed -e '2,$d;s/^[^0-9]*\([3-9]\)\.[0-9.]*.*$/\1/g'`
if test "$gccmajor" != ""; then
gccmajor=`"$CC" --version | sed -e '2,$d;s/^[^0-9]*\([1-9]\)\.[0-9.]*.*$/\1/g'`
if test "$gccmajor" > "2"; then
DEPEND_CFLAGS_FILTER="| sed 's+-I */+-isystem /+g'"
fi
fi
if test "$DEPEND_CFLAGS_FILTER" = ""; then
echo "$as_me:$LINENO: result: no" >&5
echo "${ECHO_T}no" >&6
else
echo "$as_me:$LINENO: result: yes" >&5
echo "${ECHO_T}yes" >&6
fi
ac_config_files="$ac_config_files auto/config.mk:config.mk.in"

View file

@ -1381,8 +1381,8 @@ getvvcol(wp, pos, start, cursor, end)
if (c != TAB && vim_isprintc(c))
{
endadd = char2cells(c) - 1;
if (coladd >= endadd)
coladd -= endadd;
if (coladd > endadd) /* past end of line */
endadd = 0;
else
coladd = 0;
}

View file

@ -30,8 +30,9 @@ if test -z "$CFLAGS"; then
fi
if test "$GCC" = yes; then
gccversion=`"$CC" --version | sed -e '2,$d;s/^[[^0-9]]*\([[0-9]]\.[[0-9.]]*\).*$/\1/g'`
if test "$gccversion" = "3.0.1" -o "$gccversion" = "3.0.2"; then
echo 'GCC 3.0.x has a bug in the optimizer, disabling "-O#"'
dnl version 4.0.1 was reported to cause trouble on Macintosh by Marcin Dalecki
if test "$gccversion" = "3.0.1" -o "$gccversion" = "3.0.2" -o "$gccversion" = "4.0.1"; then
echo 'GCC [34].0.[12] has a bug in the optimizer, disabling "-O#"'
CFLAGS=`echo "$CFLAGS" | sed 's/-O[[23456789]]/-O/'`
else
if test "$gccversion" = "3.1" -o "$gccversion" = "3.2" -o "$gccversion" = "3.2.1" && `echo "$CFLAGS" | grep -v fno-strength-reduce >/dev/null`; then
@ -748,7 +749,7 @@ if test "$enable_tclinterp" = "yes"; then
TCL_LIBS=`eval echo "$TCL_LIB_SPEC $TCL_LIBS"`
dnl Use $TCL_DEFS for -D_THREAD_SAFE et al. But only use the
dnl "-D_ABC" items. Watch out for -DFOO=long\ long.
TCL_DEFS=`echo $TCL_DEFS | sed -e 's/\ /\X/' | tr ' ' '\012' | sed -e '/^-[[^D]]/d' -e '/-D[[^_]]/d' -e 's/-D_/ -D_/' | tr -d '\012'`
TCL_DEFS=`echo $TCL_DEFS | sed -e 's/\\ /\\X/' | tr ' ' '\012' | sed -e '/^-[[^D]]/d' -e '/-D[[^_]]/d' -e 's/-D_/ -D_/' | tr -d '\012'`
break
fi
done
@ -3071,13 +3072,19 @@ fi
dnl gcc 3.1 changed the meaning of -MM. The only solution appears to be to
dnl use "-isystem" instead of "-I" for all non-Vim include dirs.
dnl But only when making dependencies, cproto and lint don't take "-isystem".
AC_MSG_CHECKING(for GCC 3 or later)
DEPEND_CFLAGS_FILTER=
if test "$GCC" = yes; then
gccmajor=`"$CC" --version | sed -e '2,$d;s/^[[^0-9]]*\([[3-9]]\)\.[[0-9.]]*.*$/\1/g'`
if test "$gccmajor" != ""; then
gccmajor=`"$CC" --version | sed -e '2,$d;s/^[[^0-9]]*\([[1-9]]\)\.[[0-9.]]*.*$/\1/g'`
if test "$gccmajor" > "2"; then
DEPEND_CFLAGS_FILTER="| sed 's+-I */+-isystem /+g'"
fi
fi
if test "$DEPEND_CFLAGS_FILTER" = ""; then
AC_MSG_RESULT(no)
else
AC_MSG_RESULT(yes)
fi
AC_SUBST(DEPEND_CFLAGS_FILTER)
dnl write output files

View file

@ -16538,7 +16538,8 @@ set_var(name, tv, copy)
{
/* Make sure the variable name is valid. */
for (p = varname; *p != NUL; ++p)
if (!eval_isnamec1(*p) && (p == varname || !VIM_ISDIGIT(*p)))
if (!eval_isnamec1(*p) && (p == varname || !VIM_ISDIGIT(*p))
&& *p != AUTOLOAD_CHAR)
{
EMSG2(_(e_illvar), varname);
return;

View file

@ -12,6 +12,9 @@
*/
#include "vim.h"
#ifdef HAVE_FCNTL_H
# include <fcntl.h>
#endif
#include "version.h"
#ifdef FEAT_EX_EXTRA
@ -1797,7 +1800,17 @@ write_viminfo(file, forceit)
if (tempname != NULL)
{
fp_out = mch_fopen((char *)tempname, WRITEBIN);
int fd;
/* Use mch_open() to be able to use O_NOFOLLOW and set file
* protection same as original file, but strip s-bit. */
fd = mch_open((char *)tempname,
O_CREAT|O_EXTRA|O_EXCL|O_WRONLY|O_NOFOLLOW,
(int)((st_old.st_mode & 0777) | 0600));
if (fd < 0)
fp_out = NULL;
else
fp_out = fdopen(fd, WRITEBIN);
/*
* If we can't create in the same directory, try creating a
@ -1809,18 +1822,14 @@ write_viminfo(file, forceit)
if ((tempname = vim_tempname('o')) != NULL)
fp_out = mch_fopen((char *)tempname, WRITEBIN);
}
#ifdef UNIX
#if defined(UNIX) && defined(HAVE_FCHOWN)
/*
* Set file protection same as original file, but strip s-bit
* and make sure the owner can read/write it.
* Make sure the owner can read/write it. This only works for
* root.
*/
if (fp_out != NULL)
{
(void)mch_setperm(tempname,
(long)((st_old.st_mode & 0777) | 0600));
/* this only works for root: */
(void)chown((char *)tempname, st_old.st_uid, st_old.st_gid);
}
(void)fchown(fileno(fp_out), st_old.st_uid, st_old.st_gid);
#endif
}
}

View file

@ -2152,20 +2152,16 @@ do_one_cmd(cmdlinep, sourcing,
*/
if (!global_busy && ea.line1 > ea.line2)
{
if (sourcing || exmode_active)
if (msg_silent == 0)
{
errormsg = (char_u *)_("E493: Backwards range given");
goto doend;
}
else
{
int msg_silent_save = msg_silent;
msg_silent = 0;
if (sourcing || exmode_active)
{
errormsg = (char_u *)_("E493: Backwards range given");
goto doend;
}
if (ask_yesno((char_u *)
_("Backwards range given, OK to swap"), FALSE) != 'y')
goto doend;
msg_silent = msg_silent_save;
goto doend;
}
lnum = ea.line1;
ea.line1 = ea.line2;

View file

@ -3111,7 +3111,12 @@ buf_write(buf, fname, sfname, start, end, eap, append, forceit,
if (st_old.st_nlink > 1
|| mch_lstat((char *)fname, &st) < 0
|| st.st_dev != st_old.st_dev
|| st.st_ino != st_old.st_ino)
|| st.st_ino != st_old.st_ino
# ifndef HAVE_FCHOWN
|| st.st_uid != st_old.st_uid
|| st.st_gid != st_old.st_gid
# endif
)
backup_copy = TRUE;
else
# endif
@ -3126,18 +3131,19 @@ buf_write(buf, fname, sfname, start, end, eap, append, forceit,
for (i = 4913; ; i += 123)
{
sprintf((char *)gettail(IObuff), "%d", i);
if (mch_stat((char *)IObuff, &st) < 0)
if (mch_lstat((char *)IObuff, &st) < 0)
break;
}
fd = mch_open((char *)IObuff, O_CREAT|O_WRONLY|O_EXCL, perm);
close(fd);
fd = mch_open((char *)IObuff,
O_CREAT|O_WRONLY|O_EXCL|O_NOFOLLOW, perm);
if (fd < 0) /* can't write in directory */
backup_copy = TRUE;
else
{
# ifdef UNIX
chown((char *)IObuff, st_old.st_uid, st_old.st_gid);
(void)mch_setperm(IObuff, perm);
# ifdef HAVE_FCHOWN
fchown(fd, st_old.st_uid, st_old.st_gid);
# endif
if (mch_stat((char *)IObuff, &st) < 0
|| st.st_uid != st_old.st_uid
|| st.st_gid != st_old.st_gid
@ -3145,6 +3151,7 @@ buf_write(buf, fname, sfname, start, end, eap, append, forceit,
backup_copy = TRUE;
# endif
mch_remove(IObuff);
close(fd);
}
}
}
@ -3338,7 +3345,8 @@ buf_write(buf, fname, sfname, start, end, eap, append, forceit,
/* Open with O_EXCL to avoid the file being created while
* we were sleeping (symlink hacker attack?) */
bfd = mch_open((char *)backup,
O_WRONLY|O_CREAT|O_EXTRA|O_EXCL, perm & 0777);
O_WRONLY|O_CREAT|O_EXTRA|O_EXCL|O_NOFOLLOW,
perm & 0777);
if (bfd < 0)
{
vim_free(backup);
@ -3357,11 +3365,9 @@ buf_write(buf, fname, sfname, start, end, eap, append, forceit,
* bits for the group same as the protection bits for
* others.
*/
if (st_new.st_gid != st_old.st_gid &&
if (st_new.st_gid != st_old.st_gid
# ifdef HAVE_FCHOWN /* sequent-ptx lacks fchown() */
fchown(bfd, (uid_t)-1, st_old.st_gid) != 0
# else
chown((char *)backup, (uid_t)-1, st_old.st_gid) != 0
&& fchown(bfd, (uid_t)-1, st_old.st_gid) != 0
# endif
)
mch_setperm(backup,
@ -4023,6 +4029,29 @@ restore_backup:
}
#endif
#ifdef UNIX
/* When creating a new file, set its owner/group to that of the original
* file. Get the new device and inode number. */
if (backup != NULL && !backup_copy)
{
# ifdef HAVE_FCHOWN
struct stat st;
/* don't change the owner when it's already OK, some systems remove
* permission or ACL stuff */
if (mch_stat((char *)wfname, &st) < 0
|| st.st_uid != st_old.st_uid
|| st.st_gid != st_old.st_gid)
{
fchown(fd, st_old.st_uid, st_old.st_gid);
if (perm >= 0) /* set permission again, may have changed */
(void)mch_setperm(wfname, perm);
}
# endif
buf_setino(buf);
}
#endif
if (close(fd) != 0)
{
errmsg = (char_u *)_("E512: Close failed");
@ -4047,27 +4076,6 @@ restore_backup:
mch_set_acl(wfname, acl);
#endif
#ifdef UNIX
/* When creating a new file, set its owner/group to that of the original
* file. Get the new device and inode number. */
if (backup != NULL && !backup_copy)
{
struct stat st;
/* don't change the owner when it's already OK, some systems remove
* permission or ACL stuff */
if (mch_stat((char *)wfname, &st) < 0
|| st.st_uid != st_old.st_uid
|| st.st_gid != st_old.st_gid)
{
chown((char *)wfname, st_old.st_uid, st_old.st_gid);
if (perm >= 0) /* set permission again, may have changed */
(void)mch_setperm(wfname, perm);
}
buf_setino(buf);
}
#endif
#if defined(FEAT_MBYTE) && defined(FEAT_EVAL)
if (wfname != fname)
@ -4288,7 +4296,8 @@ restore_backup:
int empty_fd;
if (org == NULL
|| (empty_fd = mch_open(org, O_CREAT | O_EXTRA | O_EXCL,
|| (empty_fd = mch_open(org,
O_CREAT | O_EXTRA | O_EXCL | O_NOFOLLOW,
perm < 0 ? 0666 : (perm & 0777))) < 0)
EMSG(_("E206: patchmode: can't touch empty original file"));
else
@ -5757,7 +5766,8 @@ vim_rename(from, to)
return -1;
/* Create the new file with same permissions as the original. */
fd_out = mch_open((char *)to, O_CREAT|O_EXCL|O_WRONLY|O_EXTRA, (int)perm);
fd_out = mch_open((char *)to,
O_CREAT|O_EXCL|O_WRONLY|O_EXTRA|O_NOFOLLOW, (int)perm);
if (fd_out == -1)
{
close(fd_in);
@ -7273,7 +7283,7 @@ au_event_disable(what)
save_ei = vim_strsave(p_ei);
if (save_ei != NULL)
{
new_ei = vim_strnsave(p_ei, (int)STRLEN(p_ei) + 8);
new_ei = vim_strnsave(p_ei, (int)(STRLEN(p_ei) + STRLEN(what)));
if (new_ei != NULL)
{
STRCAT(new_ei, what);

View file

@ -535,7 +535,7 @@ static XrmOptionDescRec cmdline_options[] =
{"+reverse", "*reverseVideo", XrmoptionNoArg, "False"},
{"+rv", "*reverseVideo", XrmoptionNoArg, "False"},
{"-display", ".display", XrmoptionSepArg, NULL},
{"-iconic", "*iconic", XrmoptionNoArg, "True"},
{"-iconic", ".iconic", XrmoptionNoArg, "True"},
{"-name", ".name", XrmoptionSepArg, NULL},
{"-bw", ".borderWidth", XrmoptionSepArg, NULL},
{"-borderwidth", ".borderWidth", XrmoptionSepArg, NULL},
@ -1610,7 +1610,8 @@ gui_mch_new_colors()
gui_mch_open()
{
/* Actually open the window */
XtPopup(vimShell, XtGrabNone);
XtRealizeWidget(vimShell);
XtManageChild(XtNameToWidget(vimShell, "*vimForm"));
gui.wid = gui_x11_get_wid();
gui.blank_pointer = gui_x11_create_blank_mouse();

View file

@ -436,6 +436,14 @@ static void Python_Release_Vim(void)
void
python_end()
{
static int recurse = 0;
/* If a crash occurs while doing this, don't try again. */
if (recurse != 0)
return;
++recurse;
#ifdef DYNAMIC_PYTHON
if (hinstPython && Py_IsInitialized())
{
@ -450,6 +458,8 @@ python_end()
Py_Finalize();
}
#endif
--recurse;
}
static int

View file

@ -1287,7 +1287,7 @@ mf_do_open(mfp, fname, flags)
/*
* try to open the file
*/
flags |= O_EXTRA;
flags |= O_EXTRA | O_NOFOLLOW;
#ifdef WIN32
/* Prevent handle inheritance that cause problems with Cscope
* (swap file may not be deleted if cscope connection was open after

View file

@ -4229,9 +4229,7 @@ nv_mousescroll(cap)
cmdarg_T *cap;
{
# if defined(FEAT_GUI) && defined(FEAT_WINDOWS)
win_T *old_curwin;
old_curwin = curwin;
win_T *old_curwin = curwin;
/* Currently we only get the mouse coordinates in the GUI. */
if (gui.in_use && mouse_row >= 0 && mouse_col >= 0)
@ -8083,6 +8081,8 @@ nv_beginline(cap)
if ((fdo_flags & FDO_HOR) && KeyTyped && cap->oap->op_type == OP_NOP)
foldOpenCursor();
#endif
ins_at_eol = FALSE; /* Don't move cursor past eol (only necessary in a
one-character line). */
}
#ifdef FEAT_VISUAL

View file

@ -3724,13 +3724,17 @@ end:
&& curwin->w_cursor.col > 0
&& !(restart_edit || (State & INSERT)))
{
#ifdef FEAT_VIRTUALEDIT
col = curwin->w_cursor.col;
#endif
/* Put the cursor on the last character in the line. */
dec_cursor();
#ifdef FEAT_VIRTUALEDIT
if (ve_flags == VE_ALL)
curwin->w_cursor.coladd = col - curwin->w_cursor.col;
{
colnr_T scol, ecol;
/* Coladd is set to the width of the last character. */
getvcol(curwin, &curwin->w_cursor, &scol, NULL, &ecol);
curwin->w_cursor.coladd = ecol - scol + 1;
}
#endif
}
}

View file

@ -3709,6 +3709,11 @@ mch_call_shell(cmd, options)
putenv(envbuf_Columns);
# endif
/*
* stderr is only redirected when using the GUI, so that a
* program like gpg can still access the terminal to get a
* passphrase using stderr.
*/
# ifdef FEAT_GUI
if (pty_master_fd >= 0)
{
@ -3719,8 +3724,11 @@ mch_call_shell(cmd, options)
dup(pty_slave_fd);
close(1);
dup(pty_slave_fd);
close(2);
dup(pty_slave_fd);
if (gui.in_use)
{
close(2);
dup(pty_slave_fd);
}
close(pty_slave_fd); /* has been dupped, close it now */
}
@ -3739,9 +3747,14 @@ mch_call_shell(cmd, options)
dup(fd_fromshell[1]);
close(fd_fromshell[1]);
/* set up stderr for the child */
close(2);
dup(1);
# ifdef FEAT_GUI
if (gui.in_use)
{
/* set up stderr for the child */
close(2);
dup(1);
}
# endif
}
}

View file

@ -19,6 +19,9 @@ func! GetMline()
let idline .= substitute(line, '"\(.*\)"$', '\1', '')
endwhile
" remove '%', not used for formatting.
let idline = substitute(idline, "'%'", '', 'g')
" remove everything but % items.
return substitute(idline, '[^%]*\(%[-+ #''.0-9*]*l\=[dsuxXpoc%]\)\=', '\1', 'g')
endfunc
@ -39,6 +42,8 @@ while 1
let toline = GetMline()
if fromline != toline
echo 'Mismatching % in line ' . (line('.') - 1)
echo 'msgid: ' . fromline
echo 'msgstr: ' . toline
let error = 1
endif
endif

View file

@ -3,8 +3,8 @@
" - Comment-out fuzzy and empty messages.
" - Make sure there is a space before the string (required for Solaris).
" Requires Vim 6.0 or later (because of multi-line search patterns).
g/^#: /d
g/^#, fuzzy\(, .*\)\=\nmsgid ""\@!/.+1,/^$/-1s/^/#\~ /
g/^msgstr"/s//msgstr "/
g/^msgid"/s//msgid "/
g/^msgstr ""\(\n"\)\@!/?^msgid?,.s/^/#\~ /
silent g/^#: /d
silent g/^#, fuzzy\(, .*\)\=\nmsgid ""\@!/.+1,/^$/-1s/^/#\~ /
silent g/^msgstr"/s//msgstr "/
silent g/^msgid"/s//msgid "/
silent g/^msgstr ""\(\n"\)\@!/?^msgid?,.s/^/#\~ /

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -3550,7 +3550,7 @@ current_block(oap, count, include, what, other)
{
if (*p_sel == 'e')
++curwin->w_cursor.col;
if (sol)
if (sol && gchar_cursor() != NUL)
inc(&curwin->w_cursor); /* include the line break */
VIsual = start_pos;
VIsual_mode = 'v';

View file

@ -47,7 +47,7 @@ test1.out: test1.in
-rm -rf X* viminfo
.in.out:
-rm -rf $*.failed test.ok X* viminfo
-rm -rf $*.failed test.ok test.out X* viminfo
cp $*.ok test.ok
# Sleep a moment to avoid that the xterm title is messed up
@-sleep .2

View file

@ -10,7 +10,7 @@ STARTTEST
:hi NewGroup term=bold cterm=italic ctermfg=DarkBlue ctermbg=Grey gui= guifg=#00ff00 guibg=Cyan
:hi Group2 term= cterm=
:hi Group3 term=underline cterm=bold
:redir >test.out
:redir! >test.out
:hi NewGroup
:hi Group2
:hi Group3

View file

@ -1274,6 +1274,10 @@ typedef enum
# define O_EXTRA 0
#endif
#ifndef O_NOFOLLOW
# define O_NOFOLLOW 0
#endif
#ifndef W_OK
# define W_OK 2 /* for systems that don't have W_OK in unistd.h */
#endif