MCPcopy Index your code
hub / github.com/coder/coder / CommandContext

Method CommandContext

agent/agentcontainers/execer.go:63–69  ·  view source on GitHub ↗
(ctx context.Context, cmd string, args ...string)

Source from the content-addressed store, hash-verified

61}
62
63func (e *commandEnvExecer) CommandContext(ctx context.Context, cmd string, args ...string) *exec.Cmd {
64 name, args, dir, env := e.prepare(ctx, cmd, args...)
65 c := e.execer.CommandContext(ctx, name, args...)
66 c.Dir = dir
67 c.Env = env
68 return c
69}
70
71func (e *commandEnvExecer) PTYCommandContext(ctx context.Context, cmd string, args ...string) *pty.Cmd {
72 name, args, dir, env := e.prepare(ctx, cmd, args...)

Callers

nothing calls this directly

Calls 2

prepareMethod · 0.95
CommandContextMethod · 0.65

Tested by

no test coverage detected