Skip to content

Instantly share code, notes, and snippets.

@Houl
Houl / matchr.vim
Created February 21, 2021 21:30
Reverse match()
" File: matchr.vim
" Created: 2020 Jul 30
" Last Change: 2020 Aug 02
" Version: 0.3
" Author: Andy Wokula <anwoku@yahoo.de>
" License: Vim License, see :h license
" NvMatchReverse({str}, {pat})
"
" like match({str}, {pat}), but return the position of the right-most
@Houl
Houl / stickydigraphs.vim
Created June 11, 2020 19:02
Sticky digraphs
" File: D2567.vim
" Created: 2020 Jun 11
" Last Change: 2020 Jun 11
" Version: 0.1
" Author: Andy Wokula <anwoku@yahoo.de>
" License: Vim License, see :h license
" Provides: sticky-digraphs
" Usage: (Insert mode)
"
@Houl
Houl / D2190.vim
Created August 11, 2019 16:45
HasPatchExpr()
" File: D2190.vim
" Created: 2017 Jun 30
" Last Change: 2018 May 15
" Version: 0.5
" Author: Andy Wokula <anwoku@yahoo.de>
" License: Vim License, see :h license
" Dependencies: (by :PutDepend)
" CallOverloaded()
" HasPatchExpr({vimver}, {patchnr})
@Houl
Houl / overload.vim
Created August 11, 2019 16:39
CallOverloaded()
" Emulate function overloading.
" File: overload.vim
" Created: 2014 Aug 01
" Last Change: 2018 Nov 18
" Version: 0.9
" Author: Andy Wokula <anwoku@yahoo.de>
" License: Vim License, see :h license
" CallOverloaded({func-dict}, {arg-list}, {dict})
"
@Houl
Houl / cxf_mod.vim
Created May 17, 2019 17:29
Restore environment var name after filename completion
" Vim plugin - restore environment var name after filename completion
" General: "{{{
" File: cxf_mod.vim
" Created: 2008 Jul 06
" Last Change: 2017 Oct 14
" Version: 0.6
" Author: Andy Wokula <anwoku@yahoo.de>
" License: Vim license
" Description:
@Houl
Houl / mtc147.vim
Created May 6, 2019 18:48
Star-search with 'iskeyword' temporarily set to additional characters.
" File: mtc147.vim
" Created: 2019 May 06
" Last Change: 2019 May 06
" Version: 0.1
" Author: Andy Wokula <anwoku@yahoo.de>
" License: Vim License, see :h license
" Description:
" Star-search with 'iskeyword' temporarily set to additional characters.
@Houl
Houl / D2307.vim
Created June 29, 2018 19:14
Virtcols2Vartabs()
" File: D2307.vim
" Created: 2018 Jun 29
" Last Change: 2018 Jun 29
" Version: 0.1
" Author: Andy Wokula <anwoku@yahoo.de>
" License: Vim License, see :h license
" Virtcols2Vartabs({virt-columns}) (copy)
"
" return differences list (list of number) from explicit virtual columns,
@Houl
Houl / vimrc.vim
Last active November 7, 2017 19:52
User's vimrc piece, supporting the modified ftplugin/python.vim
let g:no_bracket_maps = 1
map <expr> ]] repmo#Key('<Plug>]]-motion', '<Plug>[[-motion')|sunmap ]]
map <expr> [[ repmo#Key('<Plug>[[-motion', '<Plug>]]-motion')|sunmap [[
map <expr> ][ repmo#Key('<Plug>][-motion', '<Plug>[]-motion')|sunmap ][
map <expr> [] repmo#Key('<Plug>[]-motion', '<Plug>][-motion')|sunmap []
map <expr> ]m repmo#Key('<Plug>]m-motion', '<Plug>[m-motion')|sunmap ]m
map <expr> [m repmo#Key('<Plug>[m-motion', '<Plug>]m-motion')|sunmap [m
map <expr> ]M repmo#Key('<Plug>]M-motion', '<Plug>[M-motion')|sunmap ]M
map <expr> [M repmo#Key('<Plug>[M-motion', '<Plug>]M-motion')|sunmap [M
@Houl
Houl / python.vim
Last active November 7, 2017 19:54
Modified Python ftplugin script (embedded comments)
" Vim filetype plugin file
" Language: python
" Maintainer: Tom Picton <tom@tompicton.co.uk>
" Previous Maintainer: James Sully <sullyj3@gmail.com>
" Previous Maintainer: Johannes Zellner <johannes@zellner.org>
" Last Change: Fri, 20 October 2017
" https://github.com/tpict/vim-ftplugin-python
if exists("b:did_ftplugin") | finish | endif
let b:did_ftplugin = 1
@Houl
Houl / cdsubproject.vim
Last active October 21, 2017 19:40
Autocd to project's subdir
" Created: 2017 Oct 21
" Last Change: 2017 Oct 21
" Version: 0.1
" Author: Andy Wokula <anwoku@yahoo.de>
" License: Vim License, see :h license
" should be a full-qualified existing directory
if !exists("g:projects_dir")
let g:projects_dir = expand('$HOME/code/git')
endif