Skip to content

Instantly share code, notes, and snippets.

Avatar

Ryan Cook cookrn

View GitHub Profile
@cookrn
cookrn / a.rb
Last active Aug 29, 2015 — forked from ahoward/a.rb
View a.rb
# make this script run, update your gist with the running script, and it's
# output in a separate gist. the entire quzi should take 1-3 minutes, but you
# get 5.
#
# the meat - take < 5 minutes to do this
#
assert :hash do
x = Hash.new
@cookrn
cookrn / a.rb
Last active Aug 29, 2015 — forked from ahoward/a.rb
View a.rb
# fork it
#
# make it print all true with only ONE LINE OF CODE
class A
def A.foo
@foo ||= (
if self == A
'42.0'
else
@cookrn
cookrn / quotes.md
Last active Aug 29, 2015
A collection of some much appreciated quotes
View quotes.md

The bat­tle we have fought, and are still fight­ing for the forests is a part of the eter­nal con­flict between right and wrong, and we can­not expect to see the end of it. …So we must count on watch­ing and striv­ing for these trees, and should always be glad to find any­thing so surely good and noble to strive for.

--john muir

====================

Trying to live a spiritual life in modern society is the most difficult path one can walk. It is a path of pain, of isolation, and of shaken faith, but that is the only way that our Vision can become reality. Thus the true Quest in life is to live the philosophy of the Earth within the confines of man. There is no church or temple we need to seek peace, for ours are the temples of the wilderness. There are no spiritual leaders, for our hearts and the Creator are our only leaders. Our numbers are scattered; few speak our language or understand the things that we live. Thus we walk this path alone, for each Vision, each Quest, is unique unto the individual. B

View error.txt
example21.rs:70:13: 70:19 error: mismatched types: expected `&str` but found `collections::string::String` (expected &-ptr but found struct collections::string::String)
example21.rs:70 println(answer);
^~~~~~
error: aborting due to previous error
View example.rs
use std::io::println;
fn is_three(num: int) -> bool {
num % 3 == 0
}
fn is_five(num: int) -> bool {
num % 5 == 0
}
View keybase.md

Keybase proof

I hereby claim:

  • I am cookrn on github.
  • I am cookrn (https://keybase.io/cookrn) on keybase.
  • I have a public key whose fingerprint is 15DF D0D1 294D FE92 BBFE 47AC A77A 94F0 1103 1D5B

To claim this, I am signing this object:

View post cider install gem list
abstract (1.0.0)
actionmailer (3.0.0.beta3, 2.3.8)
actionpack (3.0.0.beta3, 2.3.8)
activemodel (3.0.0.beta3)
activerecord (3.0.0.beta3, 2.3.8)
activeresource (3.0.0.beta3, 2.3.8)
activesupport (3.0.0.beta3, 2.3.8)
arel (0.3.3)
awesome_print (0.2.1)
builder (2.1.2)
View post gem install cider gem list
abstract (1.0.0)
actionmailer (3.0.0.beta3, 2.3.8)
actionpack (3.0.0.beta3, 2.3.8)
activemodel (3.0.0.beta3)
activerecord (3.0.0.beta3, 2.3.8)
activeresource (3.0.0.beta3, 2.3.8)
activesupport (3.0.0.beta3, 2.3.8)
arel (0.3.3)
awesome_print (0.2.1)
builder (2.1.2)
@cookrn
cookrn / oauth-plugin-0.4.0.pre1-spec-failures.txt
Created Nov 25, 2010
The spec test failures gathered after installing the oauth-plugin oauth2 provider generator code on a base rails3 app
View oauth-plugin-0.4.0.pre1-spec-failures.txt
$ bundle exec rake spec
(in /Users/ryancook/Workspace/prologue_oauth2)
DEPRECATION WARNING: Rake tasks in /Users/ryancook/Workspace/prologue_oauth2/vendor/plugins/oauth-plugin/tasks/oauth_tasks.rake are deprecated. Use lib/tasks instead. (called from <top (required)> at /Users/ryancook/Workspace/prologue_oauth2/Rakefile:7)
/Users/ryancook/Developer/.rvm/rubies/ruby-1.9.2-p0/bin/ruby -S bundle exec rspec "./spec/controllers/admin/dashboard_controller_spec.rb" "./spec/controllers/admin/users_controller_spec.rb" "./spec/controllers/home_controller_spec.rb" "./spec/controllers/oauth_clients_controller_spec.rb" "./spec/controllers/oauth_controller_spec.rb" "./spec/models/client_application_spec.rb" "./spec/models/oauth2_token_spec.rb" "./spec/models/oauth2_verifier_spec.rb" "./spec/models/oauth_nonce_spec.rb" "./spec/models/oauth_token_spec.rb"
DEPRECATION WARNING: Use toplevel init.rb; rails/init.rb is deprecated: /Users/ryancook/Workspace/prologue_oauth2/vendor/plugins/oauth-plugin/rails/init.rb. (called from <t
View _partials.html.erb
<!-- ## VIEW PARTIAL FILE _sub_menu.html.erb -->
<% content_for :sub_menu do %>
<ul id="sub_nav">
<% # Default tab helper function always on for fancy_things sub-tab so <li> constructed manually below %>
<li class="<%= ( params[:action] == "index" ) ? "selected" : "" %>"><%= link_to t("fancy_things") , admin_fancy_things_path %></li>
<%= tab :new_fancy_thing , :route => :new_admin_fancy_thing , :match_path => '/fancy_things/new' , :css_class => 'last' %>
</ul>
<% end %>
<!-- ## VIEW PARTIAL FILE _form.html.erb -->