summaryrefslogtreecommitdiffstats
path: root/office/x_x/x_x.1
blob: fb7529c462b8dc8cc16be6c6e111d8b5c31539dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
.\" Man page generated from reStructuredText.
.
.TH X_X 1 "2020-11-15" "20150330_d236f8f" "SlackBuilds.org"
.SH NAME
x_x \- display Excel and CSV files on a terminal
.
.nr rst2man-indent-level 0
.
.de1 rstReportMargin
\\$1 \\n[an-margin]
level \\n[rst2man-indent-level]
level margin: \\n[rst2man-indent\\n[rst2man-indent-level]]
-
\\n[rst2man-indent0]
\\n[rst2man-indent1]
\\n[rst2man-indent2]
..
.de1 INDENT
.\" .rstReportMargin pre:
. RS \\$1
. nr rst2man-indent\\n[rst2man-indent-level] \\n[an-margin]
. nr rst2man-indent-level +1
.\" .rstReportMargin post:
..
.de UNINDENT
. RE
.\" indent \\n[an-margin]
.\" old: \\n[rst2man-indent\\n[rst2man-indent-level]]
.nr rst2man-indent-level -1
.\" new: \\n[rst2man-indent\\n[rst2man-indent-level]]
.in \\n[rst2man-indent\\n[rst2man-indent-level]]u
..
.\" RST source for x_x(1) man page. Convert with:
.
.\" rst2man.py x_x.rst > x_x.1
.
.\" rst2man.py comes from the SBo development/docutils package.
.
.\" converting from pod:
.
.\" s/B<\([^>]*\)>/**\1**/g
.
.\" s/I<\([^>]*\)>/*\1*/g
.
.SH SYNOPSIS
.sp
x_x [\fB\-h\fP \fIrow\fP] [\fB\-f\fP \fIcsv|excel\fP] [\fB\-d\fP \fIdelimiter\fP] [\fB\-q\fP \fIquotechar\fP] [\fB\-e\fP \fIencoding\fP]
.SH DESCRIPTION
.sp
x_x (the Dead Guy CLI) is a command line reader that displays either
Excel files or CSVs in your terminal. The purpose of this is to not
break the workflow of people who live on the command line and need to
access a spreadsheet generated using Microsoft Excel.
.SH OPTIONS
.INDENT 0.0
.TP
.B \fB\-h\fP, \fB\-\-heading\fP \fIrow\fP
Row number containing the headings (default: none). Note: the first row is
numbered 0, not 1!
.TP
.B \fB\-f\fP, \fB\-\-file\-type\fP \fIcsv|excel\fP
Override autodetection of input file type.
.TP
.B \fB\-d\fP, \fB\-\-delimiter\fP \fIcharacter\fP
Delimiter (only applicable to CSV files) [default: \(aq,\(aq].
.TP
.B \fB\-q\fP, \fB\-\-quotechar\fP
Quote character (only applicable to CSV files) [default: \(aq"\(aq].
.TP
.B \fB\-e\fP, \fB\-\-encoding\fP \fIencoding\fP
Encoding [default: UTF\-8].
.TP
.B \fB\-\-version\fP
Show the version and exit.
.TP
.B \fB\-\-help\fP
Show built\-in help and exit.
.UNINDENT
.SH EXAMPLES
.sp
So, for example:
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
$ x_x dead_guys.xlsx
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+
| A             | B            |
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+
| Person        | Age at Death |
| Harrold Holt  | 59.0         |
| Harry Houdini | 52.0         |
| Howard Hughes | 70.0         |
.ft P
.fi
.UNINDENT
.UNINDENT
.sp
Or to specify a specific row as the header which will be visible on each page:
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
$ x_x \-h 0 dead_guys.xlsx
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+
| Person        | Age at Death |
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+
| Harrold Holt  | 59.0         |
| Harry Houdini | 52.0         |
| Howard Hughes | 70.0         |
.ft P
.fi
.UNINDENT
.UNINDENT
.sp
Weird CSVs? No problem!
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
$ cat dead_guys.csv
person;age_at_death
Harrold Holt;59
Harry Houdini;52
Howard Hughes;70
|Not some guy, but just a string with ; in it|;0
.ft P
.fi
.UNINDENT
.UNINDENT
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
$ x_x \-h 0 \-\-delimiter=\(aq;\(aq \-\-quotechar=\(aq|\(aq dead_guys.csv
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+
| person                                       | age_at_death |
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+
| Harrold Holt                                 | 59           |
| Harry Houdini                                | 52           |
| Howard Hughes                                | 70           |
| Not some guy, but just a string with ; in it | 0            |
.ft P
.fi
.UNINDENT
.UNINDENT
.sp
Does your CSV file not end in "csv"? Again, no problem:
.INDENT 0.0
.INDENT 3.5
.sp
.nf
.ft C
$ mv dead_guys.csv dead_guys.some_other_extension
$ x_x \-h 0 \-\-file\-type=csv \-\-delimiter=\(aq;\(aq \-\-quotechar=\(aq|\(aq dead_guys.some_other_extension
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+
| person                                       | age_at_death |
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-\-\-\-\-\-\-+
| Harrold Holt                                 | 59           |
| Harry Houdini                                | 52           |
| Howard Hughes                                | 70           |
| Not some guy, but just a string with ; in it | 0            |
.ft P
.fi
.UNINDENT
.UNINDENT
.SH COPYRIGHT
.sp
See the file /usr/doc/x_x\-20150330_d236f8f/LICENSE for license information.
.SH AUTHORS
.sp
x_x was written by krockode.
.sp
This man page written for the SlackBuilds.org project
by B. Watson, and is licensed under the WTFPL.
.SH SEE ALSO
.sp
The x_x homepage: \fI\%https://github.com/krockode/x_x\fP
.\" Generated by docutils manpage writer.
.