[ Launch: sin waves ] 6528538 by sbecker See Previous Inlet [ Gist ]
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Image < ActiveRecord::Base | |
named_scope :allowed_for, lambda { |account| { :conditions => ["aws_is_public = ? OR account_id = ?", true, account.id] }} | |
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# issue I'm having with Hpricot 0.7.232 (latest build I believe). | |
# So to be specific, inside a tag named "description" it seems to behave wrong, with .text returning all of the text in the XML from that point forward. | |
# If I change the name of the parent tag to anything else, it works right, returning just the text inside the tag. Weird eh? Here is some code, hopefully it formats in a readable way: | |
# Inside of a tag called 'description' - gives incorrect .text value: "test\n one,two\n" | |
>> xml = Hpricot.XML(%{ | |
<peon> | |
<id>1</id> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
* Installing CentOS 5.5 & Puppet | |
** Notes | |
** Download install iso: http://mirrors.kernel.org/centos/5.5/isos/x86_64/CentOS-5.5-x86_64-bin-DVD-1of2.iso | |
** Create a new VirtualBox machine | |
- Name: vagrant-centos | |
- Operating System: Linux |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/ruby | |
require 'rubygems' | |
require "highline/system_extensions" | |
require 'colorize' | |
include HighLine::SystemExtensions | |
orig, new, args = ARGV | |
args = Array(args) | |
file_names = Dir["**/*.*"] |
[ Launch: sin waves ] 6528549 by sbecker See Previous Inlet [ Gist ]
I hereby claim:
- I am sbecker on github.
- I am sbecker (https://keybase.io/sbecker) on keybase.
- I have a public key whose fingerprint is 5195 6A86 C824 9EF9 A06D ED06 EEAB DFF0 0B55 CFB3
To claim this, I am signing this object: