MCPcopy Create free account
hub / github.com/devnullvoid/pvetui / CommandExecutor

Interface CommandExecutor

internal/ssh/executor.go:9–11  ·  view source on GitHub ↗

CommandExecutor abstracts exec.CommandContext to allow dependency injection.

Source from the content-addressed store, hash-verified

7
8// CommandExecutor abstracts exec.CommandContext to allow dependency injection.
9type CommandExecutor interface {
10 CommandContext(ctx context.Context, name string, args ...string) *exec.Cmd
11}
12
13// defaultExecutor is the default implementation using os/exec.
14type defaultExecutor struct{}

Callers 8

CommandContextMethod · 0.65
CommandContextMethod · 0.65
ExecuteNodeShellWithFunction · 0.65
ExecuteLXCShellWithFunction · 0.65
ExecuteQemuShellWithFunction · 0.65
executeSSHScriptFunction · 0.65
RunInventoryListMethod · 0.65
runAnsibleCommandFunction · 0.65

Implementers 2

defaultExecutorinternal/ssh/executor.go
mockExecutorinternal/ssh/client_test.go

Calls

no outgoing calls

Tested by

no test coverage detected