mirror of
https://gitea.com/gitea/tea.git
synced 2026-06-06 03:08:44 +02:00
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:
@@ -4,9 +4,10 @@
|
||||
package task
|
||||
|
||||
import (
|
||||
stdctx "context"
|
||||
"net/url"
|
||||
|
||||
"code.gitea.io/sdk/gitea"
|
||||
gitea "gitea.dev/sdk"
|
||||
|
||||
"gitea.dev/tea/modules/config"
|
||||
local_git "gitea.dev/tea/modules/git"
|
||||
@@ -15,13 +16,14 @@ import (
|
||||
// RepoClone creates a local git clone in the given path, and sets up upstream remote
|
||||
// for fork repos, for good usability with tea.
|
||||
func RepoClone(
|
||||
ctx stdctx.Context,
|
||||
path string,
|
||||
login *config.Login,
|
||||
repoOwner, repoName string,
|
||||
callback func(string) (string, error),
|
||||
depth int,
|
||||
) (*local_git.TeaRepo, error) {
|
||||
repoMeta, _, err := login.Client().GetRepo(repoOwner, repoName)
|
||||
repoMeta, _, err := login.Client().Repositories.GetRepo(ctx, repoOwner, repoName)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user