Vim cheat sheet
ysst - surround on current line, ignore whitespace, no indent
y_ou
s_surround(ing)
s_selection
t_ag
ySS - surround, put surrounded text on own line, indent
viwSt
v_isual mode
i_nner
w_ord -keep hitting w to select more words-
S_urround(ing)
t_ag
cs
c_hange
s_urround(ing)
t_ag
Example cs"' will change double quotes to single
ds
d_elete
s_urround(ing)
Example: dst will delete surrounding tags
ds" will delete surrounding double quotes
GET RID OF ^M
type :%s/
press CTRL-VCTRL-M
type //g
press Enter
:set fileencoding=utf-8
" Leave Latin-1 behind, set to UTF-8
:%s/[\u0026]\{1}/\&/g
" Convert ampersands from unicode to HTML
:%s/[\u2026]\{1}/\…/g
" Convert elipses from unicode to HTML
:%s/[\u201C]/\“/g
" Convert double quotes, left from unicode to HTML
:%s/[\u201D]/\”/g
" Convert double quotes, right from unicode to HTML
:%s/[\u2018]/\‘/g
" Convert single quotes, left from unicode to HTML
:%s/[\u2019]/\’/g
" Convert single quotes, right from unicode to HTML
:%s/[\u2013]/\–/g
" Convert N Dashes from unicode to HTML
:%s/--/\–/g
" Convert double dashes to N Dashes from unicode to HTML
:%s/ / /g
" Remove double spaces
:%s/ / /g
" Remove triple spaces
:%s/[\uA0]\{2}/ /g
" Remove double non-breaking spaces
:%s/[\uA0]\{1}/ /g
" Remove single non-breaking spaces
:%s/.*<//
" Delete everything in front of < ex: name <name@domain.com> produces name@domain.com>
:%s/>//
" Delete all instances of > character
:%s/,/\r/g
" Find and replace commas with a linebreak
:%s/\v\d{3}-?\d{4}//g
" delete all 7 digit numbers with dash
%s!^!"!
"add " to the beginning of each line
And for laughs, here’s my .vimrc
set shell=fish
set nocompatible
filetype off
set number
set wrap
set linebreak
set autochdir
set ruler
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
Plugin 'gmarik/Vundle.vim'
Plugin 'tpope/vim-fugitive'
Plugin 'ap/vim-css-color'
Plugin 'tpope/vim-surround'
Plugin 'tpope/vim-repeat'
Plugin 'xolox/vim-misc'
Plugin 'xolox/vim-notes'
Plugin 'jceb/vim-orgmode'
call vundle#end()
syntax enable
colorscheme monokai
filetype plugin indent on
" Brief help
" :PluginList - lists configured plugins
" :PluginInstall - installs plugins; append `!` to update or just :PluginUpdate
" :PluginSearch foo - searches for foo; append `!` to refresh local cache
" :PluginClean - confirms removal of unused plugins; append `!` to auto-approve removal
Photo by Kevin Ku30 Day Creative Cleanse Master Post
Day 1: Assess your sitch + make goals. I do have systems in place but I rarely use it. It almost always seems like it’s more effort to set everything up in The Hit List than it is to do the project but I realize I’m kind of an idiot and can convince myself of damn...
Day 2 of my Creative Business Cleanse
Day 2 Clean your computer Desktop I have my desktop icons hidden because it makes your computer run faster and is way less distracting to look at without them. It was a big mess though so this needed to be done. Started at 2pm with 175 items (including folders named...
Day 1 of my 30-day Creative Business Cleanse
Day 1: Assess Your Sitch If a client order comes through right now, do you have a set system in place to process their project? How structured are the files on your computer? Do you have albums/galleries/folders for different types of images and notes in your phone?...
Dyscalculia and Common Core Math: A history of a failure filled future
or: "Why my children will go to public school only over my stone cold, dead body." Hi, my name is Rebecca and I have dyscalculia. My formative years took place in the 90s and I graduated high school in 2000. I am 31 years old. My ability to add and subtract small...