mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-08 03:29:43 +02:00
Add github compatible tarball download API endpoints (#32572)
Fix #29654 Fix #32481
This commit is contained in:
1 parent
44909f6e2c
commit
703be6bf30
7 files changed
+152
-31
No files matched your search
@@ -1377,6 +1377,8 @@ func Routes() *web.Router {
|
||||
m.Post("", bind(api.UpdateRepoAvatarOption{}), repo.UpdateAvatar)
|
||||
m.Delete("", repo.DeleteAvatar)
|
||||
}, reqAdmin(), reqToken())
|
||||
|
||||
m.Get("/{ball_type:tarball|zipball|bundle}/*", reqRepoReader(unit.TypeCode), repo.DownloadArchive)
|
||||
}, repoAssignment(), checkTokenPublicOnly())
|
||||
}, tokenRequiresScopes(auth_model.AccessTokenScopeCategoryRepository))
|
||||
|
||||
|
||||
Reference in new issue
Block a user