https://github.com/faradayio/csvkiller
Segment CSV files by any column
https://github.com/faradayio/csvkiller
Last synced: 8 months ago
JSON representation
Segment CSV files by any column
- Host: GitHub
- URL: https://github.com/faradayio/csvkiller
- Owner: faradayio
- License: mit
- Created: 2014-07-01T18:41:33.000Z (almost 12 years ago)
- Default Branch: master
- Last Pushed: 2015-03-06T21:34:00.000Z (over 11 years ago)
- Last Synced: 2025-01-21T08:37:27.897Z (over 1 year ago)
- Language: JavaScript
- Size: 293 KB
- Stars: 6
- Watchers: 9
- Forks: 1
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
csvkiller
=========
Segment CSV files by any column
#Dependencies
nodejs, npm, and bash
#Installation
Depending on your environment you may need to run this as root
```bash
npm install -g csvkiller
```
#Usage
```
Usage: csvkiller -c [column] [options] [file ...]
Options:
-h, --help output usage information
-V, --version output the version number
-c, --column [name] Which column to segment by
-d, --delimiter [delimiter] How to split up lines in the input file (use TAB for tab-delimited) [,]
-o, --output-directory [path] Output directory [./output]
-od, --output-delimiter [delimiter] How to split up lines in the output files (use TAB for tab-delimited) [,]
-b, --buffer-size [characters] Max characters in the output buffer [1000000]
-u, --uppercase Case insensitive column matching, write to OUTPUT.csv instead of Output.csv
-l, --lowercase Case insensitive column matching, write to output.csv instead of Output.csv
-v, --verbose Verbose output
```
#Examples
Turn `people.csv` into `output/male.csv` and `output/female.csv`
```bash
csvkiller -d TAB -c gender people.tsv
```
Combine `*.csv` into `output/Alabama.csv`, `output/Alaska.csv`, etc
```bash
csvkiller -c state *.csv
```