From fc597a05703a06ac8599f8696be419e3be4c159a Mon Sep 17 00:00:00 2001 From: f Date: Tue, 24 Sep 2019 19:24:45 -0300 Subject: [PATCH] eliminar el zip antes de recrearlo --- app/models/deploy_zip.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/models/deploy_zip.rb b/app/models/deploy_zip.rb index 4671727..7ea9682 100644 --- a/app/models/deploy_zip.rb +++ b/app/models/deploy_zip.rb @@ -16,6 +16,8 @@ class DeployZip < Deploy # # rubocop:disable Metrics/MethodLength def deploy + FileUtils.rm_f path + time_start Dir.chdir(destination) do Zip::File.open(path, Zip::File::CREATE) do |z| @@ -33,7 +35,6 @@ class DeployZip < Deploy File.exist? path end # rubocop:enable Metrics/MethodLength - # rubocop:enable Metrics/AbcSize def limit 1