Skip to content

Instantly share code, notes, and snippets.

@ZenToad
ZenToad / .vimrc
Created June 18, 2018 15:23
linux vimrc
" An example for a vimrc file.
"
" Maintainer: Bram Moolenaar <[email protected]>
" Last change: 2011 Apr 15
"
" To use it, copy it to
" for Unix and OS/2: ~/.vimrc
" for Amiga: s:.vimrc
" for MS-DOS and Win32: $VIM\_vimrc
@ZenToad
ZenToad / Install.bash
Created May 16, 2018 16:55 — forked from blachniet/Install.bash
Install pip packages in an offline environment
# 1. On a internet-connected device, download the package and its dependencies to a directory
mkdir pip-es-curator
pip install --ignore-installed -d ./pip-es-curator elasticsearch-curator
# 2. Move the directory containing the packages to the offline device
# 3. On the offline device, install the package from the transferred directory
pip install --no-index --find-links ./pip-es-curator elasticsearch-curator
@ZenToad
ZenToad / gameloop.cpp
Created March 23, 2018 22:50
Mortis game loop template
#define STB_TRUETYPE_IMPLEMENTATION
#define STB_IMAGE_IMPLEMENTATION
#include "glm/glm/glm.hpp"
#include "glm/glm/ext.hpp"
#include "stb/stb_truetype.h"
#include "stb/stb_image.h"
#include "zen/sdlu.h"
@ZenToad
ZenToad / rPrint example.txt
Created July 28, 2017 18:20 — forked from stuby/rPrint example.txt
This is a handy recursive data printer.
> rPrint({first={true,1.3,"abc",{1,2,5}},22,33,last={nil,5},2},nil,"Junk")
Junk table
Junk [1] number 22
Junk [2] number 33
Junk [3] number 2
Junk [last] table
Junk [last] [2] number 5
Junk [first] table
Junk [first] [1] boolean true
Junk [first] [2] number 1.3
# on hostA, the initial home of the repo
hostA$ git bundle create hostA.bundle --branches --tags
# transfer the bundle to hostB, and continue:
hostB$ git clone /path/to/hostA.bundle my-repo
# you now have a clone, complete with remote branches and tags
# just to make it a little more obvious, rename the remote:
hostB$ git remote rename origin hostA
# make some commits on hostB; time to transfer back to hostA