[CHORE] Fix swagger deprecation message

- Fix "WARNING: item list for enum is not a valid JSON array, using the
old deprecated format" messages from
https://github.com/go-swagger/go-swagger in the CI.
This commit is contained in:
Gusted 2024-08-09 23:36:03 +02:00
parent 784173f7e9
commit 851d567776
No known key found for this signature in database
GPG key ID: FD821B732837125F
11 changed files with 17 additions and 17 deletions

View file

@ -109,7 +109,7 @@ type Repository struct {
Internal bool `json:"internal"`
MirrorInterval string `json:"mirror_interval"`
// ObjectFormatName of the underlying git repository
// enum: sha1,sha256
// enum: ["sha1", "sha256"]
ObjectFormatName string `json:"object_format_name"`
// swagger:strfmt date-time
MirrorUpdated time.Time `json:"mirror_updated,omitempty"`
@ -154,10 +154,10 @@ type CreateRepoOption struct {
// DefaultBranch of the repository (used when initializes and in template)
DefaultBranch string `json:"default_branch" binding:"GitRefName;MaxSize(100)"`
// TrustModel of the repository
// enum: default,collaborator,committer,collaboratorcommitter
// enum: ["default", "collaborator", "committer", "collaboratorcommitter"]
TrustModel string `json:"trust_model"`
// ObjectFormatName of the underlying git repository
// enum: sha1,sha256
// enum: ["sha1", "sha256"]
ObjectFormatName string `json:"object_format_name" binding:"MaxSize(6)"`
}
@ -359,7 +359,7 @@ type MigrateRepoOptions struct {
// required: true
RepoName string `json:"repo_name" binding:"Required;AlphaDashDot;MaxSize(100)"`
// enum: git,github,gitea,gitlab,gogs,onedev,gitbucket,codebase
// enum: ["git", "github", "gitea", "gitlab", "gogs", "onedev", "gitbucket", "codebase"]
Service string `json:"service"`
AuthUsername string `json:"auth_username"`
AuthPassword string `json:"auth_password"`