Permalink
Browse files

moving generator lib up one level so all generators can share it. Als…

…o stripped a couple puts'es
  • Loading branch information...
1 parent e8552f3 commit dfa9f375e43970ca6e1d47a70d7f1304cc31a422 Philip (flip) Kromer committed May 31, 2008
View
2 README
@@ -56,7 +56,7 @@ They are out of date for this new version, but may be helpful nonetheless
<a id="AWESOME"/> </a>
h2. Exciting new features
-The system has been split up to give a clear distinction between authentication
+The system has been split up to give a clear distinction among authentication
(who are you?), authorization (is he allowed to just take the plutonium like
that?), policy (note to staff: no one is allowed to take plutonium) and access
control (step away from the reactor, bubba).
@@ -1,4 +1,4 @@
-require File.expand_path(File.dirname(__FILE__) + "/lib/insert_routes.rb")
+require File.expand_path(File.dirname(__FILE__) + "/../lib/insert_routes.rb")
require 'digest/sha1'
class AuthenticatedGenerator < Rails::Generator::NamedBase
default_options :skip_migration => false,
@@ -316,3 +316,7 @@ def dump_generator_attribute_names
end
end
+
+# sanitize non-private use of the word 'user'
+# grep user -ri .| ruby -pe \
+# '$_.gsub!(/current_user|@user|session\[:user_id\]|mock_user/, ""); $_="" unless $_ =~ /^[^:]+:.*user/'
View
@@ -11,4 +11,3 @@
# FIXME -- this is crap
require 'pathname'
$REST_AUTH_DIR = Pathname.new(File.dirname(__FILE__)).realpath
-puts $REST_AUTH_DIR
@@ -64,7 +64,6 @@
Then "$actor $token cookie should exist but not include $attrlist" do |_, token, attrlist|
attrlist = attrlist.to_array_from_story
cookies.include?(token).should be_true
- puts [cookies, attrlist, token].to_yaml
attrlist.each do |val|
cookies[token].include?(val).should_not be_true
end

0 comments on commit dfa9f37

Please sign in to comment.