Merge branch 'dev_trustie' into dev_chain

This commit is contained in:
sylor_huang@126.com 2020-07-14 11:27:59 +08:00
commit 0eb1abf850
1 changed files with 3 additions and 1 deletions

View File

@ -8,7 +8,7 @@ class SyncRepositoryJob < ApplicationJob
SyncLog.sync_log("=================begin to sync request trustie repository=====================") SyncLog.sync_log("=================begin to sync request trustie repository=====================")
path = "#{Rails.root}/public/cache_repository" path = "#{Rails.root}/public/cache_repository"
image_url = repository_params[:git_url] image_url = repository_params[:git_url]
g_default_branch = repository_params[:default_branch] g_default_branch = repository_params[:default_branch] || "master"
image_repo_name = image_url.to_s.split('/')&.last&.chomp('.git') image_repo_name = image_url.to_s.split('/')&.last&.chomp('.git')
unless File.directory?(path) unless File.directory?(path)
@ -29,6 +29,8 @@ class SyncRepositoryJob < ApplicationJob
if !shell5 if !shell5
SyncLog.sync_project_log("=============force_push_erros==#{path}/#{image_repo_name}++new_gitlab_url+++#{new_gitlab_url}") SyncLog.sync_project_log("=============force_push_erros==#{path}/#{image_repo_name}++new_gitlab_url+++#{new_gitlab_url}")
SyncLog.sync_log("++++++++++++++++++force_push_erros++++++++++++++++++##{path}/#{image_repo_name}++++++new_gitlab_url+++#{new_gitlab_url}") SyncLog.sync_log("++++++++++++++++++force_push_erros++++++++++++++++++##{path}/#{image_repo_name}++++++new_gitlab_url+++#{new_gitlab_url}")
else
SyncLog.sync_project_log("=============force_push_success==#{path}/#{image_repo_name}++new_gitlab_url+++#{new_gitlab_url}")
end end
else else
SyncLog.sync_project_log("=============check_clone_erros==#{path}/#{image_repo_name}") SyncLog.sync_project_log("=============check_clone_erros==#{path}/#{image_repo_name}")