Skip to content
This repository has been archived by the owner on Aug 15, 2018. It is now read-only.

Commit

Permalink
[INSTALL] removed double save of user and fixed error that occurred i…
Browse files Browse the repository at this point in the history
…f /public/uploads already existed
  • Loading branch information
Adam Dill committed Feb 10, 2009
1 parent 6cfb27c commit 270f5f7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions lib/tasks/ansuz.rake
Expand Up @@ -122,9 +122,8 @@ namespace :ansuz do
STDOUT.flush
password = $stdin.gets.chomp
u = User.new :login => 'admin', :email => 'admin@example.com', :password => password, :password_confirmation => password
u.save
u.has_role 'admin'
u.save # Not sure why we save twice. Josh?
u.save
STDOUT.puts "[ansuz] Admin user created with login 'admin' and the password you entered."
else
STDOUT.puts "[ansuz] Admin user already exists."
Expand All @@ -134,6 +133,8 @@ namespace :ansuz do
unless( File.directory?( File.join(RAILS_ROOT, "public", "uploads") ) )
STDOUT.puts "[ansuz] Creating public/uploads directory for FCKeditor.."
FileUtils.mkdir( File.join(RAILS_ROOT, "public", "uploads") )
else
STDOUT.puts "[ansuz] public/uploads directory for FCKeditor already exists."
end

Rake::Task["ansuz:choose_theme"].invoke
Expand Down

0 comments on commit 270f5f7

Please sign in to comment.