Skip to content

Commit f04c3a3

Browse files
committed
chore: remove useless code
1 parent 680b816 commit f04c3a3

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

lib/tasks/maglev/vite.rake

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,10 @@ namespace :maglev do
6161

6262
desc "Copy the ViteRuby's public directory to the app's public directory"
6363
task copy_public_dir: :environment do
64-
within_engine_folder do
65-
output_dir_name = Maglev::Engine.vite_ruby.config.public_output_dir
66-
source_path = Maglev::Engine.root.join('public', output_dir_name)
67-
target_path = Rails.root.join('public', output_dir_name)
68-
FileUtils.rm_rf(target_path)
69-
FileUtils.mkdir_p(target_path)
70-
FileUtils.cp_r(source_path, target_path)
71-
end
64+
output_dir_name = Maglev::Engine.vite_ruby.config.public_output_dir
65+
source_path = Maglev::Engine.root.join('public', output_dir_name)
66+
target_path = Rails.root.join('public')
67+
FileUtils.cp_r(source_path, target_path)
7268
end
7369
end
7470
end

0 commit comments

Comments
 (0)