From 995c393ca7d78c410ff4d356a27f16fb694e84ef Mon Sep 17 00:00:00 2001 From: gitnexbot Date: Wed, 10 May 2023 00:05:23 +0000 Subject: [PATCH] Synchronizing API and documentation updates --- docs/CreateBranchRepoOption.md | 3 +- docs/RepositoryApi.md | 8 +++-- .../gitnex/tea4j/v2/apis/RepositoryApi.java | 6 ++++ .../v2/models/CreateBranchRepoOption.java | 32 ++++++++++++++++--- 4 files changed, 42 insertions(+), 7 deletions(-) diff --git a/docs/CreateBranchRepoOption.md b/docs/CreateBranchRepoOption.md index d82d5e3..4a6fec9 100644 --- a/docs/CreateBranchRepoOption.md +++ b/docs/CreateBranchRepoOption.md @@ -4,4 +4,5 @@ Name | Type | Description | Notes ------------ | ------------- | ------------- | ------------- **newBranchName** | **String** | Name of the branch to create | -**oldBranchName** | **String** | Name of the old branch to create from | [optional] +**oldBranchName** | **String** | Deprecated: true Name of the old branch to create from | [optional] +**oldRefName** | **String** | Name of the old branch/tag/commit to create from | [optional] diff --git a/docs/RepositoryApi.md b/docs/RepositoryApi.md index d3f0e0a..d3f6888 100644 --- a/docs/RepositoryApi.md +++ b/docs/RepositoryApi.md @@ -5649,7 +5649,7 @@ Name | Type | Description | Notes # **repoGetAllCommits** -> List<Commit> repoGetAllCommits(owner, repo, sha, path, stat, page, limit, not) +> List<Commit> repoGetAllCommits(owner, repo, sha, path, stat, verification, files, page, limit, not) Get a list of all commits from a repository @@ -5710,11 +5710,13 @@ String repo = "repo_example"; // String | name of the repo String sha = "sha_example"; // String | SHA or branch to start listing commits from (usually 'master') String path = "path_example"; // String | filepath of a file/dir Boolean stat = true; // Boolean | include diff stats for every commit (disable for speedup, default 'true') +Boolean verification = true; // Boolean | include verification for every commit (disable for speedup, default 'true') +Boolean files = true; // Boolean | include a list of affected files for every commit (disable for speedup, default 'true') Integer page = 56; // Integer | page number of results to return (1-based) Integer limit = 56; // Integer | page size of results (ignored if used with 'path') String not = "not_example"; // String | commits that match the given specifier will not be listed. try { - List result = apiInstance.repoGetAllCommits(owner, repo, sha, path, stat, page, limit, not); + List result = apiInstance.repoGetAllCommits(owner, repo, sha, path, stat, verification, files, page, limit, not); System.out.println(result); } catch (ApiException e) { System.err.println("Exception when calling RepositoryApi#repoGetAllCommits"); @@ -5731,6 +5733,8 @@ Name | Type | Description | Notes **sha** | **String**| SHA or branch to start listing commits from (usually 'master') | [optional] **path** | **String**| filepath of a file/dir | [optional] **stat** | **Boolean**| include diff stats for every commit (disable for speedup, default 'true') | [optional] + **verification** | **Boolean**| include verification for every commit (disable for speedup, default 'true') | [optional] + **files** | **Boolean**| include a list of affected files for every commit (disable for speedup, default 'true') | [optional] **page** | **Integer**| page number of results to return (1-based) | [optional] **limit** | **Integer**| page size of results (ignored if used with 'path') | [optional] **not** | **String**| commits that match the given specifier will not be listed. | [optional] diff --git a/src/main/java/org/gitnex/tea4j/v2/apis/RepositoryApi.java b/src/main/java/org/gitnex/tea4j/v2/apis/RepositoryApi.java index 2a5493c..c112860 100644 --- a/src/main/java/org/gitnex/tea4j/v2/apis/RepositoryApi.java +++ b/src/main/java/org/gitnex/tea4j/v2/apis/RepositoryApi.java @@ -1003,6 +1003,10 @@ public interface RepositoryApi { * @param path filepath of a file/dir (optional) * @param stat include diff stats for every commit (disable for speedup, default 'true') * (optional) + * @param verification include verification for every commit (disable for speedup, default + * 'true') (optional) + * @param files include a list of affected files for every commit (disable for speedup, default + * 'true') (optional) * @param page page number of results to return (1-based) (optional) * @param limit page size of results (ignored if used with 'path') (optional) * @param not commits that match the given specifier will not be listed. (optional) @@ -1015,6 +1019,8 @@ public interface RepositoryApi { @retrofit2.http.Query("sha") String sha, @retrofit2.http.Query("path") String path, @retrofit2.http.Query("stat") Boolean stat, + @retrofit2.http.Query("verification") Boolean verification, + @retrofit2.http.Query("files") Boolean files, @retrofit2.http.Query("page") Integer page, @retrofit2.http.Query("limit") Integer limit, @retrofit2.http.Query("not") String not); diff --git a/src/main/java/org/gitnex/tea4j/v2/models/CreateBranchRepoOption.java b/src/main/java/org/gitnex/tea4j/v2/models/CreateBranchRepoOption.java index 2057481..095956b 100644 --- a/src/main/java/org/gitnex/tea4j/v2/models/CreateBranchRepoOption.java +++ b/src/main/java/org/gitnex/tea4j/v2/models/CreateBranchRepoOption.java @@ -28,6 +28,9 @@ public class CreateBranchRepoOption implements Serializable { @SerializedName("old_branch_name") private String oldBranchName = null; + @SerializedName("old_ref_name") + private String oldRefName = null; + public CreateBranchRepoOption newBranchName(String newBranchName) { this.newBranchName = newBranchName; return this; @@ -53,11 +56,11 @@ public class CreateBranchRepoOption implements Serializable { } /** - * Name of the old branch to create from + * Deprecated: true Name of the old branch to create from * * @return oldBranchName */ - @Schema(description = "Name of the old branch to create from") + @Schema(description = "Deprecated: true Name of the old branch to create from") public String getOldBranchName() { return oldBranchName; } @@ -66,6 +69,25 @@ public class CreateBranchRepoOption implements Serializable { this.oldBranchName = oldBranchName; } + public CreateBranchRepoOption oldRefName(String oldRefName) { + this.oldRefName = oldRefName; + return this; + } + + /** + * Name of the old branch/tag/commit to create from + * + * @return oldRefName + */ + @Schema(description = "Name of the old branch/tag/commit to create from") + public String getOldRefName() { + return oldRefName; + } + + public void setOldRefName(String oldRefName) { + this.oldRefName = oldRefName; + } + @Override public boolean equals(java.lang.Object o) { if (this == o) { @@ -76,12 +98,13 @@ public class CreateBranchRepoOption implements Serializable { } CreateBranchRepoOption createBranchRepoOption = (CreateBranchRepoOption) o; return Objects.equals(this.newBranchName, createBranchRepoOption.newBranchName) - && Objects.equals(this.oldBranchName, createBranchRepoOption.oldBranchName); + && Objects.equals(this.oldBranchName, createBranchRepoOption.oldBranchName) + && Objects.equals(this.oldRefName, createBranchRepoOption.oldRefName); } @Override public int hashCode() { - return Objects.hash(newBranchName, oldBranchName); + return Objects.hash(newBranchName, oldBranchName, oldRefName); } @Override @@ -91,6 +114,7 @@ public class CreateBranchRepoOption implements Serializable { sb.append(" newBranchName: ").append(toIndentedString(newBranchName)).append("\n"); sb.append(" oldBranchName: ").append(toIndentedString(oldBranchName)).append("\n"); + sb.append(" oldRefName: ").append(toIndentedString(oldRefName)).append("\n"); sb.append("}"); return sb.toString(); }