I hereby claim:
- I am cousine on github.
- I am cousine (https://keybase.io/cousine) on keybase.
- I have a public key ASCKIJHRzc2i0n3JrN1tYmRZGH2JYXRm6Yr5SpZ7eRkVowo
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
This is a list of resources for learning ruby and advanced topics in Ruby, I'll try to keep it updated and add to it whenever possible.
cd ~ | |
sudo apt-get update | |
sudo apt-get install openjdk-7-jre -y | |
wget https://github.com/downloads/elasticsearch/elasticsearch/elasticsearch-0.19.10.tar.gz -O elasticsearch.tar.gz | |
tar -xf elasticsearch.tar.gz | |
rm elasticsearch.tar.gz | |
sudo mv elasticsearch-* elasticsearch | |
sudo mv elasticsearch /usr/local/share |
Below are steps I followed to get ruby debugger ruby-debug
running with Pow. Based on info from this thread basecamp/pow#43 and this blog post http://flochip.com/2011/04/13/running-pow-with-rdebug/
Assuming you're writing your app in Ruby 1.9 and using Bundler, just add the dependency to your development gems:
/* | |
Search Suggestions | |
Original design by Visual Idiot - http://dribbble.com/shots/377281-Search-Suggestions | |
*/ | |
html { | |
min-height: 100%; | |
background: -webkit-linear-gradient(#dbddde, #b6babb); | |
font-family: Helvetica Neue, Helvetica, Arial, sans-serif; | |
-webkit-font-smoothing: antialiased; |
class MongoidAlpha | |
include Mongoid::Document | |
#include Mongoid::Mebla | |
field :name | |
field :value, :type => Integer | |
field :cost, :type => Float | |
field :hidden | |
#self.whiny_indexing = true | |
# encoding: utf-8 | |
module Mongoid #:nodoc: | |
module Associations #:nodoc: | |
module EmbeddedCallbacks | |
# bubble callbacks to embedded assocaitions | |
def run_callbacks(*args) | |
# now bubble callbacks down | |
self.associations.each_pair do |name, meta| | |
if meta.association == Mongoid::Associations::EmbedsMany |
## Authentasaurus configuration | |
development: &non_production_settings | |
:hashing: "SHA2" # MD5 - SHA1 - SHA2 | |
:mail: | |
:email: &development_email "[email protected]" | |
:host: "http://localhost:3001/" | |
:modules: | |
:remote: | |
:user: | |
:site: "http://localhost:3000/application_name" |
# ---------------------------------- Add in app/controllers/remote_sessions_controller.rb | |
# This will handle the first step of authenticating through a token | |
def authenticate_token | |
# Read the token from the cookie | |
token = Token.authenticate cookies.signed[:provider_token] | |
# Find application in the database | |
current_application = App.find_by_name params[:application] | |
# Get the application url so we can redirect the user back to it. |