summary refs log tree commit diff
path: root/bin/man1/shotty.1
blob: d5eaa780f5bb7965f2cf3fad036cda3d83624701 (plain) (blame)
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
.Dd November 25, 2019
.Dt SHOTTY 1
.Os
.
.Sh NAME
.Nm shotty
.Nd terminal capture
.
.Sh SYNOPSIS
.Nm
.Op Fl Bdns
.Op Fl b Ar bg
.Op Fl f Ar fg
.Op Fl h Ar rows
.Op Fl w Ar cols
.Op Ar file
.
.Sh DESCRIPTION
.Nm
interprets terminal output from
.Ar file
or standard input
and produces HTML
.Sy <pre>
on standard output.
.
.Pp
Terminal output
can be captured with
.Xr ptee 1 .
.Nm
targets compatibility with
.Ev TERM Ns = Ns Cm xterm
and
.Ev TERM Ns = Ns Cm xterm-256color
as used by
.Xr ncurses 3 .
A snapshot of the terminal
is output each time
a media copy sequence occurs,
or once at the end of the capture.
.
.Pp
HTML output uses the classes
.Sy bg Ns Va n
and
.Sy fg Ns Va n ,
and inline styles for
bold, italic and underline.
CSS for colors can be generated with
.Xr scheme 1 .
.
.Pp
The arguments are as follows:
.Bl -tag -width "-w cols"
.It Fl B
Replace bold with bright colors.
.
.It Fl b Ar bg
Set the default background color.
The default value is 0 (black).
.
.It Fl d
Output the terminal state
following each control sequence.
.
.It Fl f Ar fg
Set the default foreground color.
The default value is 7 (white).
.
.It Fl h Ar rows
Set the terminal height.
The default value is 24.
.
.It Fl n
Do not show the cursor.
.
.It Fl s
Set the terminal size
from the current terminal size.
.
.It Fl w Ar cols
Set the terminal width.
The default value is 80.
.El
.
.Sh EXAMPLES
.Dl ptee htop | shotty -s > htop.html
.
.Sh SEE ALSO
.Xr ptee 1 ,
.Xr scheme 1
header'>2022-06-10Handle subshells (and functions) inside substitutionsJune McEnroe 2022-06-10Switch to jorts Install scriptJune McEnroe 2022-06-08Indicate if still reading or no resultsJune McEnroe 2022-06-08Add Maiden, Mother, CroneJune McEnroe Mixed bag like most collections of short stories. Some of them are pretty good. The author of the worst written story also has the worst written bio. 2022-06-05FIRST SHOW IN 2.5 YEARS BABEY!!!June McEnroe 2022-06-03Set line number on File linesJune McEnroe 2022-06-03Stop polling stdin after EOFJune McEnroe 2022-06-02Set TABSIZE=4June McEnroe Absolutely indiscriminately. 2022-06-02Do basic match highlightingJune McEnroe 2022-06-02Clean up parsing a littleJune McEnroe 2022-06-02Don't duplicate path stringJune McEnroe 2022-06-02Use stderr instead of /dev/tty, realloc buffer if lines too longJune McEnroe For some reason I haven't been able to figure out, trying to poll /dev/tty returns POLLNVAL (and this was using 100% CPU looping), but using stderr instead works fine. 2022-06-02Add initial working version of qfJune McEnroe 2022-05-29Set prompt for okshJune McEnroe