Use duck for util-csv exclusively.
This commit is contained in:
parent
2fb41c172e
commit
77f1de6e36
3 changed files with 20 additions and 28 deletions
|
@ -51,3 +51,15 @@ Curried version of fast CSV line parser with given separator and string delimite
|
|||
* ```separator``` - separator character
|
||||
* ```string-delimiger``` - string quotation character
|
||||
* ```line``` - line to parse
|
||||
|
||||
### csv-parse-lines [procedure]
|
||||
|
||||
(csv-parse-lines lines separator: (separator ;) string-delimiter: (string-delimiter "))
|
||||
|
||||
Parses given lines and returns list of lists of strings.
|
||||
|
||||
### csv-parse [procedure]
|
||||
|
||||
(csv-parse fn . args)
|
||||
|
||||
Uses ```csv-parse-lines``` on lines read from given file ```fn```.
|
||||
|
|
23
doc/utils.md
23
doc/utils.md
|
@ -8,29 +8,6 @@ well.
|
|||
|
||||
The modules are listed in alphabetical order.
|
||||
|
||||
### CSV
|
||||
|
||||
(import util-csv)
|
||||
|
||||
This module provides a very simple, incomplete and incorrect but fast
|
||||
CSV loader.
|
||||
|
||||
(csv-parse filename
|
||||
[#:separator #\;]
|
||||
[#:string-delimiter #\"])
|
||||
|
||||
* ```separator``` - cell separator in CSV file
|
||||
* ```string-delimiter``` - for introducing strings possibly with separators
|
||||
|
||||
Parses given CSV file and returns list of lists of strings
|
||||
representing its contents.
|
||||
|
||||
(csv-split-header csv)
|
||||
|
||||
* ```csv``` - list of lists of strings
|
||||
|
||||
Splits given loaded CSV into two tables at the first empty row.
|
||||
|
||||
### Dictionary
|
||||
|
||||
(import util-dict-list)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue