Skip to content

Instantly share code, notes, and snippets.

@avlok
avlok / sqlite2pg.sh
Created July 7, 2012 23:44 — forked from eclubb/sqlite2pg.sh
Script to import SQLite3 database into PostgreSQL
#!/bin/sh
# This script will migrate schema and data from a SQLite3 database to PostgreSQL.
# Schema translation based on http://stackoverflow.com/a/4581921/1303625.
# Some column types are not handled (e.g blobs).
SQLITE_DB_PATH=$1
PG_DB_NAME=$2
PG_USER_NAME=$3
@avlok
avlok / install_rvm_ruby_192
Created June 28, 2011 19:17
install rvm and ruby 1.9.2 on snow leopard
from https://rvm.beginrescueend.com/rvm/install/
curl -s https://rvm.beginrescueend.com/install/rvm -o rvm-installer ; chmod +x rvm-installer ; rvm_bin_path=~/.rvm/bin rvm_man_path=~/.rvm/share/man ./rvm-installer
echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function' >> ~/.bash_profile
source ~/.bash_profile
rvm install 1.9.2
@avlok
avlok / enableSSH.sh
Created May 24, 2011 17:32
enable ssh on Snow Leopard
sudo launchctl load -w /System/Library/LaunchDaemons/ssh.plist
@avlok
avlok / AppDelegate.lua
Created February 11, 2011 23:56
delegate file for WaxSample project
#import <wax/wax.h>
waxClass{"AppDelegate", protocols = {"UIApplicationDelegate"}}
-- Well done! You are almost ready to run a lua app on your iPhone!
--
-- Just run the app (⌘↵) in the simulator or on a device!
-- You will see a dull, bland "hello world" app (it is your job to spice it up.)
--
-- If your prefer using TextMate to edit the Lua code just type