This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| imap jj <esc> | |
| set clipboard+=unnamed | |
| " enable vim-surround | |
| set surround | |
| set ignorecase | |
| set smartcase " Case insensitive search with lowercase terms, sensitive with uppercase | |
| set scrolloff=7 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| call plug#begin('~/.local/share/nvim/plugged') | |
| Plug 'ajh17/spacegray.vim' | |
| Plug 'editorconfig/editorconfig-vim' | |
| Plug 'ekalinin/dockerfile.vim' | |
| Plug 'fatih/vim-go' | |
| Plug 'godlygeek/tabular' | |
| Plug 'isobit/vim-caddyfile' | |
| Plug 'jiangmiao/auto-pairs' | |
| Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --bin' } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| call plug#begin('~/.vim/plugged') | |
| Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --bin' } | |
| Plug 'junegunn/fzf.vim' | |
| Plug 'scrooloose/nerdtree' | |
| Plug 'vim-airline/vim-airline' | |
| Plug 'vim-airline/vim-airline-themes' | |
| Plug 'evanmiller/nginx-vim-syntax' | |
| Plug 'fatih/vim-go' | |
| Plug 'jiangmiao/auto-pairs' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * Move image inside <p> tag above the <p> tag while preserving any link around image. | |
| * Can be prevented by adding any attribute or whitespace to <p> tag, e.g. <p class="yolo"> or even <p > | |
| */ | |
| function remove_p_around_img($content) | |
| { | |
| $contentWithFixedPTags = preg_replace_callback('/<p>((?:.(?!p>))*?)(<a[^>]*>)?\s*(<img[^>]+>)(<\/a>)?(.*?)<\/p>/is', function($matches) { | |
| $image = $matches[2] . $matches[3] . $matches[4]; |