RAILS_LIB = File.join(RAILS_ROOT, 'lib/') RAILS_TASKS = File.join(RAILS_ROOT, 'lib/tasks/') namespace :uml do desc "Install rake uml:schema from http://blog.zmok.net/articles/2006/11/13/visualize-your-rails-schema" task :install => :environment do system "wget http://blog.zmok.net/files/uml_dumper.rb --output-file=" + File.join(RAILS_LIB, 'log.txt') + " --directory-prefix=" + RAILS_LIB system "wget http://blog.zmok.net/files/uml.rake --output-file=" + File.join(RAILS_TASKS, 'log.txt') + " --directory-prefix=" + RAILS_TASKS puts "Done. Installed Schema XMI created as db/schema.xml." puts "Created by www.hhtong.com" end end