comparison runtime/pack/dist/opt/shellmenu/plugin/shellmenu.vim @ 8775:d5136647ce31 v7.4.1676

commit https://github.com/vim/vim/commit/fead3ac9a35e0fc358141d3eb19574cd8a3ecb55 Author: Bram Moolenaar <Bram@vim.org> Date: Mon Mar 28 21:26:47 2016 +0200 patch 7.4.1676 Problem: The shellmenu plugin has to be copied or sourced to be used. Solution: Turn it into a package.
author Christian Brabandt <cb@256bit.org>
date Mon, 28 Mar 2016 21:30:10 +0200
parents
children 9fe2fed9bb4b
comparison
equal deleted inserted replaced
8774:905f5a8ae52e 8775:d5136647ce31
1 " When you're writing shell scripts and you are in doubt which test to use,
2 " which shell environment variables are defined, what the syntax of the case
3 " statement is, and you need to invoke 'man sh'?
4 "
5 " Your problems are over now!
6 "
7 " Attached is a Vim script file for turning gvim into a shell script editor.
8 " It may also be used as an example how to use menus in Vim.
9 "
10 " Written by: Lennart Schultz <les@dmi.min.dk>
11
12 imenu Stmts.for for in
13 do
14
15 doneki kk0elli
16 imenu Stmts.case case in
17 ) ;;
18 esacbki k0elli
19 imenu Stmts.if if
20 then
21
22 fiki kk0elli
23 imenu Stmts.if-else if
24 then
25
26 else
27
28 fiki kki kk0elli
29 imenu Stmts.elif elif
30 then
31
32 ki kk0elli
33 imenu Stmts.while while
34 do
35
36 doneki kk0elli
37 imenu Stmts.break break
38 imenu Stmts.continue continue
39 imenu Stmts.function () {
40
41 }ki k0i
42 imenu Stmts.return return
43 imenu Stmts.return-true return 0
44 imenu Stmts.return-false return 1
45 imenu Stmts.exit exit
46 imenu Stmts.shift shift
47 imenu Stmts.trap trap
48 imenu Test.existence [ -e ]hi
49 imenu Test.existence - file [ -f ]hi
50 imenu Test.existence - file (not empty) [ -s ]hi
51 imenu Test.existence - directory [ -d ]hi
52 imenu Test.existence - executable [ -x ]hi
53 imenu Test.existence - readable [ -r ]hi
54 imenu Test.existence - writable [ -w ]hi
55 imenu Test.String is empty [ x = "x$" ]hhi
56 imenu Test.String is not empty [ x != "x$" ]hhi
57 imenu Test.Strings is equal [ "" = "" ]hhhhhhhi
58 imenu Test.Strings is not equal [ "" != "" ]hhhhhhhhi
59 imenu Test.Values is greater than [ -gt ]hhhhhhi
60 imenu Test.Values is greater equal [ -ge ]hhhhhhi
61 imenu Test.Values is equal [ -eq ]hhhhhhi
62 imenu Test.Values is not equal [ -ne ]hhhhhhi
63 imenu Test.Values is less than [ -lt ]hhhhhhi
64 imenu Test.Values is less equal [ -le ]hhhhhhi
65 imenu ParmSub.Substitute word if parm not set ${:-}hhi
66 imenu ParmSub.Set parm to word if not set ${:=}hhi
67 imenu ParmSub.Substitute word if parm set else nothing ${:+}hhi
68 imenu ParmSub.If parm not set print word and exit ${:?}hhi
69 imenu SpShVars.Number of positional parameters ${#}
70 imenu SpShVars.All positional parameters (quoted spaces) ${*}
71 imenu SpShVars.All positional parameters (unquoted spaces) ${@}
72 imenu SpShVars.Flags set ${-}
73 imenu SpShVars.Return code of last command ${?}
74 imenu SpShVars.Process number of this shell ${$}
75 imenu SpShVars.Process number of last background command ${!}
76 imenu Environ.HOME ${HOME}
77 imenu Environ.PATH ${PATH}
78 imenu Environ.CDPATH ${CDPATH}
79 imenu Environ.MAIL ${MAIL}
80 imenu Environ.MAILCHECK ${MAILCHECK}
81 imenu Environ.PS1 ${PS1}
82 imenu Environ.PS2 ${PS2}
83 imenu Environ.IFS ${IFS}
84 imenu Environ.SHACCT ${SHACCT}
85 imenu Environ.SHELL ${SHELL}
86 imenu Environ.LC_CTYPE ${LC_CTYPE}
87 imenu Environ.LC_MESSAGES ${LC_MESSAGES}
88 imenu Builtins.cd cd
89 imenu Builtins.echo echo
90 imenu Builtins.eval eval
91 imenu Builtins.exec exec
92 imenu Builtins.export export
93 imenu Builtins.getopts getopts
94 imenu Builtins.hash hash
95 imenu Builtins.newgrp newgrp
96 imenu Builtins.pwd pwd
97 imenu Builtins.read read
98 imenu Builtins.readonly readonly
99 imenu Builtins.return return
100 imenu Builtins.times times
101 imenu Builtins.type type
102 imenu Builtins.umask umask
103 imenu Builtins.wait wait
104 imenu Set.set set
105 imenu Set.unset unset
106 imenu Set.mark modified or modified variables set -a
107 imenu Set.exit when command returns non-zero exit code set -e
108 imenu Set.Disable file name generation set -f
109 imenu Set.remember function commands set -h
110 imenu Set.All keyword arguments are placed in the environment set -k
111 imenu Set.Read commands but do not execute them set -n
112 imenu Set.Exit after reading and executing one command set -t
113 imenu Set.Treat unset variables as an error when substituting set -u
114 imenu Set.Print shell input lines as they are read set -v
115 imenu Set.Print commands and their arguments as they are executed set -x