Skip to content

Instantly share code, notes, and snippets.

View Goles's full-sized avatar

Nicolas Goles Goles

View GitHub Profile
#!/bin/bash
# This should work whether you are already in a TMUX session or not...
# Irssi directory is assumed to be in the user's home dir
if [ -z "$TMUX" ]
then
tmux new-session -d -s ircuser
tmux split-window -tircuser -h -l20
tmux send-keys -tircuser "tmux send-keys -t0 \"irssi\" C-m; \
tmux send-keys -t0 \"/set nicklist_height \$(stty size | cut -f1 -d' ' -)\" C-m; \
tmux send-keys -t0 \"/set nicklist_width \$(stty size | cut -f2 -d' ' -)\" C-m; \
@Goles
Goles / tmux.conf
Created March 31, 2013 19:24
My tmux conf
###
### Nicolas Goles tmux config file.
###
set-option -g default-command "reattach-to-user-namespace -l zsh"
set -g default-terminal "screen-256color"
set -g history-limit 20000
set-option -ga update-environment ' LANG'
set-option -ga update-environment ' LC_ALL'
// In my Core Data Model a Category has a one to many relation with CategoryMembers
- (void) loadCoreDataFromJSONArray:(NSArray *) jsonArray
{
[jsonArray enumerateObjectsUsingBlock:^(id obj, NSUInteger idx, BOOL *stop) {
// Create our category
Category *category = [NSEntityDescription insertNewObjectForEntityForName:@"Category" inManagedObjectContext:self.managedObjectContext];
category.name = [obj objectForKey:@"name"];
// Traverse the category members
NSArray *membersArray = [obj objectForKey:@"members"];
@Goles
Goles / vim.rb
Created May 4, 2012 19:23
Vim formula for brew for Snow Leopard with osx-gcc-installer
require 'formula'
class Vim < Formula
homepage 'http://www.vim.org/'
url 'https://vim.googlecode.com/hg/', :revision => 'f1f6ac67acd8'
version '7.3.462'
def features; %w(tiny small normal big huge) end
def interp; %w(lua mzscheme perl python python3 tcl ruby) end
@Goles
Goles / vim.rb
Created April 28, 2012 01:04 — forked from mgrouchy/vim.rb
Vim formula for Homebrew < AD Default
require 'formula'
class Vim < Formula
homepage 'http://www.vim.org/'
url 'https://vim.googlecode.com/hg/', :revision => 'f1f6ac67acd8'
version '7.3.462'
def features; %w(tiny small normal big huge) end
def interp; %w(lua mzscheme perl python python3 tcl ruby) end
@Goles
Goles / vim.rb
Created April 28, 2012 00:02 — forked from smartinez87/vim.rb
Vim formula for Homebrew
require 'formula'
class Vim < Formula
homepage 'http://www.vim.org/'
url 'ftp://ftp.vim.org/pub/vim/unix/vim-7.3.tar.bz2'
head 'https://vim.googlecode.com/hg/'
sha256 '5c5d5d6e07f1bbc49b6fe3906ff8a7e39b049928b68195b38e3e3d347100221d'
version '7.3.487'
def features; %w(tiny small normal big huge) end
$ tmux list-windows
0: tmux [208x73] [layout b147,208x73,0,0[208x62,0,0,208x10,0,63{104x10,0,63,103x10,105,63}]] (active)
➜ ~ rvm get stable && rvm get head
Original installed RVM version:
rvm 1.10.2 by Wayne E. Seguin <wayneeseguin@gmail.com>, Michal Papis <mpapis@gmail.com> [https://rvm.beginrescueend.com/]
Downloading RVM from wayneeseguin branch stable
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 829k 100 829k 0 0 105k 0 0:00:07 0:00:07 --:--:-- 168k
Usage:
rvm get {stable|latest|x.y.z|head|master|branch|help} [--auto]
Options:
stable - git clone and install the latest RVM repository stable branch.
latest - download and install the latest RVM release listed by
https://rvm.beginrescueend.com/releases/stable-version.txt
@Goles
Goles / engine_template_generator.py
Created August 16, 2011 09:20
Gando Games Automatic Engine Template Generation
#!/usr/bin/python
import shutil
import sys
import os
import subprocess
ROOT_PATH = "GGEngine/"
SRC_PATH = "src/gengine"
GG_USERNAME = "username"
GIT_REPO_URL = "ssh://" + GG_USERNAME + "@gandogames.com/path/to/engine.git "