Move sdk from code.gitea.io/sdk/gitea to gitea.dev/sdk (#1006)

Reviewed-on: https://gitea.com/gitea/tea/pulls/1006
Reviewed-by: Zettat123 <39446+zettat123@noreply.gitea.com>
This commit is contained in:
Lunny Xiao
2026-05-26 04:51:09 +00:00
parent 579099f9d9
commit 28ba9b915b
179 changed files with 617 additions and 599 deletions
+4 -4
View File
@@ -6,7 +6,7 @@ package cmd
import (
stdctx "context"
"code.gitea.io/sdk/gitea"
gitea "gitea.dev/sdk"
"gitea.dev/tea/cmd/repos"
"gitea.dev/tea/modules/context"
@@ -44,18 +44,18 @@ func runRepos(ctx stdctx.Context, cmd *cli.Command) error {
return repos.RunReposList(ctx, cmd)
}
func runRepoDetail(_ stdctx.Context, cmd *cli.Command, path string) error {
func runRepoDetail(requestCtx stdctx.Context, cmd *cli.Command, path string) error {
ctx, err := context.InitCommand(cmd)
if err != nil {
return err
}
client := ctx.Login.Client()
repoOwner, repoName := utils.GetOwnerAndRepo(path, ctx.Owner)
repo, _, err := client.GetRepo(repoOwner, repoName)
repo, _, err := client.Repositories.GetRepo(requestCtx, repoOwner, repoName)
if err != nil {
return err
}
topics, _, err := client.ListRepoTopics(repoOwner, repoName, gitea.ListRepoTopicsOptions{})
topics, _, err := client.Repositories.ListRepoTopics(requestCtx, repoOwner, repoName, gitea.ListRepoTopicsOptions{})
if err != nil {
return err
}