Skip to content
View gist:f284901960c55313e306
sudo apt-get install python-software-properties ; add-apt-repository command
sudo add-apt-repository ppa:cassou/emacs
sudo apt-get update
sudo apt-get install emacs24
sudo add-apt-repository ppa:git-core/ppa
sudo apt-get update
sudo apt-get install git
View savings_account.rb
class Account
attr_reader :account_id, :initial_balance
initialize(account_id, initial_balance)
@account_id = account_id
@initial_balance = initial_balance
end
end
class SavingsAccount < Account
View gist:8320251
export LANGUAGE="en_US.UTF-8"
export LANG="en_US.UTF-8"
export LC_ALL="en_US.UTF-8"
sudo su postgres
psql
update pg_database set datistemplate=false where datname='template1';
drop database Template1;
View migration.rb
jruby 1.7.4
rails (4.0.0)
jdbc-postgres (9.2.1002.1)
activerecord-jdbc-adapter (1.2.9.1)
activerecord-jdbcpostgresql-adapter (1.2.9)
undefined method `enable_extension' for #<CreatePosts:0x30186092>org/jruby/RubyBasicObject.java:1696
View routes.rb
resources :sellers, only: [ :index, :show ] do
resources :contracts, shallow: true
end
View gist:5084073
Using rake (10.0.3)
Installing i18n (0.6.4)
Installing minitest (4.6.2)
Installing multi_json (1.6.1)
Installing atomic (1.0.1)
Installing thread_safe (0.1.0)
Installing tzinfo (0.3.36)
Installing activesupport (4.0.0.beta1)
Installing builder (3.1.4)
Installing erubis (2.7.0)
View chat.rb
# coding: utf-8
require 'sinatra'
set server: 'thin', connections: []
get '/' do
halt erb(:login) unless params[:user]
erb :chat, locals: { user: params[:user].gsub(/\W/, '') }
end
get '/stream', provides: 'text/event-stream' do
View readme.md

Wall·E

Ruby powered robots.

Prerequisites

  1. Download and install the Arduio IDE for your OS
  2. Download and unzip Firmata 2.2
  3. Plug in your Arduino via USB
  4. Open the Arduino IDE, select: File > Open > [Path from step 2] > examples > StandardFirmata
View observable_example.rb
# We only care about Tick and Alarm events.
# The Alarm event should only be handled once.
# All other events should be ignored.
require 'observer'
class Clock
include Observable
def tick
View ruby_arduio_meetup.markdown

Prereq

Arduino

What is Arduino?

Arduino is an open-source electronics prototyping platform based on flexible, easy-to-use hardware and software. It's intended for artists, designers, hobbyists, and anyone interested in creating interactive objects or environments.

Something went wrong with that request. Please try again.