mirror of
https://github.com/mikefarah/yq.git
synced 2024-11-12 05:38:04 +00:00
24 lines
428 B
Go
24 lines
428 B
Go
package yqlib
|
|
|
|
type CsvPreferences struct {
|
|
Separator rune
|
|
AutoParse bool
|
|
}
|
|
|
|
func NewDefaultCsvPreferences() CsvPreferences {
|
|
return CsvPreferences{
|
|
Separator: ',',
|
|
AutoParse: true,
|
|
}
|
|
}
|
|
|
|
func NewDefaultTsvPreferences() CsvPreferences {
|
|
return CsvPreferences{
|
|
Separator: '\t',
|
|
AutoParse: true,
|
|
}
|
|
}
|
|
|
|
var ConfiguredCsvPreferences = NewDefaultCsvPreferences()
|
|
var ConfiguredTsvPreferences = NewDefaultTsvPreferences()
|