aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2018-08-06 09:56:57 +1200
committerTom Ryder <tom@sanctum.geek.nz>2018-08-06 09:56:57 +1200
commit4e8a4f0bec4f7cca2884d080978b030dfc1729f0 (patch)
treec97645cd4e581c0405df5690daf9e2646a0f2e44
parentMerge branch 'release/v1.44.0' (diff)
parentBump VERSION (diff)
downloaddotfiles-4e8a4f0bec4f7cca2884d080978b030dfc1729f0.tar.gz
dotfiles-4e8a4f0bec4f7cca2884d080978b030dfc1729f0.zip
Merge branch 'release/v1.46.0'
* release/v1.46.0: Bump VERSION Strip generic greetings from quoted mail Make cursor start heuristics for mail smarter Use ^= instead of += for arbitrary text options Add explicit LC_COLLATE settings to plmu(1df) Remove markdown_autoformat.vim ftplugin Strip a trailing space Use pman as 'keywordprg' for PHP Remove surround.vim's insert mode maps Let's try leaving netrw on again for a bit
-rw-r--r--.gitmodules3
-rw-r--r--VERSION4
-rw-r--r--bin/plmu.sh4
-rw-r--r--vim/after/ftplugin/mail.vim23
-rw-r--r--vim/after/ftplugin/perl.vim2
-rw-r--r--vim/after/ftplugin/php.vim4
-rw-r--r--vim/after/plugin/dist.vim1
-rw-r--r--vim/after/plugin/surround.vim6
m---------vim/bundle/markdown_autoformat0
-rw-r--r--vim/plugin/dist.vim2
-rw-r--r--vim/vimrc16
11 files changed, 42 insertions, 23 deletions
diff --git a/.gitmodules b/.gitmodules
index a695d790..38a03a11 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -61,9 +61,6 @@
[submodule "vim/bundle/make_target"]
path = vim/bundle/make_target
url = https://sanctum.geek.nz/code/vim-make-target.git
-[submodule "vim/bundle/markdown_autoformat"]
- path = vim/bundle/markdown_autoformat
- url = https://sanctum.geek.nz/code/vim-markdown-autoformat.git
[submodule "vim/bundle/perl_version_bump"]
path = vim/bundle/perl_version_bump
url = https://sanctum.geek.nz/code/vim-perl-version-bump.git
diff --git a/VERSION b/VERSION
index a43eacc3..c84e8102 100644
--- a/VERSION
+++ b/VERSION
@@ -1,2 +1,2 @@
-tejr dotfiles v1.44.0
-Sat Aug 4 09:13:25 UTC 2018
+tejr dotfiles v1.46.0
+Sun Aug 5 21:56:57 UTC 2018
diff --git a/bin/plmu.sh b/bin/plmu.sh
index 78778920..06d5ce1d 100644
--- a/bin/plmu.sh
+++ b/bin/plmu.sh
@@ -12,10 +12,10 @@ fi
# Get the list of modules; sort them in case our current locale disagrees on
# the existing sorting
-plenv list-modules | sort |
+plenv list-modules | LC_COLLATE=C sort |
# Exclude any modules in ~/.plenv/non-cpanm-modules if it exists
-comm -23 -- - "$ef" |
+LC_COLLATE=C comm -23 -- - "$ef" |
# Read that list of modules to upgrade and upgrade them one by one
while read -r module ; do
diff --git a/vim/after/ftplugin/mail.vim b/vim/after/ftplugin/mail.vim
index 34c524e1..2917425d 100644
--- a/vim/after/ftplugin/mail.vim
+++ b/vim/after/ftplugin/mail.vim
@@ -3,11 +3,26 @@ if &filetype !=# 'mail' || &compatible || v:version < 700
finish
endif
-" We will almost always want to start editing after the headers, so move to
-" the first entirely blank line, if something hasn't already moved us from the
-" start of the file
+" If something hasn't already moved the cursor, we'll move to an optimal point
+" to start writing
if line('.') == 1 && col('.') == 1
- call search('\m^$', 'c')
+
+ " Start by trying to move to the first quoted line; this may fail if there's
+ " no quote, which is fine
+ call search('\m^>', 'c')
+
+ " Check this line to see if it's a generic hello-name greeting that we can
+ " just strip out; delete the following line too, if it's blank
+ if getline('.') =~? '^>\s*\%(<hello\|hi\)\s\+\S\+\s*$'
+ delete
+ if getline('.') =~# '^>$'
+ delete
+ endif
+ endif
+
+ " Now move to the first quoted or unquoted blank line
+ call search('\m^>\=$', 'c')
+
endif
" Add a space to the end of wrapped lines for format-flowed mail
diff --git a/vim/after/ftplugin/perl.vim b/vim/after/ftplugin/perl.vim
index 777c3ad4..9c3ce6f6 100644
--- a/vim/after/ftplugin/perl.vim
+++ b/vim/after/ftplugin/perl.vim
@@ -1,5 +1,5 @@
" Extra configuration for Perl filetypes
-if &filetype !=# 'perl' || v:version < 700 || &compatible
+if &filetype !=# 'perl' || v:version < 700 || &compatible
finish
endif
diff --git a/vim/after/ftplugin/php.vim b/vim/after/ftplugin/php.vim
index c98c1264..9b7c2bb0 100644
--- a/vim/after/ftplugin/php.vim
+++ b/vim/after/ftplugin/php.vim
@@ -13,6 +13,10 @@ setlocal comments=s1:/*,m:*,ex:*/,://,:#
setlocal formatoptions+=or
let b:undo_ftplugin .= '|setlocal comments< formatoptions<'
+" Use pman as 'keywordprg'
+setlocal keywordprg=pman
+let b:undo_ftplugin .= '|setlocal keywordprg<'
+
" Stop here if the user doesn't want ftplugin mappings
if exists('g:no_plugin_maps') || exists('g:no_php_maps')
finish
diff --git a/vim/after/plugin/dist.vim b/vim/after/plugin/dist.vim
index 4613925f..bc8995b6 100644
--- a/vim/after/plugin/dist.vim
+++ b/vim/after/plugin/dist.vim
@@ -2,7 +2,6 @@
unlet! g:loaded_getscriptPlugin
unlet! g:loaded_vimballPlugin
unlet! g:loaded_logiPat
-unlet! g:loaded_netrwPlugin
unlet! g:loaded_rrhelper
unlet! g:loaded_spellfile_plugin
unlet! g:loaded_gzip
diff --git a/vim/after/plugin/surround.vim b/vim/after/plugin/surround.vim
new file mode 100644
index 00000000..b1face5f
--- /dev/null
+++ b/vim/after/plugin/surround.vim
@@ -0,0 +1,6 @@
+" Remove surround.vim's insert mode maps
+iunmap <Plug>ISurround
+iunmap <Plug>Isurround
+iunmap <C-G>S
+iunmap <C-G>s
+iunmap <C-S>
diff --git a/vim/bundle/markdown_autoformat b/vim/bundle/markdown_autoformat
deleted file mode 160000
-Subproject dc5d96400412f63a170e87bc7e947743df07b76
diff --git a/vim/plugin/dist.vim b/vim/plugin/dist.vim
index 53962c93..ac3671a2 100644
--- a/vim/plugin/dist.vim
+++ b/vim/plugin/dist.vim
@@ -8,8 +8,6 @@ let g:loaded_tarPlugin = 1
let g:loaded_zipPlugin = 1
" I prefer filtering text with Unix tools
let g:loaded_logiPat = 1
-" The shell, tab completion, and 'wildmenu' are good enough
-let g:loaded_netrwPlugin = 1
" I don't use Vim servers
let g:loaded_rrhelper = 1
" I don't need extra spelling files
diff --git a/vim/vimrc b/vim/vimrc
index 6b181fa7..e9fbaf3f 100644
--- a/vim/vimrc
+++ b/vim/vimrc
@@ -49,8 +49,8 @@ set backup
set backupdir^=~/.vim/cache/backup,~/vimfiles/cache/backup
" Add some paths not to back up
-set backupskip+=/dev/shm/*
-set backupskip+=/var/tmp/*
+set backupskip^=/dev/shm/*
+set backupskip^=/var/tmp/*
" Indent wrapped lines
silent! set breakindent
@@ -113,11 +113,11 @@ set lazyredraw
set linebreak
" Define extra 'list' display characters
-set listchars+=extends:> " Unwrapped text to screen right
-set listchars+=precedes:< " Unwrapped text to screen left
-set listchars+=tab:>- " Tab characters, preserve width
-set listchars+=trail:_ " Trailing spaces
-silent! set listchars+=nbsp:+ " Non-breaking spaces
+set listchars^=extends:> " Unwrapped text to screen right
+set listchars^=precedes:< " Unwrapped text to screen left
+set listchars^=tab:>- " Tab characters, preserve width
+set listchars^=trail:_ " Trailing spaces
+silent! set listchars^=nbsp:+ " Non-breaking spaces
" Don't allow setting options via buffer content
set nomodeline
@@ -127,7 +127,7 @@ set nrformats-=octal
" Options for file search with gf/:find
set path-=/usr/include " Let the C/C++ filetypes set that
-set path+=** " Search current directory's whole tree
+set path^=** " Search current directory's whole tree
" Don't show startup splash screen (I donated)
set shortmess+=I