MCPcopy Index your code
hub / github.com/git-bug/git-bug / Init

Method Init

bridge/github/export.go:63–76  ·  view source on GitHub ↗

Init .

(_ context.Context, repo *cache.RepoCache, conf core.Configuration)

Source from the content-addressed store, hash-verified

61
62// Init .
63func (ge *githubExporter) Init(_ context.Context, repo *cache.RepoCache, conf core.Configuration) error {
64 ge.conf = conf
65 ge.identityClient = make(map[entity.Id]*rateLimitHandlerClient)
66 ge.cachedOperationIDs = make(map[entity.Id]string)
67 ge.cachedLabels = make(map[string]string)
68
69 // preload all clients
70 err := ge.cacheAllClient(repo)
71 if err != nil {
72 return err
73 }
74
75 return nil
76}
77
78func (ge *githubExporter) cacheAllClient(repo *cache.RepoCache) error {
79 creds, err := auth.List(repo, auth.WithTarget(target), auth.WithKind(auth.KindToken))

Callers 1

TestGithubPushPullFunction · 0.95

Calls 1

cacheAllClientMethod · 0.95

Tested by 1

TestGithubPushPullFunction · 0.76