Discover Packages
github.com/go-faster/gooners
internal
sshutil
package
Version:
v0.2.0
Opens a new window with list of versions in this module.
Published: Jul 6, 2026
License: MIT
Opens a new window with license information.
Imports: 9
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
Documentation
¶
Package sshutil provides helpers for running commands over SSH connections.
DefaultTimeout is the default command execution timeout.
Defaults to 10 seconds.
Quote returns a shell-escaped version of s, safe to use as a single argument
in a POSIX shell command (e.g. via ssh).
RunWithContext runs a function f in a separate goroutine and returns its result
or returns a context error if the context is canceled before f completes.
type Result struct {
Stdout string `json:"stdout"`
Stderr string `json:"stderr"`
ExitCode int `json:"exit_code,omitempty"`
Error string `json:"error,omitempty"`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.