pub struct GitClient { /* private fields */ }
Expand description
Git API 客户端
Implementations§
Source§impl GitClient
impl GitClient
Sourcepub async fn get_repo_git_branches_branch(
&self,
repo: String,
branch: String,
) -> Result<Value>
pub async fn get_repo_git_branches_branch( &self, repo: String, branch: String, ) -> Result<Value>
查询指定分支。Get a branch.
Sourcepub async fn delete_repo_git_branches_branch(
&self,
repo: String,
branch: String,
) -> Result<Value>
pub async fn delete_repo_git_branches_branch( &self, repo: String, branch: String, ) -> Result<Value>
删除指定分支。Delete the specified branch.
Sourcepub async fn get_repo_git_commit_annotations_sha(
&self,
repo: String,
sha: String,
) -> Result<Value>
pub async fn get_repo_git_commit_annotations_sha( &self, repo: String, sha: String, ) -> Result<Value>
查询指定 commit 的元数据。Get commit annotations.
Sourcepub async fn put_repo_git_commit_annotations_sha(
&self,
repo: String,
sha: String,
put_commit_annotations_form: Value,
) -> Result<Value>
pub async fn put_repo_git_commit_annotations_sha( &self, repo: String, sha: String, put_commit_annotations_form: Value, ) -> Result<Value>
设定指定 commit 的元数据。Put commit annotations.
Sourcepub async fn get_repo_git_branches(
&self,
repo: String,
page: Option<i64>,
page_size: Option<i64>,
) -> Result<Value>
pub async fn get_repo_git_branches( &self, repo: String, page: Option<i64>, page_size: Option<i64>, ) -> Result<Value>
查询分支列表。List branches.
Sourcepub async fn post_repo_git_branches(
&self,
repo: String,
create_branch_form: Value,
) -> Result<Value>
pub async fn post_repo_git_branches( &self, repo: String, create_branch_form: Value, ) -> Result<Value>
创建新分支。Create a new branch based on a start point.
Sourcepub async fn get_repo_git_commits(
&self,
repo: String,
sha: Option<String>,
author: Option<String>,
committer: Option<String>,
since: Option<String>,
until: Option<String>,
page: Option<i64>,
page_size: Option<i64>,
) -> Result<Value>
pub async fn get_repo_git_commits( &self, repo: String, sha: Option<String>, author: Option<String>, committer: Option<String>, since: Option<String>, until: Option<String>, page: Option<i64>, page_size: Option<i64>, ) -> Result<Value>
查询 commit 列表。List commits.
Sourcepub async fn get_repo_git_archive_compare_changed_files_base_head(
&self,
repo: String,
base_head: String,
) -> Result<Value>
pub async fn get_repo_git_archive_compare_changed_files_base_head( &self, repo: String, base_head: String, ) -> Result<Value>
打包下载两次 ref 之间的变更文件。Download archive of changed files for a compare.
Sourcepub async fn post_repo_git_blobs(
&self,
repo: String,
post_blob_form: Value,
) -> Result<Value>
pub async fn post_repo_git_blobs( &self, repo: String, post_blob_form: Value, ) -> Result<Value>
创建一个 blob。Create a blob.
Sourcepub async fn get_repo_git_tag_annotations_tag(
&self,
repo: String,
tag: String,
) -> Result<Value>
pub async fn get_repo_git_tag_annotations_tag( &self, repo: String, tag: String, ) -> Result<Value>
查询指定 tag 的元数据。Query the metadata of the specified tag.
Sourcepub async fn put_repo_git_tag_annotations_tag(
&self,
repo: String,
tag: String,
put_tag_annotations_form: Value,
) -> Result<Value>
pub async fn put_repo_git_tag_annotations_tag( &self, repo: String, tag: String, put_tag_annotations_form: Value, ) -> Result<Value>
设定指定 tag 的元数据。Set the metadata of the specified tag.
Sourcepub async fn get_repo_git_commit_statuses_commitish(
&self,
repo: String,
commitish: String,
) -> Result<Value>
pub async fn get_repo_git_commit_statuses_commitish( &self, repo: String, commitish: String, ) -> Result<Value>
查询指定 commit 的 check statuses。List commit check statuses.
Sourcepub async fn get_repo_git_deferred_commits(
&self,
repo: String,
cs: String,
) -> Result<Value>
pub async fn get_repo_git_deferred_commits( &self, repo: String, cs: String, ) -> Result<Value>
查询 deferred commit 列表
Sourcepub async fn delete_repo_git_tag_annotations_tag_with_key(
&self,
repo: String,
tag_with_key: String,
) -> Result<Value>
pub async fn delete_repo_git_tag_annotations_tag_with_key( &self, repo: String, tag_with_key: String, ) -> Result<Value>
删除指定 tag 的元数据。Delete the metadata of the specified tag.
Sourcepub async fn get_repo_git_commit_assets_sha_1(
&self,
repo: String,
sha_1: String,
) -> Result<Value>
pub async fn get_repo_git_commit_assets_sha_1( &self, repo: String, sha_1: String, ) -> Result<Value>
查询指定 commit 的附件。List commit assets.
查询标签列表。List tags.
创建一个 tag。Create a tag.
Sourcepub async fn post_repo_git_commit_annotations_in_batch(
&self,
repo: String,
get_commit_annotations_form: Value,
) -> Result<Value>
pub async fn post_repo_git_commit_annotations_in_batch( &self, repo: String, get_commit_annotations_form: Value, ) -> Result<Value>
查询指定 commit 的元数据。Get commit annotations in batch.
Sourcepub async fn post_repo_git_commit_assets_sha_1_asset_upload_confirmation_upload_token_asset_path(
&self,
repo: String,
sha_1: String,
token: String,
asset_path: String,
) -> Result<Value>
pub async fn post_repo_git_commit_assets_sha_1_asset_upload_confirmation_upload_token_asset_path( &self, repo: String, sha_1: String, token: String, asset_path: String, ) -> Result<Value>
确认 Commit asset 上传完成。Confirm commit asset upload.
Sourcepub async fn get_repo_git_archive_commit_changed_files_sha_1(
&self,
repo: String,
sha_1: String,
) -> Result<Value>
pub async fn get_repo_git_archive_commit_changed_files_sha_1( &self, repo: String, sha_1: String, ) -> Result<Value>
打包下载 commit 变更文件。Download archive of changed files for a commit.
Sourcepub async fn delete_repo_git_commit_annotations_sha_key(
&self,
repo: String,
sha: String,
key: String,
) -> Result<Value>
pub async fn delete_repo_git_commit_annotations_sha_key( &self, repo: String, sha: String, key: String, ) -> Result<Value>
删除指定 commit 的元数据。Delete commit annotation.
查询指定 Tag。Get a tag.
删除指定标签。Delete the specified tag.
Sourcepub async fn delete_repo_git_commit_assets_sha_1_asset_id(
&self,
repo: String,
sha_1: String,
asset_id: String,
) -> Result<Value>
pub async fn delete_repo_git_commit_assets_sha_1_asset_id( &self, repo: String, sha_1: String, asset_id: String, ) -> Result<Value>
删除指定 commit 的附件。Delete commit asset.
Sourcepub async fn get_repo_git_contents_file_path(
&self,
repo: String,
file_path: String,
ref: Option<String>,
) -> Result<Value>
pub async fn get_repo_git_contents_file_path( &self, repo: String, file_path: String, ref: Option<String>, ) -> Result<Value>
查询仓库文件列表或文件。List repository files or file.
Sourcepub async fn get_repo_git_head(&self, repo: String) -> Result<Value>
pub async fn get_repo_git_head(&self, repo: String) -> Result<Value>
获取仓库默认分支。Get the default branch of the repository.
Sourcepub async fn get_repo_git_commits_ref(
&self,
repo: String,
ref: String,
) -> Result<Value>
pub async fn get_repo_git_commits_ref( &self, repo: String, ref: String, ) -> Result<Value>
查询指定 commit。Get a commit.
Sourcepub async fn get_repo_git_compare_base_head(
&self,
repo: String,
base_head: String,
) -> Result<Value>
pub async fn get_repo_git_compare_base_head( &self, repo: String, base_head: String, ) -> Result<Value>
对比 base…head。Compare two commits.