mirror of
https://github.com/aptly-dev/aptly.git
synced 2026-04-20 19:38:39 +00:00
swagger: make json params uppercase and add default values
This commit is contained in:
20
api/repos.go
20
api/repos.go
@@ -70,16 +70,16 @@ func apiReposList(c *gin.Context) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
type repoCreateParams struct {
|
type repoCreateParams struct {
|
||||||
// local repository name
|
// Name of repository to create
|
||||||
Name string `binding:"required"`
|
Name string `binding:"required" json:"Name" example:"repo1"`
|
||||||
// text describing local repository, for the user
|
// Text describing the repository (optional)
|
||||||
Comment string
|
Comment string ` json:"Comment" example:"this is a repo"`
|
||||||
// default distribution when publishing from this local repo
|
// Default distribution when publishing from this local repo
|
||||||
DefaultDistribution string
|
DefaultDistribution string ` json:"DefaultDistribution" example:"stable"`
|
||||||
// default component when publishing from this local repo
|
// Default component when publishing from this local repo
|
||||||
DefaultComponent string
|
DefaultComponent string ` json:"DefaultComponent" example:"main"`
|
||||||
// snapshot name to create repo from
|
// Snapshot name to create repoitory from (optional)
|
||||||
FromSnapshot string
|
FromSnapshot string ` json:"FromSnapshot" example:"snapshot1"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// @Summary Create repository
|
// @Summary Create repository
|
||||||
|
|||||||
Reference in New Issue
Block a user