## just slap this in your rake file or in lib/tasks namespace 'views' do desc 'Renames all your rhtml views to erb' task 'rename' do Dir.glob('app/views/**/*.rhtml').each do |file| puts `svn mv #{file} #{file.gsub(/\.rhtml$/, '.erb')}` end end end ## or if you have rhtml and rxml you could probably use the following (untested) namespace 'views' do desc 'Renames all your rhtml views to erb' task 'rename' do Dir.glob('app/views/**/*.rhtml').each do |file| puts `svn mv #{file} #{file.gsub(/\.(rhtml|rxml)$/, '.erb')}` end end end