Skip to content

Instantly share code, notes, and snippets.

Kirk Ouimet kirkouimet

View GitHub Profile
branneman /
Last active Jul 7, 2020
Better local require() paths for Node.js

Better local require() paths for Node.js


When the directory structure of your Node.js application (not library!) has some depth, you end up with a lot of annoying relative paths in your require calls like:

const Article = require('../../../../app/models/article');

Those suck for maintenance and they're ugly.

Possible solutions

gregorynicholas / .inputrc
Last active Jul 7, 2020
OSX .inputrc to make terminal way better. and by better i mean i'm naked
View .inputrc
"\e[1~": beginning-of-line
"\e[4~": end-of-line
"\e[5~": history-search-backward
"\e[6~": history-search-forward
"\e[3~": delete-char
"\e[2~": quoted-insert
"\e[5C": forward-word
"\e[5D": backward-word
"\e\e[C": forward-word
"\e\e[D": backward-word
evocateur / fixconsolas
Created Mar 15, 2009
Fix Consolas's line-height on OS X
View fixconsolas
# Requires ftxdumperfuser from
# Usage: fixconsolas [files ...]
# When called with no arguments, it attempts to operate on every TrueType
# file in the current directory.
# References:
You can’t perform that action at this time.