v3

package
v0.0.73 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 25, 2021 License: Apache-2.0, BSD-2-Clause, BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CodeHubClientBuilder

func CodeHubClientBuilder() *http_client.HcHttpClientBuilder

func GenReqDefForAddDeployKey

func GenReqDefForAddDeployKey() *def.HttpRequestDef

func GenReqDefForAddDeployKeyV2

func GenReqDefForAddDeployKeyV2() *def.HttpRequestDef

func GenReqDefForAddHooks

func GenReqDefForAddHooks() *def.HttpRequestDef

func GenReqDefForAddRepoMembers

func GenReqDefForAddRepoMembers() *def.HttpRequestDef

func GenReqDefForAddSshKey

func GenReqDefForAddSshKey() *def.HttpRequestDef

func GenReqDefForCreateCommit

func GenReqDefForCreateCommit() *def.HttpRequestDef

func GenReqDefForCreateProjectAndRepositories

func GenReqDefForCreateProjectAndRepositories() *def.HttpRequestDef

func GenReqDefForCreateProjectAndforkRepositories

func GenReqDefForCreateProjectAndforkRepositories() *def.HttpRequestDef

func GenReqDefForCreateRepository

func GenReqDefForCreateRepository() *def.HttpRequestDef

func GenReqDefForDeleteDeployKey

func GenReqDefForDeleteDeployKey() *def.HttpRequestDef

func GenReqDefForDeleteDeployKeyV2

func GenReqDefForDeleteDeployKeyV2() *def.HttpRequestDef

func GenReqDefForDeleteHooks

func GenReqDefForDeleteHooks() *def.HttpRequestDef

func GenReqDefForDeleteRepoMember

func GenReqDefForDeleteRepoMember() *def.HttpRequestDef

func GenReqDefForDeleteRepository

func GenReqDefForDeleteRepository() *def.HttpRequestDef

func GenReqDefForDeleteSShkey

func GenReqDefForDeleteSShkey() *def.HttpRequestDef

func GenReqDefForGetAllRepositoryByProjectId

func GenReqDefForGetAllRepositoryByProjectId() *def.HttpRequestDef

func GenReqDefForGetProductTemplates

func GenReqDefForGetProductTemplates() *def.HttpRequestDef

func GenReqDefForGetRepositoryByProjectId

func GenReqDefForGetRepositoryByProjectId() *def.HttpRequestDef

func GenReqDefForGetTemplates

func GenReqDefForGetTemplates() *def.HttpRequestDef

func GenReqDefForListCommitStatistics

func GenReqDefForListCommitStatistics() *def.HttpRequestDef

func GenReqDefForListCommits

func GenReqDefForListCommits() *def.HttpRequestDef

func GenReqDefForListFiles

func GenReqDefForListFiles() *def.HttpRequestDef

func GenReqDefForListHooks

func GenReqDefForListHooks() *def.HttpRequestDef

func GenReqDefForListProductTwoTemplates

func GenReqDefForListProductTwoTemplates() *def.HttpRequestDef

func GenReqDefForListRepoMembers

func GenReqDefForListRepoMembers() *def.HttpRequestDef

func GenReqDefForListRepositoryStatus

func GenReqDefForListRepositoryStatus() *def.HttpRequestDef

func GenReqDefForListSshKeys

func GenReqDefForListSshKeys() *def.HttpRequestDef

func GenReqDefForListSubfiles

func GenReqDefForListSubfiles() *def.HttpRequestDef

func GenReqDefForListTemplatesTwo

func GenReqDefForListTemplatesTwo() *def.HttpRequestDef

func GenReqDefForListTwoTemplates

func GenReqDefForListTwoTemplates() *def.HttpRequestDef

func GenReqDefForListUserAllRepositories

func GenReqDefForListUserAllRepositories() *def.HttpRequestDef

func GenReqDefForSetRepoRole

func GenReqDefForSetRepoRole() *def.HttpRequestDef

func GenReqDefForShareTemplates

func GenReqDefForShareTemplates() *def.HttpRequestDef

func GenReqDefForShowAllRepositoryByTwoProjectId

func GenReqDefForShowAllRepositoryByTwoProjectId() *def.HttpRequestDef

func GenReqDefForShowBranchesByRepositoryId

func GenReqDefForShowBranchesByRepositoryId() *def.HttpRequestDef

func GenReqDefForShowBranchesByTwoRepositoryId

func GenReqDefForShowBranchesByTwoRepositoryId() *def.HttpRequestDef

func GenReqDefForShowCommitsByBranch

func GenReqDefForShowCommitsByBranch() *def.HttpRequestDef

func GenReqDefForShowCommitsByRepoId

func GenReqDefForShowCommitsByRepoId() *def.HttpRequestDef

func GenReqDefForShowDiffCommit

func GenReqDefForShowDiffCommit() *def.HttpRequestDef

func GenReqDefForShowFile

func GenReqDefForShowFile() *def.HttpRequestDef

func GenReqDefForShowHasPipeline

func GenReqDefForShowHasPipeline() *def.HttpRequestDef

func GenReqDefForShowImageBlob

func GenReqDefForShowImageBlob() *def.HttpRequestDef

func GenReqDefForShowMaster

func GenReqDefForShowMaster() *def.HttpRequestDef

func GenReqDefForShowPrivateKeyVerify

func GenReqDefForShowPrivateKeyVerify() *def.HttpRequestDef

func GenReqDefForShowRepoId

func GenReqDefForShowRepoId() *def.HttpRequestDef

func GenReqDefForShowRepositoryArchive

func GenReqDefForShowRepositoryArchive() *def.HttpRequestDef

func GenReqDefForShowRepositoryByUuid

func GenReqDefForShowRepositoryByUuid() *def.HttpRequestDef

func GenReqDefForShowRepositoryNameExist

func GenReqDefForShowRepositoryNameExist() *def.HttpRequestDef

func GenReqDefForShowRepositoryStatistics

func GenReqDefForShowRepositoryStatistics() *def.HttpRequestDef

func GenReqDefForShowSingleCommit

func GenReqDefForShowSingleCommit() *def.HttpRequestDef

func GenReqDefForShowStatisticCommit

func GenReqDefForShowStatisticCommit() *def.HttpRequestDef

func GenReqDefForShowStatisticalData

func GenReqDefForShowStatisticalData() *def.HttpRequestDef

func GenReqDefForValidateHttpsInfo

func GenReqDefForValidateHttpsInfo() *def.HttpRequestDef

func GenReqDefForValidateHttpsInfoV2

func GenReqDefForValidateHttpsInfoV2() *def.HttpRequestDef

Types

type CodeHubClient

type CodeHubClient struct {
	HcClient *http_client.HcHttpClient
}

func NewCodeHubClient

func NewCodeHubClient(hcClient *http_client.HcHttpClient) *CodeHubClient

func (*CodeHubClient) AddDeployKey

添加部署密钥

func (*CodeHubClient) AddDeployKeyV2

添加部署密钥

func (*CodeHubClient) AddHooks

func (c *CodeHubClient) AddHooks(request *model.AddHooksRequest) (*model.AddHooksResponse, error)

提交代码自动触发编译构建,添加仓库钩子

func (*CodeHubClient) AddRepoMembers

调用方codehubportal,添加仓库成员。

func (*CodeHubClient) AddSshKey

func (c *CodeHubClient) AddSshKey(request *model.AddSshKeyRequest) (*model.AddSshKeyResponse, error)

添加ssh key

func (*CodeHubClient) CreateCommit

能够一次提交位于不同目录的多个文件,目录不存在时,能自动创建目录。支持强制覆盖选项,当选择强制覆盖标志为true时,忽略冲突,强制提交。

func (*CodeHubClient) CreateProjectAndRepositories

创建项目后,创建仓库组由后台生成方式 传入参数:仓库名、模板id、是否导入项目成员、归属项目

func (*CodeHubClient) CreateProjectAndforkRepositories

创建仓库后fork仓库 传入参数:仓库名、是否导入项目成员、归属项目

func (*CodeHubClient) CreateRepository

用指定的名称在指定项目上创建仓库。传入参数:仓库名、模板id、是否导入项目成员、归属项目

func (*CodeHubClient) DeleteDeployKey

删除仓库部署密钥

func (*CodeHubClient) DeleteDeployKeyV2

删除仓库部署密钥

func (*CodeHubClient) DeleteHooks

提交代码自动触发编译构建,删除仓库钩子

func (*CodeHubClient) DeleteRepoMember

删除仓库成员

func (*CodeHubClient) DeleteRepository

根据仓库32位uuid删除指定的仓库

func (*CodeHubClient) DeleteSShkey

调用gitlab原生接口删除用户公钥。

func (*CodeHubClient) GetAllRepositoryByProjectId

获取仓库列表 模糊查询支持范围,如果未传入project_id,则支持按仓库名或项目名模糊查询,否则,只按仓库名模糊匹配。

func (*CodeHubClient) GetProductTemplates

获取一个项目下可以设置为公开状态的仓库列表

func (*CodeHubClient) GetRepositoryByProjectId

不建议再使用,建议使用/{repository_uuid}/status

func (*CodeHubClient) GetTemplates

获取公开示例模板列表

func (*CodeHubClient) ListCommitStatistics

获取仓库上一次的提交统计信息

func (*CodeHubClient) ListCommits

根据仓库短ID获取提交信息,支持根据文件路径,查询这个路径下所有的commits列表。

func (*CodeHubClient) ListFiles

func (c *CodeHubClient) ListFiles(request *model.ListFilesRequest) (*model.ListFilesResponse, error)

获取一个仓库下特定分支指定文件内容

func (*CodeHubClient) ListHooks

func (c *CodeHubClient) ListHooks(request *model.ListHooksRequest) (*model.ListHooksResponse, error)

获取仓库webhook

func (*CodeHubClient) ListProductTwoTemplates

获取一个项目下可以设置为公开状态的仓库列表

func (*CodeHubClient) ListRepoMembers

获取仓库成员列表,可通过关键字搜索某成员。

func (*CodeHubClient) ListRepositoryStatus

获取仓库状态。

func (*CodeHubClient) ListSshKeys

获取ssh key列表。

func (*CodeHubClient) ListSubfiles

获取分支目录下的文件

func (*CodeHubClient) ListTemplatesTwo

设置仓库是公开状态还是私有状态

func (*CodeHubClient) ListTwoTemplates

获取公开示例模板列表

func (*CodeHubClient) ListUserAllRepositories

获取用户的所有仓库信息

func (*CodeHubClient) SetRepoRole

给仓库中成员设置仓库的操作权限,

func (*CodeHubClient) ShareTemplates

设置仓库是公开状态还是私有状态

func (*CodeHubClient) ShowAllRepositoryByTwoProjectId

获取仓库列表,模糊查询支持范围,如果未传入project uuid,则支持按仓库名或项目名模糊查询,否则,只按仓库名模糊匹配

func (*CodeHubClient) ShowBranchesByRepositoryId

根据仓库id获取指定仓库的分支列表.

func (*CodeHubClient) ShowBranchesByTwoRepositoryId

查询指定仓库对应的分支。

func (*CodeHubClient) ShowCommitsByBranch

根据仓库组名、仓库名和分支获取提交列表。

func (*CodeHubClient) ShowCommitsByRepoId

根据仓库id查询仓库某分支对应的提交.

func (*CodeHubClient) ShowDiffCommit

根据commit id查询提交差异信息。

func (*CodeHubClient) ShowFile

func (c *CodeHubClient) ShowFile(request *model.ShowFileRequest) (*model.ShowFileResponse, error)

获取仓库中文件的信息,如名称、大小、内容。请注意,文件内容是Base64编码的。

func (*CodeHubClient) ShowHasPipeline

修改被流水线引用的仓库状态

func (*CodeHubClient) ShowImageBlob

获取一个仓库下特定分支的图片文件

func (*CodeHubClient) ShowMaster

func (c *CodeHubClient) ShowMaster(request *model.ShowMasterRequest) (*model.ShowMasterResponse, error)

判断用户是否有仓库的管理员权限

func (*CodeHubClient) ShowPrivateKeyVerify

检验私钥是否有拉取代码的权限

func (*CodeHubClient) ShowRepoId

func (c *CodeHubClient) ShowRepoId(request *model.ShowRepoIdRequest) (*model.ShowRepoIdResponse, error)

获取仓库短id,用于获取仓库详情页面url

func (*CodeHubClient) ShowRepositoryArchive

按照指定格式下载仓库

func (*CodeHubClient) ShowRepositoryByUuid

根据仓库UUID获取仓库信息仓库信息。返回 包含id,name,组名,仓库访问URL。

func (*CodeHubClient) ShowRepositoryNameExist

一般创建仓库时调用。通过传入项目uuid,仓库名,调用CoudeHubAdapter接口,查询数据库来判断仓库是否重名。

func (*CodeHubClient) ShowRepositoryStatistics

根据仓库短id,查询仓库的代码提交记录统计

func (*CodeHubClient) ShowSingleCommit

获取由commit id或分支或标记的名称标识的特定提交。

func (*CodeHubClient) ShowStatisticCommit

获取指定日期内代码仓指定分支的代码提交行数

func (*CodeHubClient) ShowStatisticalData

获取仓库统计数据

func (*CodeHubClient) ValidateHttpsInfo

调用 gitlab 接口判断用户使用 https 上传/下载代码时输入的用户名和密码是否合法。

func (*CodeHubClient) ValidateHttpsInfoV2

调用 gitlab 接口判断用户使用 https 上传/下载代码时输入的用户名和密码是否合法。

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL