Skip to content

Instantly share code, notes, and snippets.

View drylucidity's full-sized avatar

Jop Roskam drylucidity

View GitHub Profile
@nifl
nifl / grok_vi.mdown
Created August 29, 2011 17:23
Your problem with Vim is that you don't grok vi.

Answer by Jim Dennis on Stack Overflow question http://stackoverflow.com/questions/1218390/what-is-your-most-productive-shortcut-with-vim/1220118#1220118

Your problem with Vim is that you don't grok vi.

You mention cutting with yy and complain that you almost never want to cut whole lines. In fact programmers, editing source code, very often want to work on whole lines, ranges of lines and blocks of code. However, yy is only one of many way to yank text into the anonymous copy buffer (or "register" as it's called in vi).

The "Zen" of vi is that you're speaking a language. The initial y is a verb. The statement yy is a simple statement which is, essentially, an abbreviation for 0 y$:

0 go to the beginning of this line. y yank from here (up to where?)

@darcyparker
darcyparker / vimModeStateDiagram.svg
Last active July 15, 2025 05:22
Vim Modes Transition Diagram in SVG https://rawgithub.com/darcyparker/1886716/raw/eab57dfe784f016085251771d65a75a471ca22d4/vimModeStateDiagram.svg Note, most of the nodes in this graph have clickable hyperlinks to documentation.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@dmytro
dmytro / ssh-multi.sh
Created October 31, 2012 03:46
Start multiple synchronized SSH connections with Tmux
#!/bin/bash
# ssh-multi
# D.Kovalov
# Based on http://linuxpixies.blogspot.jp/2011/06/tmux-copy-mode-and-how-to-control.html
# a script to ssh multiple servers over multiple tmux panes
starttmux() {
if [ -z "$HOSTS" ]; then
@livibetter
livibetter / README.rst
Last active January 22, 2021 08:39
Frequency spectrum of sound using PyAudio, NumPy, and Matplotlib
@mattes
mattes / inject_dotfiles.sh
Last active March 26, 2017 20:59
inject minimal set of dotfiles into running docker container (https://github.com/mattes/dotfiles)
current_dir=$(pwd) && \
cd /tmp && \
( curl -L -s -o dotfiles.tar.gz https://github.com/mattes/dotfiles/archive/master.tar.gz > /dev/null 2>&1 || \
wget -O dotfiles.tar.gz https://github.com/mattes/dotfiles/archive/master.tar.gz > /dev/null 2>&1) && \
tar xfz dotfiles.tar.gz && \
cd ./dotfiles-master && \
source docker_dotfiles.sh > /dev/null && \
cd $current_dir && \
unset current_dir && \
rm -rf /tmp/dotfiles-master && \
@natelandau
natelandau / .bash_profile
Last active October 27, 2025 14:01
Mac OSX Bash Profile
# ---------------------------------------------------------------------------
#
# Description: This file holds all my BASH configurations and aliases
#
# Sections:
# 1. Environment Configuration
# 2. Make Terminal Better (remapping defaults and adding functionality)
# 3. File and Folder Management
# 4. Searching
# 5. Process Management
@Dnomyar
Dnomyar / .Xdefaults
Last active April 16, 2022 20:12
My XMonad (xmobar : battery, cpu, memory, volume, time) - ArchLinux
Xcursor.theme: Vanilla-DMZ-AA
!urxvt color scheme:
URxvt*background: #2B2B2B
URxvt*foreground: #DEDEDE
!URxvt*colorUL: #86a2b0
! black
@kyle-ilantzis
kyle-ilantzis / open-w-atom.reg
Last active June 1, 2021 17:20
Adds 'Open in Atom' to context menu in Windows Explorer.
Windows Registry Editor Version 5.00
;
; Adds 'Open in Atom' to context menu (when you right click) in Windows Explorer.
;
; Based on https://github.com/Zren/atom-windows-context-menu. It didn't work
; https://github.com/Zren/atom-windows-context-menu/issues/1.
;
; Save this file to disk with a .reg extension. Replace C:\\Atom\\atom.exe with
; the path to the atom executable on your machine.
@LeCoupa
LeCoupa / bash-cheatsheet.sh
Last active October 23, 2025 20:35
Bash CheatSheet for UNIX Systems --> UPDATED VERSION --> https://github.com/LeCoupa/awesome-cheatsheets
#!/bin/bash
#####################################################
# Name: Bash CheatSheet for Mac OSX
#
# A little overlook of the Bash basics
#
# Usage:
#
# Author: J. Le Coupanec
# Date: 2014/11/04
@romainl
romainl / _rnb.md
Last active June 26, 2025 17:42
RNB, a Vim colorscheme template