From d84975a61ada0783edc82ed5f948b0355e1a6c5a Mon Sep 17 00:00:00 2001 From: f Date: Tue, 11 Apr 2023 10:42:07 -0300 Subject: [PATCH 1/3] feat: poder hacer git lfs checkout --- app/models/deploy_local.rb | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/app/models/deploy_local.rb b/app/models/deploy_local.rb index bfde29f7..ee06fa4e 100644 --- a/app/models/deploy_local.rb +++ b/app/models/deploy_local.rb @@ -14,6 +14,7 @@ class DeployLocal < Deploy # Sutty def deploy(output: false) return false unless mkdir + return false unless git_lfs(output: output) return false unless yarn(output: output) return false unless pnpm(output: output) return false unless bundle(output: output) @@ -113,6 +114,11 @@ class DeployLocal < Deploy File.exist? pnpm_lock end + def git_lfs(output: false) + run %(git lfs fetch), output: output + run %(git lfs checkout), output: output + end + def gem(output: false) run %(gem install bundler --no-document), output: output end From 1c5dd603e5890b32eaf864e11213206229d3f78a Mon Sep 17 00:00:00 2001 From: f Date: Tue, 11 Apr 2023 10:42:33 -0300 Subject: [PATCH 2/3] fix: hacer git lfs checkout despues de clonar el sitio #13022 --- app/models/site.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/models/site.rb b/app/models/site.rb index 3f2aa34e..9a6a3865 100644 --- a/app/models/site.rb +++ b/app/models/site.rb @@ -473,6 +473,8 @@ class Site < ApplicationRecord return if jekyll? Rugged::Repository.clone_at ENV['SKEL_SUTTY'], path + + deploys.find_by_type('DeployLocal').send(:git_lfs) end # Elimina el directorio del sitio From 9e177a2257db47eddaf7f70f90ce98d5b7e09bbe Mon Sep 17 00:00:00 2001 From: f Date: Tue, 11 Apr 2023 10:48:00 -0300 Subject: [PATCH 3/3] fix: correr lfs junto con las gemas MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit esto es una soluciĆ³n temporal! --- app/models/site.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/models/site.rb b/app/models/site.rb index 9a6a3865..6ac10329 100644 --- a/app/models/site.rb +++ b/app/models/site.rb @@ -473,8 +473,6 @@ class Site < ApplicationRecord return if jekyll? Rugged::Repository.clone_at ENV['SKEL_SUTTY'], path - - deploys.find_by_type('DeployLocal').send(:git_lfs) end # Elimina el directorio del sitio @@ -566,6 +564,8 @@ class Site < ApplicationRecord def install_gems return unless persisted? + deploys.find_by_type('DeployLocal').send(:git_lfs) + if !gem_dir? || gemfile_updated? || gemfile_lock_updated? deploys.find_by_type('DeployLocal').send(:bundle) touch