parseArgsData parses the given args in the format key=value into a map of the provided arguments. The given reader can also supply key=value pairs.
(stdin io.Reader, args []string)
| 133 | // parseArgsData parses the given args in the format key=value into a map of |
| 134 | // the provided arguments. The given reader can also supply key=value pairs. |
| 135 | func parseArgsData(stdin io.Reader, args []string) (map[string]interface{}, error) { |
| 136 | builder := &kvbuilder.Builder{Stdin: stdin} |
| 137 | if err := builder.Add(args...); err != nil { |
| 138 | return nil, err |
| 139 | } |
| 140 | |
| 141 | return builder.Map(), nil |
| 142 | } |
| 143 | |
| 144 | // parseArgsDataString parses the args data and returns the values as strings. |
| 145 | // If the values cannot be represented as strings, an error is returned. |
searching dependent graphs…