I\'m migrating from Authlogic to Devise.
UPDATED:
The migration of devise tries to re-create the table users, so i changed as you can see below the create_
The error that you're getting is because you are trying to recreate the email field which you already have. The email field is created in the devise helper t.database_authenticatable. You can use your old user table with the new system, but you don't need to include t.database_authenticatable, you just need to rename your old field names. Looking in the Documentation for Devise, you can see that database_authenticatable just creates three fields: email, encrypted_password and password_salt. They are the same as the email, crypted_password, and password_salt that you already have in your authlogic user table, so you can use change_table like so:
def self.up
change_table(:users) do |t|
t.recoverable
t.trackable
# rememberable uses remember_token, but this field is different
t.rename :remember_token_expires_at, :remember_created_at
# these fields are named differently in devise
t.rename :crypted_password, :encrypted_password
end
end