Skip to content

Instantly share code, notes, and snippets.

View romainl's full-sized avatar
💰
Alwayz Into Somethin'

Romain Lafourcade romainl

💰
Alwayz Into Somethin'
  • Razorfish France
  • Paris, France
View GitHub Profile
@romainl
romainl / gist:9970697
Last active March 21, 2024 09:00
How to use Tim Pope's Pathogen

How to use Tim Pope’s Pathogen

I’ll assume you are on Linux or Mac OSX. For Windows, replace ~/.vim/ with $HOME\vimfiles\ and forward slashes with backward slashes.

The idea

Vim plugins can be single scripts or collections of specialized scripts that you are supposed to put in “standard” locations under your ~/.vim/ directory. Syntax scripts go into ~/.vim/syntax/, plugin scripts go into ~/.vim/plugin, documentation goes into ~/.vim/doc/ and so on. That design can lead to a messy config where it quickly becomes hard to manage your plugins.

This is not the place to explain the technicalities behind Pathogen but the basic concept is quite straightforward: each plugin lives in its own directory under ~/.vim/bundle/, where each directory simulates the standard structure of your ~/.vim/ directory.

@romainl
romainl / gist:1f93db9dc976ba851bbb
Last active March 13, 2024 23:15
Vim: available key pairs in normal mode…

Vim: available key pairs in normal mode

All lowercase

The operators c, d, and y expect a motion, like w, e, etc. The second character in the following pairs is not a motion so it is a NOP and nothing is overridden if we use them in mappings.

cd cm co cp cq cr cs cu cx cy cz

dc dm dq dr ds du dx dy dz
@romainl
romainl / deprecation.md
Last active February 24, 2022 02:42
Idiomatic vimrc
Large Object Motions:
(
)
{
}
[[
[]
][
]]
[m
@romainl
romainl / gist:2e1f7936f8179b38f84b
Last active August 29, 2015 14:10 — forked from dahu/gist:f3f8dd2b93db253c1c1d
Possible Title Ideas

Possible Title Ideas

  • The Patient Vimmer
  • Vim from the Bottom Up
  • The Competent Vimmer
  • Versed in Vim
  • Cultivating Vimmers
  • Grooming Vimmers
  • The Vim of Editing
  • Vim is Beautiful -- Editing as if People Mattered
@romainl
romainl / 256color.pl
Last active August 29, 2015 14:14 — forked from hSATAC/256color.pl
#!/usr/bin/perl
# Author: Todd Larason <jtl@molehill.org>
# $XFree86: xc/programs/xterm/vttests/256colors2.pl,v 1.2 2002/03/26 01:46:43 dickey Exp $
# use the resources for colors 0-15 - usually more-or-less a
# reproduction of the standard ANSI colors, but possibly more
# pleasing shades
# colors 16-231 are a 6x6x6 color cube
for ($red = 0; $red < 6; $red++) {
TabLineFill _TabLineFill ModeMsg _ModeMsg
TabLine _TabLine DiffAdd _DiffAdd
LineNr _LineNr Search _Search
Ignore _Ignore PmenuSel _PmenuSel
CursorColumn _CursorColumn PmenuThumb _PmenuThumb
CursorLine _CursorLine CursorLineNr _CursorLineNr
SignColumn _SignColumn TabLineSel _TabLineSel
Pmenu _Pmenu Visual _Visual
FoldColumn _FoldColumn WildMenu _WildMenu
Folded _Folded DiffText _DiffText
@romainl
romainl / _rnb.md
Last active August 12, 2021 21:56
RNB, a Vim colorscheme template
@romainl
romainl / list.md
Last active November 7, 2021 20:57
Show ]I, [I, ]D, [D, :ilist and :dlist results — even spanning multiple files — in the quickfix window.
@romainl
romainl / .slate
Created May 6, 2015 15:52
My Slate config
# ~/.slate
# Aliases
alias top-left screenOriginX+screenSizeX/8;screenOriginY+screenSizeY/8
alias width-height (screenSizeX/8)*6;(screenSizeY/8)*6
# Config
config defaultToCurrentScreen true
config resizePercentOf screenSize