Skip to content

Instantly share code, notes, and snippets.

View georgeredinger's full-sized avatar
💭
Coding

George Redinger georgeredinger

💭
Coding
View GitHub Profile
set :sync_directories, ["public/assets", "public/galleries"]
set :sync_backups, 3
set :sync_directories, ["public/assets", "public/galleries"]
set :sync_backups, 3
@georgeredinger
georgeredinger / ubuntu-11.10-gems.erb
Created November 2, 2011 14:21 — forked from kashif/ubuntu-11.10-gems.erb
Chef bootstrap With rvm and ruby 1.9.2 on ubuntu 11.10
bash -c '
<% if knife_config[:bootstrap_proxy] -%>
(
cat <<'EOP'
<%= "proxy = #{knife_config[:bootstrap_proxy]}" %>
EOP
) > ~/.curlrc
<% end -%>
if [ ! -f /usr/bin/chef-client ]; then
@georgeredinger
georgeredinger / Guardfile
Created April 5, 2012 16:36 — forked from drnic/Guardfile
An example Guardfile with the works for a Rails app
guard 'rspec', :version => 2 do
watch(%r{^spec/.+_spec\.rb$})
watch(%r{^lib/(.+)\.rb$}) { |m| "spec/lib/#{m[1]}_spec.rb" }
watch('spec/spec_helper.rb') { "spec" }
# Rails example
watch(%r{^app/(.+)\.rb$}) { |m| "spec/#{m[1]}_spec.rb" }
watch(%r{^app/(.*)(\.erb|\.haml)$}) { |m| "spec/#{m[1]}#{m[2]}_spec.rb" }
watch(%r{^app/controllers/(.+)_(controller)\.rb$}) { |m| ["spec/routing/#{m[1]}_routing_spec.rb", "spec/#{m[2]}s/#{m[1]}_#{m[2]}_spec.rb", "spec/acceptance/#{m[1]}_spec.rb"] }
watch(%r{^spec/support/(.+)\.rb$}) { "spec" }
@georgeredinger
georgeredinger / setup.md
Created June 23, 2012 23:14 — forked from leesmith/setup.md
Ruby on Rails development setup on Ubuntu 12.04 (vim, git, rbenv)

Ruby on Rails development setup on Ubuntu 12.04

System update

# change mirror to ubuntu.osuosl.org first
sudo apt-get update

Install common libraries

sudo apt-get install build-essential libreadline-dev libssl-dev zlib1g-dev libxml2-dev libxslt-dev

@georgeredinger
georgeredinger / mouse.js
Created July 15, 2012 16:44 — forked from bfncs/mouse.js
Read Linux mouse(s) in node.js
/**
* Read Linux mouse(s) in node.js
* Author: Marc Loehe ([email protected])
*
* Adapted from Tim Caswell's nice solution to read a linux joystick
* http://nodebits.org/linux-joystick
* https://github.com/nodebits/linux-joystick
*/
var fs = require('fs'),
#!/bin/sh
SOURCE=""
if [ $# -gt 1 ]
then
SOURCE="--source ADF -l 3"
outname=$2
pbreak=$1
@georgeredinger
georgeredinger / dabblet.css
Created November 10, 2012 18:16 — forked from LeaVerou/markup.html
Illustrating correct & wrong inner border-radius
/**
* Illustrating correct & wrong inner border-radius
*/
.outer {
padding: 10px;
margin: 50px;
border: 1px solid silver;
box-shadow: 0 0 10px gray;
border-radius: 20px;
void setup () {
Serial.begin(57600);
Serial.println("\n[lipoVolt]");
}
void loop () {
int millivolt = map(analogRead(6), 0, 1023, 0, 6600);
Serial.println(millivolt);
delay(1000);
}