|
|
@ -410,11 +410,11 @@ update
|
|
|
|
@zip_path = Gitlab.endpoint.to_s + "/projects/" + @project.gpid.to_s + "/repository/archive?&private_token=" + Gitlab.private_token
|
|
|
|
@zip_path = Gitlab.endpoint.to_s + "/projects/" + @project.gpid.to_s + "/repository/archive?&private_token=" + Gitlab.private_token
|
|
|
|
|
|
|
|
|
|
|
|
# 获取版本库路径,主要分为两种,一种随Gitlab类型,另一种为Git类型,Git类型为无用数据,最终需要删掉这种类型。
|
|
|
|
# 获取版本库路径,主要分为两种,一种随Gitlab类型,另一种为Git类型,Git类型为无用数据,最终需要删掉这种类型。
|
|
|
|
if @repository.type.to_s == "Repository::Gitlab"
|
|
|
|
# if @repository.type.to_s == "Repository::Gitlab"
|
|
|
|
@repos_url = gitlab_address.to_s+"/" + @creator + "/" + @repository.identifier+"."+"git"
|
|
|
|
@repos_url = gitlab_address.to_s+"/" + @creator + "/" + @repository.identifier+"."+"git"
|
|
|
|
else
|
|
|
|
# else
|
|
|
|
@repos_url = "http://"+@repository.login.to_s+"_"+@repository.identifier.to_s+"@"+ip.to_s + @repository.url.slice(project_path_cut, @repository.url.length).to_s
|
|
|
|
# @repos_url = "http://"+@repository.login.to_s+"_"+@repository.identifier.to_s+"@"+ip.to_s + @repository.url.slice(project_path_cut, @repository.url.length).to_s
|
|
|
|
end
|
|
|
|
# end
|
|
|
|
render :action => 'show', :layout => 'base_projects'
|
|
|
|
render :action => 'show', :layout => 'base_projects'
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|