A collection of random code fragments and wrapper functions. Hopefully one day this will get some order. For now, I'll just throw stuff in here.