Skip to content

Instantly share code, notes, and snippets.

View MicahElliott's full-sized avatar

Micah Elliott MicahElliott

View GitHub Profile
@MicahElliott
MicahElliott / i-get-around.md
Last active December 22, 2015 05:49
I Get Around (a Zsh overview of the chdir family)

I Get Around

We all know how to use cd (aka chdir). It’s probably the first command you ever learned. Or maybe that was ls. Anyway, when paired with some cousins (pushd, popd, dirs, cdpath, chpwd) it’s a lot more capable than you may have realized.

Useful Aliases

I find it tedious to type out all the family (“cd-fam” henceforth) of navigation commands in full length, so let’s start by slimming down – we’re

@MicahElliott
MicahElliott / vimpress.mkd
Created December 21, 2010 04:43
Plain Presentations in Plain Text (PPPT)

Presentations in Plain Text (PPT++)

With some help from Markdown and Vim.

“Hope this makes you chuckle.” —Micah Elliott

@MicahElliott
MicahElliott / clj-fold.vim
Created July 4, 2012 19:42 — forked from dakrone/gist:519858
Automagic Clojure folding on defns and defmacros
" ---------------------------------------------------------------------------
" Automagic Clojure folding on defn's and defmacro's
"
" Blog post: http://writequit.org/blog/?p=413
function GetClojureFold()
if getline(v:lnum) =~ '^\s*(defn.*\s'
return ">1"
elseif getline(v:lnum) =~ '^\s*(def\(macro\|method\|page\|partial\).*\s'
return ">1"
@MicahElliott
MicahElliott / dict-search-arch.md
Created July 10, 2013 00:42
Set up local dictionary search on ArchLinux

Install the dictionary.

% pacman -S words

Make it convenient.

% alias g='grep --color=always --perl-regexp'
% export dict=/usr/share/dict/american-english

Use it.

Keybase proof

I hereby claim:

  • I am MicahElliott on github.
  • I am micahelliott (https://keybase.io/micahelliott) on keybase.
  • I have a public key whose fingerprint is D75C 9C88 9D93 8635 14F3 95F2 C8D4 2FB3 299C 28F0

To claim this, I am signing this object:

@MicahElliott
MicahElliott / arch-augment-vim-for-python.md
Created July 4, 2012 18:01
Configure vim in arch linux for python runtime support

Steps to upgrade vim in arch linux for python runtime support

Python support is needed by vim in order to run things like Conque and Slimv. Arch keeps vim slim by only providing Python support in gvim. But you may prefer vim to gvim, so here's what's needed.

More ABS info.

# Install and run abs (sync)

sudo pacman -S abs

@MicahElliott
MicahElliott / REAMDE.md
Last active November 26, 2019 00:41
Generated User Names by Color

Generated User Names by Color

Good for: demo purposes or seeding a small group of assignable user names/avatars.

I came across a need for a set of neutral generated user names. Pulling them out of a gender-neutral name dictionary was pretty lame. I also wanted some form of distinguishable avatar. This led to looking at a list of web-friendly color names.

@MicahElliott
MicahElliott / .gitignore
Created November 29, 2010 07:14
Python Autotest - Automatically run tests upon detecting writes to source(s).
vids
@MicahElliott
MicahElliott / fnfix.py
Created November 29, 2010 08:27
Fix ugly file names to be UNIX shell-friendly.
#! /usr/bin/env python
"""Fix ugly file names to be UNIX shell-friendly.
PROBLEM
=======
You have files named with funky characters lying around in your
filesystem. Ugly files like "My Document #3 - (2005)[1].txt" are
common when you're sharing directories with Windows users, but you
@MicahElliott
MicahElliott / zbell-long-cmd.zsh
Last active December 22, 2021 23:41
Sound a bell when long-running commands complete
# Original: https://gist.github.com/oknowton/8346801
# Add to zplug:
# zplug MicahElliott/97df9ca799e49c0fcc0a981bf021f813, from:gist, as:plugin, use:zbell-long-cmd.zsh
# brew install terminal-notifier
# only do this if we're in an interactive shell
[[ -o interactive ]] || return