This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ sudo aptitude update | |
$ sudo aptitude install build-essential openssl libreadline6 libreadline6-dev zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev libxslt1-dev autoconf libc6-dev libncurses5-dev automake libtool bison subversion | |
$ cd | |
$ git clone git://github.com/sstephenson/rbenv.git .rbenv | |
$ echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc | |
$ echo 'eval "$(rbenv init -)"' >> ~/.bashrc | |
$ git clone git://github.com/sstephenson/ruby-build.git | |
$ cd ruby-build | |
$ sudo ./install.sh | |
$ rbenv install 1.9.3-p125 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class Fuse4x < Formula | |
homepage 'http://fuse4x.org/' | |
url 'https://github.com/fuse4x/fuse.git', :tag => "fuse4x_0_9_0" | |
version "0.9.0" | |
depends_on 'gettext' | |
depends_on 'fuse4x-kext' | |
depends_on "automake" => :build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var str = "/activity_sets/:activity_set_id/activity_set_annotations/:id/edit John Smith" | |
, repl = { | |
"11": ":activity_set_id", | |
"1": ":id", | |
"$2, $1": new RegExp("(John)\\s(Smith)", "gi") | |
}; | |
function multi_replace(str, repl) { | |
if (!str) return str; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var newPetitionListener = function (e) { | |
newPetition(win, params); | |
} | |
, cameraView = Ti.UI.createView({ | |
width: 95, | |
height: 50, | |
bottom: 0 | |
}); | |
cameraView.addEventListener("click", newPetitionListener); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* defineClass( ) -- a utility function for defining JavaScript classes. | |
* | |
* This function expects a single object as its only argument. It defines | |
* a new JavaScript class based on the data in that object and returns the | |
* constructor function of the new class. This function handles the repetitive | |
* tasks of defining classes: setting up the prototype object for correct | |
* inheritance, copying methods from other types, and so on. | |
* | |
* The object passed as an argument should have some or all of the |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Valida campos usando un objeto, evalua expresiones regulares, si el campo | |
* es requerido o no, mensajes por cada campo, tambien crea un elemento <span> | |
* al lado del campo que tiene errores con el mensaje de error. | |
* | |
* // Ejemplo | |
* var reglas = { | |
* 'elementos': { | |
* 'formPlanillaenlinea:tiposIngresoTemp': { | |
* 'requerido': true, // Puede ser un boolean o un objeto si es necesario evaluar otro campo asociado a este: { 'el': '#formPlanillaenlinea\\:novedadVST', 'selector': ':checked' } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ brew install soprano | |
==> Downloading http://downloads.sourceforge.net/project/soprano/Soprano/2.6.0/soprano-2.6.0.tar.bz2 | |
File already downloaded in /Users/nebiros/Library/Caches/Homebrew | |
==> cmake . -DCMAKE_INSTALL_PREFIX='/usr/local/Cellar/soprano/2.6.0' -DCMAKE_BUILD_TYPE=None -Wno-dev | |
-- The C compiler identification is GNU | |
-- The CXX compiler identification is GNU | |
-- Checking whether C compiler has -isysroot | |
-- Checking whether C compiler has -isysroot - yes | |
-- Checking whether C compiler supports OSX deployment target flag | |
-- Checking whether C compiler supports OSX deployment target flag - yes |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# clone svn repo, -s means standar svn repo (trunk, branches, tags) | |
$ git svn clone file:///tmp/test-svn -s | |
# branches list | |
$ git branch -a | |
$ git repack -d | |
# creates and jump to the new branch | |
$ git checkout -b new_branch | |
# add changes | |
$ git add <FILE> | |
# commit changes to the current branch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ brew install -vd emacs --cocoa --srgb | |
==> Downloading http://ftp.gnu.org/pub/gnu/emacs/emacs-23.3.tar.bz2 | |
File already downloaded in /Users/nebiros/Library/Caches/Homebrew | |
/usr/bin/tar xf /Users/nebiros/Library/Caches/Homebrew/emacs-23.3.tar.bz2 | |
==> Downloading patches | |
/usr/bin/curl -f#LA Homebrew 0.8 (Ruby 1.8.7-249; Mac OS X 10.7) http://repo.or.cz/w/emacs.git/commitdiff_plain/c8bba48c5889c4773c62a10f7c3d4383881f11c1 -o 001-homebrew.diff https://raw.github.com/gist/1012927 -o 002-homebrew.diff | |
######################################################################## 100.0% | |
######################################################################## 100.0% | |
==> Patching | |
/usr/bin/patch -f -p1 -i 001-homebrew.diff |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<VirtualHost *:80> | |
ServerName ##APP_DOMAIN## | |
ServerAlias www.##APP_DOMAIN## | |
ServerAlias ##APPLICATION_ENV##.www.##APP_DOMAIN## | |
ServerAlias ##APPLICATION_ENV##.##APP_DOMAIN## | |
ServerAdmin admin@##APP_DOMAIN## | |
SetEnv APPLICATION_ENV ##APPLICATION_ENV## | |
SetEnv SERVER_HOSTNAME ##SERVER_HOSTNAME## | |
Header append X-Host-List "%{SERVER_HOSTNAME}e" |