dot

packages and services management
Log | Files | Refs | README

commit a59370d7afc5be8b69dd02ae343fdbe76810fa7f
parent 40ef9b1c1232dc0d11493b0c1ca175b6e6d4bfc3
Author: josuah <mail@josuah.net>
Date:   Fri,  2 Sep 2016 20:01:53 +0200

Merge branch 'master' of https://github.com/sshbio/Config

Diffstat:
Mbin/comment | 2++
Dbin/headline | 26--------------------------
Ms-nail/.mailrc | 2+-
Mvim/.vimrc | 36+++++++++++++++++++++++++++++++-----
4 files changed, 34 insertions(+), 32 deletions(-)

diff --git a/bin/comment b/bin/comment @@ -7,6 +7,8 @@ # \____\ \____/ \/ \/ \/ \/ \/ \/ \___\ \/ \/ \/ #=============================================================================== +NL=' +' help=' ' NL=' diff --git a/bin/headline b/bin/headline @@ -1,26 +0,0 @@ -#!~/bin/sh -# headline - Insert a header line with info on file 2016/08/16 -# /\ /\ /\ __ -# / /_ ___ _____ ___/ // / \/ ____ ___ -# / __ \ .'__ \ .'__ /.'__ // / /\ / __ \ .'__ \ -# / / / // ____// /_/ // /_/ // / / // / / // ____/ -# \/ \/ \___\ \____/ \____/ \/ \/ \/ \/ \___\ -#=============================================================================== -# -# Format: <comment char> <filename> - <description> <last edit date> -# -# 80 column wide with the date right aligned, no space before comment char. -# It must be the first line of the file, or the second if there is a shebang. - -read -r line - -skip=0 action='append' -case line in -'#!*' ) - skip=1 - read line - ;; -'* - *[0-9][0-9][0-9][0-9]/[0-9][0-9]/[0-9][0-9]' ) - - ;; -esac diff --git a/s-nail/.mailrc b/s-nail/.mailrc @@ -116,7 +116,7 @@ set pipe-application/pdf="cat > \"${TMPDIR}/${NAIL_FILENAME_GENERATED}\"; \ # s-it-mode -# Macros +# MACROS #------------------------------------------------------------------------------- # If threaded mode is activated, automatically collapse thread diff --git a/vim/.vimrc b/vim/.vimrc @@ -10,25 +10,45 @@ "------------------------------------------------------------------------------- " Behavior -set autoindent copyindent +set autoindent copyindent laststatus=2 ruler " Text display -set showmatch list listchars=tab:>\ ,eol:$ +set showmatch list listchars=tab:>\ ,eol:$ hlsearch " Interface set ruler number colorcolumn=80 +" FUNCTIONS +"------------------------------------------------------------------------------- + +function! FzyCommand(choice_command, vim_command) + try + let output = system(a:choice_command . " | fzy ") + catch /Vim:Interrupt/ + " Swallow errors from ^C, allow redraw! below + endtry + redraw! + if v:shell_error == 0 && !empty(output) + exec a:vim_command . ' ' . output + endif +endfunction + + " MAPPINGS "------------------------------------------------------------------------------- map <Space> : map <Space><Space> : map <Space>s :set -map <Space>w :w<CR> +map <Space>w :w<cr> +map <Space>e :call FzyCommand("find -type f", ":e")<cr> +map <Space>v :call FzyCommand("find -type f", ":vs")<cr> +map <Space>g :exec ':' system("swiper '" . expand("%:p") . "'")<cr> -map col :set list! <CR>:set list? <CR> -map con :set number!<CR>:set number?<CR> +map col :set list! <cr>:set list? <cr> +map con :set number!<cr>:set number?<cr> +map cop :set paste! <cr>:set paste? <cr> map ]<Space> mzo<Esc>k`z map [<Space> mzO<Esc>k`z<C-e> @@ -46,3 +66,9 @@ iabbrev =_ <Esc>v0x80a=<esc>gvpA highlight NonText cterm=bold ctermfg=0 highlight SpecialKey cterm=bold ctermfg=0 + + +" PLUGINS +"------------------------------------------------------------------------------- + +pathogen#infect()