Skip to content

Instantly share code, notes, and snippets.

View aeden's full-sized avatar

Anthony Eden aeden

View GitHub Profile
desc "Generate and deploy assets"
task :deploy_assets, :roles => :app do
# get the previous timestamp
old_timestamp = File.read("config/deploy_timestamp").to_i rescue 0
# generate timestamp into config/deploy_timestamp
timestamp = Time.now.to_i
File.open("config/deploy_timestamp", 'w') do |f|
f.write(timestamp)
end
This is a test.
module Poco
def field_id
@field_id ||= rand
end
def field_id=(field_id)
@field_id = field_id
end
end
Time.send(:include, Poco)
begin
require 'jeweler'
Jeweler::Tasks.new do |gemspec|
gemspec.name = "refinery"
gemspec.summary = "Refinery processes data in a distributed environment."
gemspec.email = "anthonyeden@gmail.com"
gemspec.homepage = "http://github.com/aeden/refinery"
gemspec.description = "Process data in a distributed fashion."
gemspec.authors = ["Anthony Eden"]
gemspec.files.exclude 'docs/**/*'
E, [2009-07-07T18:12:22.791000 #21667][198] ERROR -- : An error occurred while receiving from the waiting queue: Could not open any of [xml2, xslt, exslt]
E, [2009-07-07T18:12:22.791000 #21667][198] ERROR -- : /opt/jruby/lib/ruby/1.8/ffi/library.rb:18:in `ffi_lib'
/opt/jruby/lib/ruby/gems/1.8/gems/nokogiri-1.3.2-java/lib/nokogiri/ffi/libxml.rb:5
/opt/jruby/lib/ruby/gems/1.8/gems/nokogiri-1.3.2-java/lib/nokogiri/ffi/libxml.rb:31:in `require'
/opt/jruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
/opt/jruby/lib/ruby/gems/1.8/gems/nokogiri-1.3.2-java/lib/nokogiri.rb:10
/opt/jruby/lib/ruby/gems/1.8/gems/nokogiri-1.3.2-java/lib/nokogiri.rb:31:in `require'
/opt/jruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
/opt/jruby/lib/ruby/gems/1.8/gems/pauldix-sax-machine-0.0.13/lib/sax-machine/sax_document.rb:1
/opt/jruby/lib/ruby/gems/1.8/gems/pauldix-sax-machine-0.0.13/lib/sax-machine/sax_document.rb:31:in `require'
require 'java'
require File.dirname(__FILE__) + '/vendor/jaxb-20090708.jar'
include_class javax.xml.bind.UnmarshalException
/usr/local/lib/jruby-1.3.0/lib/ruby/site_ruby/1.8/builtin/javasupport.rb:49:in `get_proxy_or_package_under_package': cannot load Java class javax.xml.bind.UnmarshalException (NameError)
from /usr/local/lib/jruby-1.3.0/lib/ruby/site_ruby/1.8/builtin/javasupport/java.rb:51:in `method_missing'
from import-test.rb:3
module Autotest::CustomTestMatch
Autotest.add_hook :initialize do |at|
at.add_mapping(/test/) do |f, _|
at.files_matching(/_test\.rb$/)
end
at.add_mapping(/lib\/.*/) do |f, _|
at.files_matching(/_test\.rb$/)
end
at.add_exception('test/performance')
end
Checkout:
git clone url
Checkout throwing away local changes:
git checkout -f
Checkout a single file to get it back to HEAD:
@aeden
aeden / gist:220808
Created October 28, 2009 20:41 — forked from kmayer/gist:220166
while true do
RefineryQueue.stats_update
sleep 60
end
aeden:~$ rvm remove macruby-head; rvm install macruby-head --trace
it seems that /Users/aeden/.rvm/src/macruby-head is already non existent.
it seems that /Users/aeden/.rvm/macruby-head is already non existent.
install macruby-head --trace
+ [[ -z install ]]
+ [[ ! -z '' ]]