MCPcopy Index your code
hub / github.com/dagger/dagger / New

Method New

util/gitutil/cli.go:193–201  ·  view source on GitHub ↗

New returns a new git client with the same config as the current one, but with the given options applied on top.

(opts ...Option)

Source from the content-addressed store, hash-verified

191// New returns a new git client with the same config as the current one, but
192// with the given options applied on top.
193func (cli *GitCLI) New(opts ...Option) *GitCLI {
194 clone := *cli
195 clone.args = slices.Clone(cli.args)
196
197 for _, opt := range opts {
198 opt(&clone)
199 }
200 return &clone
201}
202
203// Run executes a git command with the given args.
204func (cli *GitCLI) Run(ctx context.Context, args ...string) (_ []byte, rerr error) {

Callers 1

CleanedMethod · 0.95

Calls 1

CloneMethod · 0.65

Tested by

no test coverage detected