Skip to content

Instantly share code, notes, and snippets.

{12-02-28 16:49}[ruby-1.9.3]maxbookpro:~/workspace/dozeo/payments@topic-new-database-layout2✗✗✗ max% rspec spec/api/controllers/payments_controller_spec.rb
:public is no longer used to avoid overloading Module#public, use :public_folder instead
from /Users/max/.rvm/gems/ruby-1.9.3-p0/gems/resque-1.19.0/lib/resque/server.rb:12:in `<class:Server>'
/Users/max/workspace/dozeo/payments/models/payment.rb:2: [BUG] Segmentation fault
ruby 1.9.3p0 (2011-10-30 revision 33570) [x86_64-darwin11.2.0]
-- Control frame information -----------------------------------------------
c:0036 p:---- s:0134 b:0134 l:000133 d:000133 CFUNC :inspect
c:0035 p:---- s:0132 b:0132 l:000131 d:000131 CFUNC :inspect
c:0034 p:0030 s:0129 b:0128 l:000127 d:000127 CLASS /Users/max/workspace/dozeo/payments/models/payment.rb:2
"took": 3,
"timed_out": false,
"_shards": {
"total": 5,
"successful": 5,
"failed": 0
},
"hits": {
"total": 1,
"max_score": 1.0,
@mmack
mmack / Gemfile.lock
Created November 9, 2011 08:43
Gemfile
GIT
remote: git://github.com/chriseppstein/compass.git
revision: 616af1c1398ed6cf53ce6e2c2f0064848cc96e51
specs:
compass (0.12.alpha.0.616af1c)
chunky_png (~> 1.2)
fssm (>= 0.2.7)
sass (~> 3.1)
GIT
@mmack
mmack / gist:1315863
Created October 26, 2011 09:22
ruby regex
ruby-1.9.2-p290 :059 > u = "validusername"
=> "validusername"
ruby-1.9.2-p290 :060 > u !~ /^[a-z0-9\-_]$/
=> true
ruby-1.9.2-p290 :061 > u = "not a valid.username"
=> "not a valid.username"
ruby-1.9.2-p290 :062 > u !~ /^[a-z0-9\-_]$/
=> true
@mmack
mmack / gist:1122092
Created August 3, 2011 07:22
Silicon Valley
<iframe src="about:blank" frameborder="0" id="shimmer" style="display:none;"></iframe>
<!DOCTYPE html>
<head>
<title>Pusher Test</title>
<script src="http://js.pusherapp.com/1.8/pusher.min.js" type="text/javascript"></script>
<script type="text/javascript">
// Enable pusher logging - don't include this in production
Pusher.log = function(message) {
if (window.console && window.console.log) window.console.log(message);
};
@mmack
mmack / test
Created April 5, 2011 09:18
test
uzffkufku
@mmack
mmack / gist:756295
Created December 27, 2010 17:04
padrino setup not working
$ padrino g project wikirocket -a postgres -d datamapper -s jquery -b
$ cd wikirocket
$ padrino start
-----------------
>> Listening on localhost:3000, CTRL+C to stop
NoMethodError: undefined method `matched?' for nil:NilClass
/Users/max/.rvm/gems/ruby-1.9.2-p0/gems/padrino-core-0.9.19/lib/padrino-core/application/routing.rb:66:in `route'
/Users/max/.rvm/gems/ruby-1.9.2-p0/gems/sinatra-1.1.2/lib/sinatra/base.rb:549:in `call!'
/Users/max/.rvm/gems/ruby-1.9.2-p0/gems/sinatra-1.1.2/lib/sinatra/base.rb:538:in `call'
routes.rb:
match 'fax/send(/:user_id(/:token))' => 'fax#send', :as => :fax_send#, :via => :post
rake route:
fax_send /fax/send(/:user_id(/:token))(.:format) {:controller=>"fax", :action=>"send"}
controller:
class FaxController < ApplicationController
def send
end
rake aborted!
Command failed with status (1): [bundle exec /Users/dexcs/.rvm/rubies/ruby-...]
/Users/dexcs/.rvm/gems/ruby-1.9.2-rc2/gems/rake-0.8.7/lib/rake.rb:995:in `block in sh'
/Users/dexcs/.rvm/gems/ruby-1.9.2-rc2/gems/rake-0.8.7/lib/rake.rb:1010:in `call'
/Users/dexcs/.rvm/gems/ruby-1.9.2-rc2/gems/rake-0.8.7/lib/rake.rb:1010:in `sh'
/Users/dexcs/.rvm/gems/ruby-1.9.2-rc2/gems/rake-0.8.7/lib/rake.rb:1094:in `sh'
/Users/dexcs/.rvm/gems/ruby-1.9.2-rc2/gems/cucumber-0.8.5/lib/cucumber/rake/task.rb:72:in `run'
/Users/dexcs/.rvm/gems/ruby-1.9.2-rc2/gems/cucumber-0.8.5/lib/cucumber/rake/task.rb:142:in `block in define_task'
/Users/dexcs/.rvm/gems/ruby-1.9.2-rc2/gems/rake-0.8.7/lib/rake.rb:636:in `call'
/Users/dexcs/.rvm/gems/ruby-1.9.2-rc2/gems/rake-0.8.7/lib/rake.rb:636:in `block in execute'