Declare the Copy API

This commit is contained in:
Sylvain Nieuwlandt
2024-03-17 19:37:38 +01:00
committed by André Roth
parent d8c1e432c6
commit 8114786179
2 changed files with 6 additions and 0 deletions

View File

@@ -414,6 +414,11 @@ func apiReposPackageFromDir(c *gin.Context) {
})
}
// POST /repos/:name/copy/:src/:file
func apiReposCopyPackage(c *gin.Context) {
// TODO
}
// POST /repos/:name/include/:dir/:file
func apiReposIncludePackageFromFile(c *gin.Context) {
// redirect all work to dir method

View File

@@ -116,6 +116,7 @@ func Router(c *ctx.AptlyContext) http.Handler {
api.POST("/repos/:name/file/:dir/:file", apiReposPackageFromFile)
api.POST("/repos/:name/file/:dir", apiReposPackageFromDir)
api.POST("/repos/:name/copy/:src/:file", apiReposCopyPackage)
api.POST("/repos/:name/include/:dir/:file", apiReposIncludePackageFromFile)
api.POST("/repos/:name/include/:dir", apiReposIncludePackageFromDir)