Skip to content

Instantly share code, notes, and snippets.

View kamal's full-sized avatar

Kamal Fariz Mahyuddin kamal

View GitHub Profile
Index: test/test_ruby_parser.rb
===================================================================
--- test/test_ruby_parser.rb (revision 448)
+++ test/test_ruby_parser.rb (working copy)
@@ -374,6 +374,13 @@
assert_equal pt, @processor.parse(rb)
end
+ def test_str_pct_nested_nested
+ rb = "%{ { #\{ \"#\{1}\" } } }"
DEBUG: ---- Begin cd /tmp/chef-solo/ && tar xzvf /tmp/chef-solo/recipes.tgz STDOUT ----
DEBUG: opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/
opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/LICENSE
opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/NOTICE
opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/cookbooks/
opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/cookbooks/chef/
opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/cookbooks/chef/attributes/
opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/cookbooks/chef/attributes/chef.rb
opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/cookbooks/chef/recipes/
opscode-chef-server-solo-install-f786c30009a68157775bebce7b0bad01da6f756a/cookbooks/chef/recipes/default.rb
MacBook-Pro:eagle(master) kamal$ time jrake --trace
(in /Users/kamal/src/eagle)
** Invoke default (first_time)
** Invoke features (first_time)
** Invoke db:test:prepare (first_time)
** Invoke db:abort_if_pending_migrations (first_time)
** Invoke environment (first_time)
** Execute environment
rake aborted!
wrong argument type Symbol (expected Module)
{
"authorization":
{
"sudo":
{
"users": [
"foo",
"bar"
]
}
authorization Mash.new unless attribute?("authorization")
authorization[:sudo] = Mash.new unless authorization.has_key?("sudo")
authorization[:sudo][:users] = ["foo", "bar"]
MacBook-Pro:zoecity-app(master) kamal$ irb
irb(main):001:0> require "rubygems"
=> true
irb(main):002:0> require "addressable/uri"
=> true
irb(main):003:0> a = Addressable::URI.heuristic_parse("www.google.com ")
=> #<Addressable::URI:0xc3300c URI:http://www.google.com >
irb(main):004:0> a.normalize!
=> #<Addressable::URI:0xc3300c URI:http://www.google.com/>
irb(main):005:0> a.host
node[:apps].each do |app|
template "/etc/apache2/sites-available/#{app}_#{node[:rails_env]}" do
owner 'root'
group 'root'
mode 0644
source "application.vhost.erb"
variables({
:docroot => "/data/#{app}/current/public",
:server_name => node[:apache][app][:server_name],
:max_pool_size => node[:apache][app][:max_pool_size] || 2,
http://example.com/shares/new?v=1 <--- WTF???
https://secure.example.com/shares/new?v=1
Authorization: AuthSub token="COy2q9qdGRDWm7iMAm"
Authorization: AuthSub token="COy2q9qdGRDWm7iMAm" sigalg="rsa-sha1" data="GET http://www.google.com/m8/feeds/contacts/default/thin?max-results=200 1237370831 18094396511823580603" sig="XOQNfKpQ8VPCN2Yp+Zt="