Skip to content

Instantly share code, notes, and snippets.

View AndreiRailean's full-sized avatar
🏠
Working from home

Andrei Railean AndreiRailean

🏠
Working from home
View GitHub Profile
@AndreiRailean
AndreiRailean / echoHttpRequest.js
Last active August 29, 2015 14:23 — forked from Marak/echoHttpRequest.js
Echo HTTP requests
module['exports'] = function echoHttp (hook) {
hook.debug("Debug messages are sent to the debug console");
hook.debug(hook.params);
hook.debug(hook.req.path);
hook.debug(hook.req.method);
@AndreiRailean
AndreiRailean / pg.sh
Last active August 29, 2015 14:11 — forked from cjolly/pg.sh
mac upgrade postgres to 9.4.0 after automatic homebrew upgrade
newpg=9.4.0
oldpg=9.3.5_1 # set this to your current PG version
# Stop current Postgres server
# launchctl unload ~/Library/LaunchAgents/homebrew.mxcl.postgresql.plist
# Backup current db
mv /usr/local/var/postgres/ /usr/local/var/postgres-$oldpg
# Homebrew
require 'rubygems'
require 'sinatra'
require 'redis'
# To use, simply start your Redis server and boot this
# example app with:
# ruby example_note_keeping_app.rb
#
# Point your browser to http://localhost:4567 and enjoy!
#