Skip to content

Commit c2ae61a

Browse files
Fritz Mehnervim-scripts
authored andcommitted
Version 3.12
- New global variable g:BASH_InsertFileHeader (suppress file description comment for new files) - New menu item 'view code snippet' (\nv). - New ex command BASH_ScriptCmdLineArguments. - 3 ex commands renamed. - Minor internal improvements.
1 parent 73c20b2 commit c2ae61a

File tree

7 files changed

+180
-192
lines changed

7 files changed

+180
-192
lines changed

README.bashsupport

Lines changed: 27 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
README for bash-support.vim (Version 3.11) / December 01 2012
1+
README for bash-support.vim (Version 3.12) / January 02 2013
22

33
* INSTALLATION
4-
* RELEASE NOTES
4+
* RELEASE NOTES
55
* FILES
66
* ADDITIONAL TIPS
77

@@ -10,8 +10,8 @@ speed up writing code in a consistent style. This is done by inserting
1010
complete statements, comments, idioms, and code snippets. Syntax checking,
1111
running a script, starting a debugger can be done with a keystroke. There are
1212
many additional hints and options which can improve speed and comfort when
13-
writing shell scripts.
14-
13+
writing shell scripts.
14+
1515
================================================================================
1616
INSTALLATION
1717
================================================================================
@@ -43,11 +43,11 @@ structure which is needed below the local installation directory $HOME/.vim/
4343
This is the minimal content of the file '$HOME/.vimrc'. Create one if there
4444
is none or use the files in $HOME/.vim/bash-support/rc as a starting point.
4545

46-
(1.3) Set at least some personal details in the file
47-
'$HOME/.vim/bash-support/templates/Templates'
46+
(1.3) Set at least some personal details in the file
47+
'$HOME/.vim/bash-support/templates/Templates'
4848
Here is the minimal personalization (my settings as an example):
4949

50-
|AUTHOR| = Dr. Fritz Mehner
50+
|AUTHOR| = Dr. Fritz Mehner
5151
|AUTHORREF| = fgm
5252
5353
|COMPANY| = FH S�dwestfalen, Iserlohn
@@ -59,11 +59,11 @@ structure which is needed below the local installation directory $HOME/.vim/
5959
Vim command line:
6060

6161
:helptags $HOME/.vim/doc/
62-
62+
6363
(1.5) Consider additional settings in the file '$HOME/.vimrc'. The files
6464
customization.vimrc and customization.gvimrc are replacements or extensions
6565
for your .vimrc and .gvimrc. You may want to use parts of them. The files
66-
are documented.
66+
are documented.
6767

6868

6969
(2) WINDOWS
@@ -94,11 +94,11 @@ $HOME/vimfiles/ (find the value of $HOME with ":echo $HOME" from inside Vim).
9494
is none or use the files in $HOME/vimfiles/bash-support/rc as a starting
9595
point.
9696

97-
(2.3) Set at least some personal details in the file
98-
'$HOME/vimfiles/bash-support/templates/Templates'
97+
(2.3) Set at least some personal details in the file
98+
'$HOME/vimfiles/bash-support/templates/Templates'
9999
Here is the minimal personalization (my settings as an example):
100100

101-
|AUTHOR| = Dr. Fritz Mehner
101+
|AUTHOR| = Dr. Fritz Mehner
102102
|AUTHORREF| = fgm
103103
104104
|COMPANY| = FH S�dwestfalen, Iserlohn
@@ -110,11 +110,11 @@ $HOME/vimfiles/ (find the value of $HOME with ":echo $HOME" from inside Vim).
110110
Vim command line:
111111

112112
:helptags $HOME\vimfiles\doc\
113-
113+
114114
(2.5) Consider additional settings in the file '$HOME/_vimrc'. The files
115115
customization.vimrc and customization.gvimrc are replacements or extensions
116116
for your _vimrc and _gvimrc. You may want to use parts of them. The files
117-
are documented.
117+
are documented.
118118

119119
There are a lot of features and options which can be used and influenced:
120120

@@ -126,7 +126,7 @@ There are a lot of features and options which can be used and influenced:
126126

127127
Look at the bashsupport help with
128128

129-
:help bashsupport
129+
:help bashsupport
130130

131131
+-----------------------------------------------+
132132
| +-------------------------------------------+ |
@@ -136,10 +136,12 @@ Look at the bashsupport help with
136136
+-----------------------------------------------+
137137

138138
=======================================================================================
139-
RELEASE NOTES FOR VERSION 3.11
139+
RELEASE NOTES FOR VERSION 3.12
140140
=======================================================================================
141-
- Rendering of manuals (\hm) and Bash help (\hh).
142-
- Bugfix: \hb, \hm, \hh not working.
141+
- New global variable g:BASH_InsertFileHeader (suppress file description comment for new files)
142+
- New menu item 'view code snippet' (\nv).
143+
- New ex command BASH_ScriptCmdLineArguments.
144+
- 3 ex commands renamed.
143145
- Minor internal improvements.
144146

145147
=======================================================================================
@@ -157,7 +159,7 @@ ftplugin/sh.vim A filetype plugin. Defines hotkeys and more.
157159
plugin/bash-support.vim The bash plugin for Vim/gVim.
158160
bash-support/scripts/wrapper.sh A wrapper script for the use of an xterm.
159161

160-
doc/bashsupport.txt The help file for the local online help.
162+
doc/bashsupport.txt The help file for the local online help.
161163

162164
bash-support/codesnippets/* Some code snippets as a starting point.
163165

@@ -170,19 +172,19 @@ bash-support/wordlists/* Additional word lists (dictionaries).
170172
bash-support.vim will work without them.
171173
-------------------------------------------------------------
172174

173-
bash-support/rc/customization.bashrc Additional settings I use in .bashrc:
175+
bash-support/rc/customization.bashrc Additional settings I use in .bashrc:
174176
set the prompt P2, P3, P4 (for debugging).
175177

176-
bash-support/rc/customization.vimrc Additional settings I use in .vimrc: incremental
177-
search, tabstop, hot keys, font, use of dictionaries,
178+
bash-support/rc/customization.vimrc Additional settings I use in .vimrc: incremental
179+
search, tabstop, hot keys, font, use of dictionaries,
178180
... The file is commented. Append it to your .vimrc
179181
if you like.
180182

181-
bash-support/rc/customization.gvimrc Additional settings I use in .gvimrc: hot keys,
182-
mouse settings, ... The file is commented.
183+
bash-support/rc/customization.gvimrc Additional settings I use in .gvimrc: hot keys,
184+
mouse settings, ... The file is commented.
183185
Append it to your .gvimrc if you like.
184186

185-
bash-support/doc/* Hotkey reference card (PDF), changelog.
187+
bash-support/doc/* Hotkey reference card (PDF), changelog.
186188

187189

188190
=======================================================================================

doc/ChangeLog

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
=======================================================================================
2+
RELEASE NOTES FOR VERSION 3.11
3+
=======================================================================================
4+
- Rendering of manuals (\hm) and Bash help (\hh).
5+
- Bugfix: \hb, \hm, \hh not working.
6+
- Minor internal improvements.
7+
18
=======================================================================================
29
RELEASE NOTES FOR VERSION 3.10
310
=======================================================================================

doc/bash-hot-keys.pdf

-2.09 KB
Binary file not shown.

doc/bash-hot-keys.tex

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@
88
99
%% Copyright: Copyright (C) 2003-2010 Dr.-Ing. Fritz Mehner ([email protected])
1010
%% Version: see PluginVersion (below)
11-
%% Revision: $Id: bash-hot-keys.tex,v 1.40 2012/06/01 07:47:06 mehner Exp $
11+
%% Revision: $Id: bash-hot-keys.tex,v 1.41 2013/01/01 12:57:59 mehner Exp $
1212
%% Created: 09.06.2003
1313
%%
1414
%% Notes:
1515
%%
1616
%%=====================================================================================
1717

18-
\newcommand{\PluginVersion}{3.10}
18+
\newcommand{\PluginVersion}{3.12}
1919
\newcommand{\ReleaseDate}{\today}
2020
\newcommand{\Rep}{{\scriptsize{[n]}}}
2121

@@ -185,6 +185,7 @@
185185
\hline
186186
\multicolumn{2}{|r|}{\textsl{S\textbf{n}ippets}}\\
187187
\hline \verb'\nr' & read code snippet \hfill (n, i)\\
188+
\hline \verb'\nv' & view code snippet \hfill (n, i)\\
188189
\hline \verb'\nw' & write code snippet \hfill (n, v, i)\\
189190
\hline \verb'\ne' & edit code snippet \hfill (n, i)\\
190191
%

doc/bashsupport.txt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
*bashsupport.txt* Bash Support December 01 2012
1+
*bashsupport.txt* Bash Support January 02 2013
22

33
bash Support *bash-support* *bashsupport*
4-
Plugin version 3.11
4+
Plugin version 3.12
55
for Vim version 7.0 and above
66
Fritz Mehner <[email protected]>
77

@@ -746,6 +746,7 @@ Legend: (i) insert mode, (n) normal mode, (v) visual mode
746746
-- Snippets --------------------------------------------
747747

748748
\nr read code snippet (n, i)
749+
\nv view code snippet (readonly) (n, i)
749750
\nw write code snippet (n, v, i)
750751
\ne edit code snippet (n, i)
751752

@@ -907,6 +908,7 @@ g:BASH_Debugger 'term'
907908
g:BASH_LineEndCommColDefault 49
908909
g:BASH_SyntaxCheckOptionsGlob ''
909910
g:BASH_Printheader '%<%f%h%m%< %=%{strftime('%x %X')} Page %N'
911+
g:BASH_InsertFileHeader 'yes'
910912
g:BASH_BASH $SHELL (Linux/U**X)
911913
'bash.exe' (Windows)
912914
g:BASH_Man 'man' (Linux/U**X)
@@ -944,6 +946,7 @@ g:BASH_AlsoBash ''
944946
g:BASH_LineEndCommColDefault : default starting column for line end comments
945947
g:BASH_SyntaxCheckOptionsGlob : shopt options used with syntax checking
946948
g:BASH_Printheader : hardcopy header format
949+
g:BASH_InsertFileHeader : suppress file description comment for new files
947950
g:BASH_BASH : the shell used
948951
g:BASH_Man : the interface to the on-line manuals
949952
g:BASH_MapLeader : the map leader for hotkeys (see|bashsupport-usage-vim|)

ftplugin/sh.vim

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
" Language : bash
44
" Plugin : bash-support.vim
55
" Maintainer : Fritz Mehner <[email protected]>
6-
" Revision : $Id: sh.vim,v 1.48 2012/12/01 10:59:55 mehner Exp $
6+
" Revision : $Id: sh.vim,v 1.49 2013/01/01 12:57:32 mehner Exp $
77
"
88
" -----------------------------------------------------------------
99
"
@@ -38,9 +38,10 @@ if exists("g:BASH_Dictionary_File")
3838
silent! exe 'setlocal dictionary+='.save
3939
endif
4040
"
41-
command! -nargs=1 -complete=customlist,BASH_StyleList BashStyle call BASH_Style(<f-args>)
42-
command! -nargs=1 -complete=customlist,BASH_ScriptSectionList ScriptSection call BASH_ScriptSectionListInsert(<f-args>)
43-
command! -nargs=1 -complete=customlist,BASH_KeywordCommentList KeywordComment call BASH_KeywordCommentListInsert(<f-args>)
41+
command! -nargs=* -complete=file BashCmdlineArgs call BASH_ScriptCmdLineArguments(<q-args>)
42+
command! -nargs=1 -complete=customlist,BASH_KeywordCommentList BashKeywordComment call BASH_KeywordCommentListInsert(<f-args>)
43+
command! -nargs=1 -complete=customlist,BASH_ScriptSectionList BashScriptSection call BASH_ScriptSectionListInsert(<f-args>)
44+
command! -nargs=1 -complete=customlist,BASH_StyleList BashStyle call BASH_Style(<f-args>)
4445
"
4546
" ---------- hot keys ------------------------------------------
4647
"
@@ -62,8 +63,8 @@ if has("gui_running")
6263
vmap <buffer> <silent> <C-F9> <C-C>:call BASH_Run("v")<CR>
6364
endif
6465
"
65-
map <buffer> <silent> <S-F9> :call BASH_ScriptCmdLineArguments()<CR>
66-
imap <buffer> <silent> <S-F9> <C-C>:call BASH_ScriptCmdLineArguments()<CR>
66+
map <buffer> <S-F9> :BashCmdlineArgs<Space>
67+
imap <buffer> <S-F9> <C-C>:BashCmdlineArgs<Space>
6768
endif
6869
"
6970
if !s:MSWIN
@@ -249,19 +250,21 @@ inoremap <buffer> <silent> <LocalLeader>px [:xdigit:]
249250
"
250251
" ---------- snippet menu ----------------------------------------------------
251252
"
252-
nnoremap <buffer> <silent> <LocalLeader>nr :call BASH_CodeSnippets("r")<CR>
253-
nnoremap <buffer> <silent> <LocalLeader>nw :call BASH_CodeSnippets("w")<CR>
254-
vnoremap <buffer> <silent> <LocalLeader>nw <C-C>:call BASH_CodeSnippets("wv")<CR>
255-
nnoremap <buffer> <silent> <LocalLeader>ne :call BASH_CodeSnippets("e")<CR>
253+
nnoremap <buffer> <silent> <LocalLeader>nr :call BASH_CodeSnippets("read")<CR>
254+
nnoremap <buffer> <silent> <LocalLeader>nv :call BASH_CodeSnippets("view")<CR>
255+
nnoremap <buffer> <silent> <LocalLeader>nw :call BASH_CodeSnippets("write")<CR>
256+
vnoremap <buffer> <silent> <LocalLeader>nw <C-C>:call BASH_CodeSnippets("writemarked")<CR>
257+
nnoremap <buffer> <silent> <LocalLeader>ne :call BASH_CodeSnippets("edit")<CR>
256258
"
257259
nnoremap <buffer> <silent> <LocalLeader>ntl :call BASH_BrowseTemplateFiles("Local")<CR>
258260
nnoremap <buffer> <silent> <LocalLeader>ntg :call BASH_BrowseTemplateFiles("Global")<CR>
259261
nnoremap <buffer> <silent> <LocalLeader>ntr :call BASH_RereadTemplates()<CR>
260262
nnoremap <buffer> <LocalLeader>nts :BashStyle<Space>
261263
"
262-
inoremap <buffer> <silent> <LocalLeader>nr <Esc>:call BASH_CodeSnippets("r")<CR>
263-
inoremap <buffer> <silent> <LocalLeader>nw <Esc>:call BASH_CodeSnippets("w")<CR>
264-
inoremap <buffer> <silent> <LocalLeader>ne <Esc>:call BASH_CodeSnippets("e")<CR>
264+
inoremap <buffer> <silent> <LocalLeader>nr <Esc>:call BASH_CodeSnippets("read")<CR>
265+
inoremap <buffer> <silent> <LocalLeader>nv <Esc>:call BASH_CodeSnippets("view")<CR>
266+
inoremap <buffer> <silent> <LocalLeader>nw <Esc>:call BASH_CodeSnippets("write")<CR>
267+
inoremap <buffer> <silent> <LocalLeader>ne <Esc>:call BASH_CodeSnippets("edit")<CR>
265268
"
266269
inoremap <buffer> <silent> <LocalLeader>ntl <Esc>:call BASH_BrowseTemplateFiles("Local")<CR>
267270
inoremap <buffer> <silent> <LocalLeader>ntg <Esc>:call BASH_BrowseTemplateFiles("Global")<CR>
@@ -280,8 +283,8 @@ inoremap <buffer> <silent> <LocalLeader>t2 [ - ]<Left><Left><Left><Left>
280283
"
281284
map <buffer> <silent> <LocalLeader>rr :call BASH_Run("n")<CR>
282285
imap <buffer> <silent> <LocalLeader>rr <Esc>:call BASH_Run("n")<CR>
283-
map <buffer> <silent> <LocalLeader>ra :call BASH_ScriptCmdLineArguments()<CR>
284-
imap <buffer> <silent> <LocalLeader>ra <Esc>:call BASH_ScriptCmdLineArguments()<CR>
286+
map <buffer> <LocalLeader>ra :BashCmdlineArgs<Space>
287+
imap <buffer> <LocalLeader>ra <Esc>:BashCmdlineArgs<Space>
285288
map <buffer> <silent> <LocalLeader>rba :call BASH_BashCmdLineArguments()<CR>
286289
imap <buffer> <silent> <LocalLeader>rba <Esc>:call BASH_BashCmdLineArguments()<CR>
287290

0 commit comments

Comments
 (0)