MCPcopy Create free account
hub / github.com/OpenAtomFoundation/SmartIDE / Decode

Function Decode

cli/pkg/ssh_config/config.go:300–306  ·  view source on GitHub ↗

Decode reads r into a Config, or returns an error if r could not be parsed as an SSH config file.

(r io.Reader)

Source from the content-addressed store, hash-verified

298// Decode reads r into a Config, or returns an error if r could not be parsed as
299// an SSH config file.
300func Decode(r io.Reader) (*Config, error) {
301 b, err := io.ReadAll(r)
302 if err != nil {
303 return nil, err
304 }
305 return decodeBytes(b, false, 0)
306}
307
308// DecodeBytes reads b into a Config, or returns an error if r could not be
309// parsed as an SSH config file.

Callers 1

TestIOErrorFunction · 0.85

Calls 1

decodeBytesFunction · 0.85

Tested by 1

TestIOErrorFunction · 0.68