Permalink
Browse files

update readme

  • Loading branch information...
binarylogic committed May 5, 2011
1 parent d6d90ee commit 29846f55afc1003ee2a001d3e1dd094341dd67cf
Showing with 10 additions and 10 deletions.
  1. +10 −10 README.rdoc
View
@@ -1,5 +1,7 @@
= Authlogic
+** Please note the latest version is compatible with rails 3 only. Rails 2 should use version 2.X.X **
+
Authlogic is a clean, simple, and unobtrusive ruby authentication solution.
A code example can replace a thousand words...
@@ -152,7 +154,7 @@ What if your user sessions controller could look just like your other controller
def new
@user_session = UserSession.new
end
-
+
def create
@user_session = UserSession.new(params[:user_session])
if @user_session.save
@@ -161,7 +163,7 @@ What if your user sessions controller could look just like your other controller
render :action => :new
end
end
-
+
def destroy
current_user_session.destroy
redirect_to new_user_session_url
@@ -185,13 +187,13 @@ Or how about persisting the session...
class ApplicationController
helper_method :current_user_session, :current_user
-
+
private
def current_user_session
return @current_user_session if defined?(@current_user_session)
@current_user_session = UserSession.find
end
-
+
def current_user
return @current_user if defined?(@current_user)
@current_user = current_user_session && current_user_session.user
@@ -202,17 +204,15 @@ Or how about persisting the session...
Install the gem / plugin (recommended)
-From rubyforge:
+Rails 3:
$ sudo gem install authlogic
-Or from github:
-
- $ sudo gem install binarylogic-authlogic
+Rails 2:
-Now just add the gem dependency in your projects configuration.
+ $ sudo gem install authlogic --version=2.1.6
-Or you can install this as a plugin:
+Or install as a plugin:
script/plugin install git://github.com/binarylogic/authlogic.git

0 comments on commit 29846f5

Please sign in to comment.