MCPcopy Create free account
hub / github.com/conforma/cli / inputFromString

Function inputFromString

internal/input/validate.go:142–148  ·  view source on GitHub ↗

write the input file if a json or yaml string is provided

(ctx context.Context, data string)

Source from the content-addressed store, hash-verified

140
141// write the input file if a json or yaml string is provided
142func inputFromString(ctx context.Context, data string) ([]string, error) {
143 data, err := utils.WriteTempFile(ctx, data, "input-file-")
144 if err != nil {
145 return nil, err
146 }
147 return []string{data}, nil
148}

Callers 1

detectInputFunction · 0.85

Calls 1

WriteTempFileFunction · 0.92

Tested by

no test coverage detected