Skip to content

Comments

[fst-bin] Add a commandline option '--delimiter' to map.#147

Open
jakob-ledermann wants to merge 1 commit intoBurntSushi:masterfrom
jakob-ledermann:allow_specifing_the_csv_delimiter
Open

[fst-bin] Add a commandline option '--delimiter' to map.#147
jakob-ledermann wants to merge 1 commit intoBurntSushi:masterfrom
jakob-ledermann:allow_specifing_the_csv_delimiter

Conversation

@jakob-ledermann
Copy link

This commandline option allows to specify the delimiter between keys and the values in the input file to the map subcommand.

The provided delimiter should be a single byte utf-8 character. If the value consists of multiple bytes only the first one is used. This parameter is passed to csv::ReaderBuilder::delimiter which only allows for a single byte as delimiter.

Motivation

This is motivated by a colon used as separator between the keys and values. Fundamentaly resulting in issue #146, as I needed to write my own generator binary (where I missed the call to finish). With this option I would not have needed to use a custom implementation or could have used the official binary to compare the behaviour.

This commandline option allows to specify the delimiter between keys and the values
in the input file to the `map` subcommand.

The provided delimiter should be a single byte utf-8 character.
If the value consists of multiple bytes only the first one is used.
This parameter is passed to `csv::ReaderBuilder::delimiter` which only
allows for a single byte as delimiter.
@yuzhichang
Copy link

I need this too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants