WIP: adding CSV decoder

This commit is contained in:
Mike Farah
2022-07-31 17:31:27 +10:00
parent 4508bc2dc2
commit 183a42c249
6 changed files with 424 additions and 1 deletions
+4
View File
@@ -68,6 +68,10 @@ func configureDecoder() (yqlib.Decoder, error) {
return yqlib.NewPropertiesDecoder(), nil
case yqlib.JsonInputFormat:
return yqlib.NewJSONDecoder(), nil
case yqlib.CSVObjectInputFormat:
return yqlib.NewCSVObjectDecoder(','), nil
case yqlib.TSVObjectInputFormat:
return yqlib.NewCSVObjectDecoder('\t'), nil
}
return yqlib.NewYamlDecoder(), nil