|
|
|
@ -489,7 +489,15 @@ class GamesController < ApplicationController
|
|
|
|
|
path = path.try(:strip)
|
|
|
|
|
uid_logger("--rep_content: path is #{path}")
|
|
|
|
|
begin
|
|
|
|
|
@content = git_fle_content(@myshixun.repo_path, path) || ""
|
|
|
|
|
if @myshixun.repo_name.nil?
|
|
|
|
|
g = Gitlab.client
|
|
|
|
|
repo_name = g.project(@myshixun.gpid).path_with_namespace
|
|
|
|
|
@myshixun.update_column(:repo_name, repo_name)
|
|
|
|
|
@content = git_fle_content("#{repo_name}.git", path) || ""
|
|
|
|
|
else
|
|
|
|
|
@content = git_fle_content(@myshixun.repo_path, path) || ""
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
rescue Exception => e
|
|
|
|
|
# 思路: 异常首先应该考虑去恢复
|
|
|
|
|
if params[:retry].to_i == 1
|
|
|
|
|