home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 5 Edit / 05-Edit.zip / vim45os2.zip / vim-4.5 / macros / shell.gui < prev    next >
Text File  |  1996-10-07  |  4KB  |  95 lines

  1. " When you're writing shell scripts, are you then in doubt which
  2. " test to use, which shell environment variables that are defined,
  3. " the syntax of the case statement, and need to call 'man sh'?
  4. " Your problems are over now!
  5. " Attached is a vim 'so' file making vim to a shell script editor (in
  6. " graphics mode). It may also be used as an example how to use menues in Vim.
  7. "
  8. " Written by: Lennart Schultz <les@dmi.min.dk>
  9.  
  10. imenu Stmts.for    for  in dodoneki    kk0elli
  11. imenu Stmts.case    case  in) ;;esacbki    k0elli
  12. imenu Stmts.if    if   thenfiki    kk0elli
  13. imenu Stmts.if-else    if   thenelsefiki    kki    kk0elli
  14. imenu Stmts.elif    elif   thenki    kk0elli
  15. imenu Stmts.while    while   dodoneki    kk0elli
  16. imenu Stmts.break    break 
  17. imenu Stmts.continue     continue 
  18. imenu Stmts.function    () {}ki    k0i
  19. imenu Stmts.return    return 
  20. imenu Stmts.return-true    return 0
  21. imenu Stmts.return-false    return 1
  22. imenu Stmts.exit     exit 
  23. imenu Stmts.shift     shift 
  24. imenu Stmts.trap     trap 
  25. imenu Test.existence     [ -e  ]hi
  26. imenu Test.existence - file     [ -f  ]hi
  27. imenu Test.existence - file (not empty)     [ -s  ]hi
  28. imenu Test.existence - directory     [ -d  ]hi
  29. imenu Test.existence - executable     [ -x  ]hi
  30. imenu Test.existence - readable     [ -r  ]hi
  31. imenu Test.existence - writable     [ -w  ]hi
  32. imenu Test.String is empty [ x = "x$" ]hhi
  33. imenu Test.String is not empty [ x != "x$" ]hhi
  34. imenu Test.Strings is equal [ "" = "" ]hhhhhhhi
  35. imenu Test.Strings is not equal [ "" != "" ]hhhhhhhhi
  36. imenu Test.Values is greater than [  -gt  ]hhhhhhi
  37. imenu Test.Values is greater equal [  -ge  ]hhhhhhi
  38. imenu Test.Values is equal [  -eq  ]hhhhhhi
  39. imenu Test.Values is not equal [  -ne  ]hhhhhhi
  40. imenu Test.Values is less than [  -lt  ]hhhhhhi
  41. imenu Test.Values is less equal [  -le  ]hhhhhhi
  42. imenu ParmSub.Substitute word if parm not set ${:-}hhi
  43. imenu ParmSub.Set parm to word if not set ${:=}hhi
  44. imenu ParmSub.Substitute word if parm set else nothing ${:+}hhi
  45. imenu ParmSub.If parm not set print word and exit ${:?}hhi
  46. imenu SpShVars.Number of positional parameters ${#}
  47. imenu SpShVars.All positional parameters (quoted spaces) ${*}
  48. imenu SpShVars.All positional parameters (unquoted spaces) ${@}
  49. imenu SpShVars.Flags set ${-}
  50. imenu SpShVars.Return code of last command ${?}
  51. imenu SpShVars.Process number of this shell ${$}
  52. imenu SpShVars.Process number of last background command ${!}
  53. imenu Environ.HOME ${HOME}
  54. imenu Environ.PATH ${PATH}
  55. imenu Environ.CDPATH ${CDPATH}
  56. imenu Environ.MAIL ${MAIL}
  57. imenu Environ.MAILCHECK ${MAILCHECK}
  58. imenu Environ.PS1 ${PS1}
  59. imenu Environ.PS2 ${PS2}
  60. imenu Environ.IFS ${IFS}
  61. imenu Environ.SHACCT ${SHACCT}
  62. imenu Environ.SHELL ${SHELL}
  63. imenu Environ.LC_CTYPE ${LC_CTYPE}
  64. imenu Environ.LC_MESSAGES ${LC_MESSAGES}
  65. imenu Builtins.cd cd
  66. imenu Builtins.echo echo
  67. imenu Builtins.eval eval
  68. imenu Builtins.exec exec
  69. imenu Builtins.export export
  70. imenu Builtins.getopts getopts
  71. imenu Builtins.hash hash
  72. imenu Builtins.newgrp newgrp
  73. imenu Builtins.pwd pwd
  74. imenu Builtins.read read
  75. imenu Builtins.readonly readonly
  76. imenu Builtins.return return
  77. imenu Builtins.times times
  78. imenu Builtins.type type
  79. imenu Builtins.umask umask
  80. imenu Builtins.wait wait
  81. imenu Set.set set
  82. imenu Set.unset unset
  83. imenu Set.mark modified or modified variables set -a
  84. imenu Set.exit when command returns non-zero exit code set -e
  85. imenu Set.Disable file name generation set -f
  86. imenu Set.remember function commands set -h
  87. imenu Set.All keyword arguments are placed in the environment set -k
  88. imenu Set.Read commands but do not execute them set -n
  89. imenu Set.Exit after reading and executing one command set -t
  90. imenu Set.Treat unset variables as an error when substituting set -u
  91. imenu Set.Print shell input lines as they are read set -v
  92. imenu Set.Print commands and their arguments as they are executed set -x
  93.