Skip to content

Instantly share code, notes, and snippets.

View coder36's full-sized avatar

Mark Middleton coder36

  • Newcastle
View GitHub Profile
@coder36
coder36 / gist:6616612
Last active December 23, 2015 09:48
Vim productivity
Ruby actor frameword - celluloid celluloid:io
Ruby productivity using vim and tmux
====================================
http://www.youtube.com/watch?v=vHdiXoHKSgU
vim - filesearch ctrlp https://github.com/kien/ctrlp.vim
vim - search withi files AG https://github.com/rking/ag.vim
@coder36
coder36 / gist:6800743
Last active December 24, 2015 12:49
Setup tmux v1.8
This installs version 1.8 of tmux:
sudo apt-get install libevent-dev libncurses-dev
git clone git://git.code.sf.net/p/tmux/tmux-code tmux
cd tmux
git checkout 1.8
autoreconf -fis
./configure
make
sudo make install
@coder36
coder36 / gist:6935492
Last active December 25, 2015 06:58
Rails notes
/sbin/ifconfig |grep inet|sed 's/\:/ /'|awk '{print $3}'|grep -v 127.0.0 | grep -v :: | tr "\\n" " "
1) sudo apt-get install openvpn
2) Use Tinyca to create: CA, OpenVPN cert and key and Client cert and key
3) Edit /etc/openvpn/server.conf
Edit section as follows:
# Push routes to the client to allow it
# to reach other private subnets behind
@coder36
coder36 / gist:9913314
Created April 1, 2014 12:50
Database notes
If you get output looking like:
ID
----------
9.1E+10
then you can set the output width using: set NUMWIDTH 20
ID
@coder36
coder36 / gist:10986249
Last active August 29, 2015 13:59
Baking up an MBR

Baking up an MBR

guide

The MBR is stored in the the first 512 bytes of the disk. It consist of 3 parts:

|-----------------------446 bytes bootloader--------------------|------64 bytes partition table-------|-id-|

@coder36
coder36 / gist:7b7479c48d996a83bed0
Last active August 29, 2015 14:01
Setting up Gitlab on Centos 6.5

Setting up Gitlab on Centos 6.5

Based on this guide

Notes:

     root / 5iveL!fe
@coder36
coder36 / gist:105240448ad95ec2aa3c
Last active August 29, 2015 14:01
Ansible Spike

Setup

[ansible github] (https://github.com/ansible/ansible)

sudo yum install rpm-build make python2-devel asciidoc python-setuptools PyYAML python-crypto2.6 python-httplib2  python-jinja2  python-keyczar sshpass
git clone git://github.com/ansible/ansible.git
cd ./ansible
git checkout release1.6.2

make rpm