-
-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f139602
commit 23b6974
Showing
6 changed files
with
59 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,13 +34,22 @@ var RootCmd = &cobra.Command{ | |
Short: "Another cross-platform, efficient and practical CSV/TSV toolkit", | ||
Long: `Another cross-platform, efficient and practical CSV/TSV toolkit | ||
Version: 0.2.3 | ||
Version: 0.2.4 | ||
Author: Wei Shen <[email protected]> | ||
Documents : http://shenwei356.github.io/csvtk | ||
Source code: https://github.com/shenwei356/csvtk | ||
Attention: | ||
1. The CSV parser requires all the lines have same number of fields/columns. | ||
Even lines with spaces will cause error. | ||
2. By default, csvtk think your files have header row, if not, use "-H". | ||
3. By default, lines starting with '#' will be ignored, if the header row | ||
starts with '#', please assign "-C" another rare symbol, e.g. '$'. | ||
4. By default, csvtk handles CSV files, use "-t" for tab-delimited files. | ||
`, | ||
} | ||
|
||
|
@@ -60,7 +69,8 @@ func init() { | |
RootCmd.PersistentFlags().StringP("delimiter", "d", ",", `delimiting character of the input CSV file`) | ||
RootCmd.PersistentFlags().StringP("out-delimiter", "D", ",", `delimiting character of the input CSV file`) | ||
// RootCmd.PersistentFlags().StringP("quote-char", "q", `"`, `character used to quote strings in the input CSV file`) | ||
RootCmd.PersistentFlags().StringP("comment-char", "C", `#`, `commment character for start of line in the input CSV file`) | ||
RootCmd.PersistentFlags().StringP("comment-char", "C", `#`, "lines starting with commment-character will be ignored. "+ | ||
`if your header row starts with '#', please assign "-C" another rare symbol, e.g. '$'`) | ||
RootCmd.PersistentFlags().BoolP("lazy-quotes", "l", false, `if given, a quote may appear in an unquoted field and a non-doubled quote may appear in a quoted field`) | ||
|
||
RootCmd.PersistentFlags().BoolP("tabs", "t", false, `specifies that the input CSV file is delimited with tabs. Overrides "-d"`) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,39 @@ | ||
# Usage and Examples | ||
|
||
## Before use | ||
|
||
**Attention** | ||
|
||
1. The CSV parser requires all the lines have same number of fields/columns. | ||
Even lines with spaces will cause error. | ||
2. By default, csvtk think your files have header row, if not, use `-H`. | ||
3. By default, lines starting with `#` will be ignored, if the header row | ||
starts with `#`, please assign `-C` another rare symbol, e.g. `&`. | ||
4. By default, csvtk handles CSV files, use `-t` for tab-delimited files. | ||
|
||
## csvkit | ||
|
||
Usage | ||
|
||
``` | ||
Another cross-platform, efficient and practical CSV/TSV toolkit | ||
Version: 0.2.3 | ||
Version: 0.2.4 | ||
Author: Wei Shen <[email protected]> | ||
Documents : http://shenwei356.github.io/csvtk | ||
Source code: https://github.com/shenwei356/csvtk | ||
Attention: | ||
1. The CSV parser requires all the lines have same number of fields/columns. | ||
Even lines with spaces will cause error. | ||
2. By default, csvtk think your files have header row, if not, use "-H". | ||
3. By default, lines starting with '#' will be ignored, if the header row | ||
starts with '#', please assign "-C" another rare symbol, e.g. '&'. | ||
4. By default, csvtk handles CSV files, use "-t" for tab-delimited files. | ||
Usage: | ||
csvtk [command] | ||
|
@@ -22,7 +42,7 @@ Available Commands: | |
cut select parts of fields | ||
grep grep data by selected fields with patterns/regular expressions | ||
inter intersection of multiple files | ||
join join multiple CSV files by selected fields | ||
join join multiple CSV files by selected fields | ||
mutate create new column from selected fields by regular expression | ||
rename rename column names | ||
rename2 rename column names by regular expression | ||
|
@@ -36,16 +56,18 @@ Available Commands: | |
Flags: | ||
-c, --chunk-size int chunk size of CSV reader (default 50) | ||
-C, --comment-char string commment character for start of line in the input CSV file (default "#") | ||
-C, --comment-char string lines starting with commment-character will be ignored. if your header row starts with '#', please assign "-C" another rare symbol, e.g. '&' (default "#") | ||
-d, --delimiter string delimiting character of the input CSV file (default ",") | ||
-l, --lazy-quotes if given, a quote may appear in an unquoted field and a non-doubled quote may appear in a quoted field | ||
-H, --no-header-row specifies that the input CSV file does not have header row | ||
-j, --num-cups int number of CPUs to use (default value depends on your computer) (default 4) | ||
-j, --num-cpus int number of CPUs to use (default value depends on your computer) (default 4) | ||
-D, --out-delimiter string delimiting character of the input CSV file (default ",") | ||
-o, --out-file string out file ("-" for stdout, suffix .gz for gzipped out) (default "-") | ||
-T, --out-tabs specifies that the output is delimited with tabs. Overrides "-D" | ||
-t, --tabs specifies that the input CSV file is delimited with tabs. Overrides "-d" | ||
Use "csvtk [command] --help" for more information about a command. | ||
``` | ||
|
||
## stat | ||
|
Submodule site
updated
from 22be98 to d4d7e7