Skip to content

Commit 0c4a1bf

Browse files
committed
fixing formatting
1 parent 79206db commit 0c4a1bf

34 files changed

+593
-564
lines changed

cmds/csv2xlsx/csv2xlsx.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ If the Workbook does not exist then it is created.
5050

5151
examples = `
5252
53-
EXAMPLE
53+
EXAMPLES
5454
5555
%s -i data.csv MyWorkbook.xlsx 'My worksheet'
5656

cmds/joinstring/joinstring.go

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,12 +54,15 @@ This should yield
5454
5555
Joining a newline delimited file into a single string
5656
57-
cat <<EOF > %s -nl -d '||' "one||two||three"
58-
one
57+
cat myfile.txt | %s -nl -d '||' "one||two||three"
58+
59+
where myfile.txt holds
60+
61+
one
5962
two
6063
three
61-
EOF
62-
This should yield
64+
65+
should yield
6366
6467
one||two||three
6568

cmds/range/range.go

Lines changed: 17 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,26 +56,37 @@ down otherwise it counts up.
5656
5757
EXAMPLES
5858
59-
Yields 1 2 3 4 5
60-
59+
Create a range of integers one through five
60+
6161
%s 1 5
6262
63-
Yields -2 -1 0 1 2 3 4 5 6
63+
Yields 1 2 3 4 5
64+
65+
Create a range of integer negative two to six
6466
6567
%s -- -2 6
6668
67-
Yields 2 4 6 8 10
69+
Yields -2 -1 0 1 2 3 4 5 6
70+
71+
Create a range of even integers two to ten
6872
6973
%s -increment=2 2 10
7074
71-
Yields 10 9 8 7 6 5 4 3 2 1
75+
Yields 2 4 6 8 10
76+
77+
Create a descending range of integers ten down to one
7278
7379
%s 10 1
7480
75-
Yields a random integer from 0 to 10
81+
Yields 10 9 8 7 6 5 4 3 2 1
82+
83+
84+
Pick a random integer between zero and ten
7685
7786
%s -r 0 10
7887
88+
Yields a random integer from 0 to 10
89+
7990
`
8091

8192
// Standard Options

docs/csv2json.md

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -12,21 +12,21 @@ per line.
1212
## OPTIONS
1313

1414
```
15-
-as-blobs output as one JSON blob per line
16-
-d set the delimter character
17-
-delimiter set the delimter character
18-
-example display example(s)
19-
-h display help
20-
-help display help
21-
-i input filename
22-
-input input filename
23-
-l display license
24-
-license display license
25-
-o output filename
26-
-output output filename
27-
-use-header treat the first row as field names
28-
-v display version
29-
-version display version
15+
-as-blobs output as one JSON blob per line
16+
-d set the delimter character
17+
-delimiter set the delimter character
18+
-example display example(s)
19+
-h display help
20+
-help display help
21+
-i input filename
22+
-input input filename
23+
-l display license
24+
-license display license
25+
-o output filename
26+
-output output filename
27+
-use-header treat the first row as field names
28+
-v display version
29+
-version display version
3030
```
3131

3232
## EXAMPLES

docs/csv2mdtable.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,19 +11,19 @@ table to stdout.
1111
## OPTIONS
1212

1313
```
14-
-d set delimiter character
15-
-delimiter set delimiter character
16-
-example display example(s)
17-
-h display help
18-
-help display help
19-
-i input filename
20-
-input input filename
21-
-l display license
22-
-license display license
23-
-o output filename
24-
-output output filename
25-
-v display version
26-
-version display version
14+
-d set delimiter character
15+
-delimiter set delimiter character
16+
-example display example(s)
17+
-h display help
18+
-help display help
19+
-i input filename
20+
-input input filename
21+
-l display license
22+
-license display license
23+
-o output filename
24+
-output output filename
25+
-v display version
26+
-version display version
2727
```
2828

2929
## EXAMPLES

docs/csv2xlsx.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -11,32 +11,32 @@ If the Workbook does not exist then it is created.
1111
## OPTIONS
1212

1313
```
14-
-d set delimiter character (input)
15-
-delimiter set delimiter character (input)
16-
-example display example(s)
17-
-h display help
18-
-help display help
19-
-i input filename (CSV content)
20-
-input input filename (CSV content)
21-
-l display license
22-
-license display license
23-
-sheet Sheet name to create/replace
24-
-v display version
25-
-version display version
26-
-workbook Workbook name
14+
-d set delimiter character (input)
15+
-delimiter set delimiter character (input)
16+
-example display example(s)
17+
-h display help
18+
-help display help
19+
-i input filename (CSV content)
20+
-input input filename (CSV content)
21+
-l display license
22+
-license display license
23+
-sheet Sheet name to create/replace
24+
-v display version
25+
-version display version
26+
-workbook Workbook name
2727
```
2828

29-
## EXAMPLE
29+
## EXAMPLES
3030

3131
```shell
32-
csv2xlsx -i data.csv MyWorkbook.xlsx 'My worksheet'
32+
csv2xlsx -i data.csv MyWorkbook.xlsx 'My worksheet'
3333
```
3434

3535
This creates a new 'My worksheet' in the Excel Workbook
3636
called 'MyWorkbook.xlsx' with the contents of data.csv.
3737

3838
```shell
39-
cat data.csv | csv2xlsx MyWorkbook.xlsx 'My worksheet'
39+
cat data.csv | csv2xlsx MyWorkbook.xlsx 'My worksheet'
4040
```
4141

4242
This does the same but the contents of data.csv are piped into

docs/csvcleaner.md

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -17,29 +17,29 @@ minimal memory is used to operate on the file.
1717
## OPTIONS
1818

1919
```
20-
-comma if set use this character in place of a comma for delimiting cells
21-
-comment-char if set, rows starting with this character will be ignored as comments
22-
-example display example(s)
23-
-fields-per-row set the number of columns to output right padding empty cells as needed
24-
-h display help
25-
-help display help
26-
-i input filename
27-
-input input filename
28-
-l display license
29-
-left-trim-spaces If set to true leading white space in a field is ignored.
30-
-license display license
31-
-o output filename
32-
-output output filename
33-
-output-comma if set use this character in place of a comma for delimiting output cells
34-
-reuse if false then a new array is allocated for each row processed, if true the array gets reused
35-
-right-trim-spaces If set to true trailing white space in a field is ignored.
36-
-stop-on-error exit on error, useful if you're trying to debug a problematic CSV file
37-
-trim-spaces If set to true leading and trailing white space in a field is ignored.
38-
-use-crlf if set use a charage return and line feed in output
39-
-use-lazy-quoting If LazyQuotes is true, a quote may appear in an unquoted field and a non-doubled quote may appear in a quoted field.
40-
-v display version
41-
-verbose write verbose output to standard error
42-
-version display version
20+
-comma if set use this character in place of a comma for delimiting cells
21+
-comment-char if set, rows starting with this character will be ignored as comments
22+
-example display example(s)
23+
-fields-per-row set the number of columns to output right padding empty cells as needed
24+
-h display help
25+
-help display help
26+
-i input filename
27+
-input input filename
28+
-l display license
29+
-left-trim-spaces If set to true leading white space in a field is ignored.
30+
-license display license
31+
-o output filename
32+
-output output filename
33+
-output-comma if set use this character in place of a comma for delimiting output cells
34+
-reuse if false then a new array is allocated for each row processed, if true the array gets reused
35+
-right-trim-spaces If set to true trailing white space in a field is ignored.
36+
-stop-on-error exit on error, useful if you're trying to debug a problematic CSV file
37+
-trim-spaces If set to true leading and trailing white space in a field is ignored.
38+
-use-crlf if set use a charage return and line feed in output
39+
-use-lazy-quoting If LazyQuotes is true, a quote may appear in an unquoted field and a non-doubled quote may appear in a quoted field.
40+
-v display version
41+
-verbose write verbose output to standard error
42+
-version display version
4343
```
4444

4545
## EXAMPLES

docs/csvcols.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -12,23 +12,23 @@ listed on the commandline (first column is 1 not 0).
1212
## OPTIONS
1313

1414
```
15-
-col output specified columns (e.g. -col 1,12:14,2,4))
16-
-cols output specified columns (e.g. -col 1,12:14,2,4))
17-
-d set delimiter character
18-
-delimiter set delimiter character
19-
-example display example
20-
-h display help
21-
-help display help
22-
-i input filename
23-
-input input filename
24-
-l display license
25-
-license display license
26-
-o output filename
27-
-output output filename
28-
-skip-header-row skip the header row
29-
-uuid add a prefix row with generated UUID cell
30-
-v display version
31-
-version display version
15+
-col output specified columns (e.g. -col 1,12:14,2,4))
16+
-cols output specified columns (e.g. -col 1,12:14,2,4))
17+
-d set delimiter character
18+
-delimiter set delimiter character
19+
-example display example
20+
-h display help
21+
-help display help
22+
-i input filename
23+
-input input filename
24+
-l display license
25+
-license display license
26+
-o output filename
27+
-output output filename
28+
-skip-header-row skip the header row
29+
-uuid add a prefix row with generated UUID cell
30+
-v display version
31+
-version display version
3232
```
3333

3434
## EXAMPLES

docs/csvfind.md

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -12,32 +12,32 @@ exact match as well as some Levenshtein matching.
1212
## OPTIONS
1313

1414
```
15-
-allow-duplicates allow duplicates when searching for matches
16-
-append-edit-distance append column with edit distance found (useful for tuning levenshtein)
17-
-case-sensitive perform a case sensitive match (default is false)
18-
-col column to search for match in the CSV file
19-
-contains use contains phrase for matching
20-
-d set delimiter character
21-
-delete-cost set the delete cost to use for levenshtein matching
22-
-delimiter set delimiter character
23-
-example display example(s)
24-
-h display help
25-
-help display help
26-
-i input filename
27-
-input input filename
28-
-insert-cost set the insert cost to use for levenshtein matching
29-
-l display license
30-
-levenshtein use levenshtein matching
31-
-license display license
32-
-max-edit-distance set the edit distance thresh hold for match, default 0
33-
-o output filename
34-
-output output filename
35-
-skip-header-row skip the header row
36-
-stop-words use the colon delimited list of stop words
37-
-substitute-cost set the substitution cost to use for levenshtein matching
38-
-trim-spaces trim spaces around cell values before comparing
39-
-v display version
40-
-version display version
15+
-allow-duplicates allow duplicates when searching for matches
16+
-append-edit-distance append column with edit distance found (useful for tuning levenshtein)
17+
-case-sensitive perform a case sensitive match (default is false)
18+
-col column to search for match in the CSV file
19+
-contains use contains phrase for matching
20+
-d set delimiter character
21+
-delete-cost set the delete cost to use for levenshtein matching
22+
-delimiter set delimiter character
23+
-example display example(s)
24+
-h display help
25+
-help display help
26+
-i input filename
27+
-input input filename
28+
-insert-cost set the insert cost to use for levenshtein matching
29+
-l display license
30+
-levenshtein use levenshtein matching
31+
-license display license
32+
-max-edit-distance set the edit distance thresh hold for match, default 0
33+
-o output filename
34+
-output output filename
35+
-skip-header-row skip the header row
36+
-stop-words use the colon delimited list of stop words
37+
-substitute-cost set the substitution cost to use for levenshtein matching
38+
-trim-spaces trim spaces around cell values before comparing
39+
-v display version
40+
-version display version
4141
```
4242

4343
## EXAMPLES

0 commit comments

Comments
 (0)