aboutsummaryrefslogtreecommitdiff
path: root/jsmond.1
blob: df25a5e830487a0f77c10bbe0f9e6a5503236c39 (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
.\" Man page generated from reStructuredText.
.
.TH JSMOND 1 "2020-05-15" "0.1.0" "Urchlay"
.SH NAME
jsmond \- disable screensaver on joystick activity
.
.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 jsmond(1) man page. Convert with:
.
.\" rst2man.py jsmond.rst > jsmond.1
.
.SH SYNOPSIS
.sp
jsmond [\fB\-c command\fP] [\fB\-i seconds\fP] [\fB\-d\fP] [\fB\-x\fP] [\fBjoydev [joydev ...]\fP]
.SH DESCRIPTION
.sp
jsmond lets you play games with your joysticks/gamepads without
xscreensaver activating due to lack of keyboard/mouse input.
.sp
Up to 16 joystick devices can be monitored. By default, jsmond searches
for these and monitors all the joysticks it finds. You can override
this on the command line by providing one or more \fBjoydev\fP arguments,
in which case no autodetection will be done.
.sp
Every \fIinterval\fP seconds (60, or whatever \fB\-i\fP is set to), jsmond
checks to see if there\(aqs been any activity on any of the devices it\(aqs
monitoring. If so, it runs the \fBxscreensaver\-command \-deactivate\fP,
or whatever the \fB\-c\fP argument is set to.
.sp
The command will be run no more than once every \fIinterval\fP seconds.
.sp
jsmond should be started from your \fB\&.xinitrc\fP or whatever X startup
script your windowmanager or desktop environment uses. By default, it
will exit when the X server does.
.sp
If you can think of a use for jsmond outside of X, give it the \-x argument
so it won\(aqt complain about not being able to connect to the X server. This
will also prevent it from exiting when the X server does. When using
\-x, be careful not to spawn multiple instances of jsmond (although they
won\(aqt hurt anything, just waste resources).
.SH OPTIONS
.INDENT 0.0
.TP
.B \-\-help
Print usage summary
.TP
.BI \-c \ <command>
Run <command> when activity was detected during the
last \fIinterval\fP\&.
.TP
.BI \-i \ <seconds>
Interval to check for activity. Should be set lower
than your xscreensaver timeout. Setting this too low
will waste resources. Default: 60.
.TP
.B \-d
Debug mode: print verbose messages and don\(aqt fork()
into the background.
.TP
.B \-x
Don\(aqt try to connect to X server.
.UNINDENT
.SH EXIT STATUS
.sp
Without the \-d option, the exit status is 0 (success) if jsmond
successfully opened at least one joystick and forked into the background.
.sp
A non\-zero exit status means no joysticks were found, or else fork()
failed. No daemon will be running in this case.
.sp
With the \-d option, jsmond never exits until it\(aqs killed.
.SH BUGS
.sp
jsmond only searches for joysticks when it\(aqs started. If USB joysticks are
plugged in while jsmond is running, it won\(aqt detect them. This includes
unplugging the device and plugging it back in: jsmond won\(aqt complain,
but it\(aqll never report activity on that device again.
.sp
jsmond isn\(aqt portable. It only works on Linux, at least for now.
.\" EXAMPLES
.
.\" ========
.
.SH LICENSE
.sp
jsmond is released under the WTFPL: Do WTF you want with this.
.SH AUTHORS
.sp
jsmond was written by B. Watson <\fI\%yalhcru@gmail.com\fP>.
.SH SEE ALSO
.sp
sdl\-jstest(1), sdl2\-jstest(2)
.\" Generated by docutils manpage writer.
.