comparison doc/src/irccdctl.md @ 607:bb9771fb5f44

Docs: rework documentation - Change directories, - Remove handwritten manual pages.
author David Demelier <markand@malikania.fr>
date Fri, 08 Dec 2017 20:11:22 +0100
parents
children ebe561276c33
comparison
equal deleted inserted replaced
606:4f5f306d13ac 607:bb9771fb5f44
1 % irccdctl
2 % David Demelier
3 % 2017-12-08
4
5 The `irccdctl` utility let you control a running `irccd` instance.
6
7 # Synopsis
8
9 usage: irccdctl plugin-config plugin [variable] [value]
10 irccdctl plugin-info plugin
11 irccdctl plugin-list
12 irccdctl plugin-load logger
13 irccdctl plugin-reload plugin
14 irccdctl plugin-unload plugin
15 irccdctl rule-list
16 irccdctl server-connect [options] id host [port]
17 irccdctl server-disconnect [server]
18 irccdctl server-info server
19 irccdctl server-invite server nickname channel
20 irccdctl server-join server channel [password]
21 irccdctl server-kick server target channel [reason]
22 irccdctl server-list
23 irccdctl server-me server target message
24 irccdctl server-message server target message
25 irccdctl server-mode server mode
26 irccdctl server-nick server nickname
27 irccdctl server-notice server target message
28 irccdctl server-part server channel [reason]
29 irccdctl server-reconnect [server]
30 irccdctl server-topic server channel topic
31 irccdctl watch [-f|--format json|native]
32
33 # Syntax
34
35 The general syntax for running an irccdctl command is:
36
37 irccdctl commandname arg1 arg2 arg3 ... argn
38
39 # Shell escaping issue
40
41 Some shells may discard arguments if they begins with a hash. For instance,
42 `bash` will not understand the following command:
43
44 $ irccdctl server-join localhost #staff
45
46 Instead, enclose the arguments with quotes
47
48 $ irccdctl server-join localhost "#staff"
49
50 # Commands
51
52 ## plugin-config
53
54 Get or set a plugin configuration variable.
55
56 If both variable and value are provided, sets the plugin configuration to the
57 respective variable name and value.
58
59 If only variable is specified, shows its current value. Otherwise, list all
60 variables and their values.
61
62 ### Usage
63
64 $ irccdctl plugin-config plugin [variable] [value]
65
66 ### Example
67
68 $ irccdctl plugin-config ask
69
70 ## plugin-info
71
72 Get plugin information.
73
74 ### Usage
75
76 $ irccdctl plugin-info name
77
78 ### Example
79
80 $ irccdctl plugin-info ask
81
82 ## plugin-list
83
84 Get the list of all loaded plugins.
85
86 ### Usage
87
88 $ irccdctl plugin-list
89
90 ## plugin-load
91
92 Load a plugin into the irccd instance.
93
94 ### Usage
95
96 $ irccdctl plugin-load plugin
97
98 ### Example
99
100 $ irccdctl load ask
101
102 ## plugin-reload
103
104 Reload a plugin by calling the appropriate onReload event, the plugin is not
105 unloaded and must be already loaded.
106
107 ### Usage
108
109 $ irccdctl plugin-reload name
110
111 ### Example
112
113 $ irccdctl plugin-reload logger
114
115 ## plugin-unload
116
117 Unload a loaded plugin from the irccd instance.
118
119 ### Usage
120
121 $ irccdctl plugin-unload name
122
123 ### Example
124
125 $ irccdctl plugin-unload logger
126
127 ## rule-add
128
129 Add a new rule to irccd.
130
131 If no index is specified, the rule is added to the end.
132
133 ### Usage
134
135 $ irccdctl rule-add [options] accept|drop
136
137 Available options:
138
139 - **-c, --add-channel**: match a channel
140 - **-e, --add-event**: match an event
141 - **-i, --index**: rule position
142 - **-p, --add-plugin**: match a plugin
143 - **-s, --add-server**: match a server
144
145 ### Example
146
147 $ irccdctl rule-add -p hangman drop
148 $ irccdctl rule-add -s localhost -c #games -p hangman accept
149
150 ## rule-edit
151
152 Edit an existing rule in irccd.
153
154 All options can be specified multiple times.
155
156 Available options:
157
158 - **a, --action**: set action
159 - **c, --add-channel**: match a channel
160 - **C, --remove-channel**: remove a channel
161 - **e, --add-event**: match an event
162 - **E, --remove-event**: remove an event
163 - **p, --add-plugin**: match a plugin
164 - **P, --add-plugin**: remove a plugin
165 - **s, --add-server**: match a server
166 - **S, --remove-server**: remove a server
167
168 ### Usage
169
170 usage: irccdctl rule-edit [options] index
171
172 ### Example
173
174 $ irccdctl rule-edit -p hangman 0
175 $ irccdctl rule-edit -S localhost -c #games -p hangman 1
176
177 ## rule-info
178
179 Show a rule.
180
181 ### Usage
182
183 $ irccdctl rule-info index
184
185 ### Example
186
187 $ irccdctl rule-info 0
188 $ irccdctl rule-info 1
189
190 ## rule-list
191
192 List all rules.
193
194 ### Usage
195
196 $ irccdctl rule-list
197
198 ## rule-move
199
200 Move a rule from the given source at the specified destination index.
201
202 The rule will replace the existing one at the given destination moving
203 down every other rules. If destination is greater or equal the number of rules,
204 the rule is moved to the end.
205
206 ### Usage
207
208 irccdctl rule-move source destination
209
210 ### Example
211
212 irccdctl rule-move 0 5
213 irccdctl rule-move 4 3
214
215 ## rule-remove
216
217 Remove an existing rule.
218
219 ### Usage
220
221 $ irccdctl rule-remove index
222
223 ### Example
224
225 $ irccdctl rule-remove 0
226 $ irccdctl rule-remove 1
227
228 ## server-connect
229
230 Connect to a new IRC server.
231
232 ### Usage
233
234 $ irccdctl server-connect [options] name host port
235
236 Available options:
237
238 - **-c, --command**: specify the command char
239 - **-n, --nickname**: specify a nickname
240 - **-r, --realname**: specify a real name
241 - **-S, --ssl-verify**: verify SSL
242 - **-s, --ssl**: connect using SSL
243 - **-u, --username**: specify a user name
244
245 ### Example
246
247 $ irccdctl server-connect -n jean example irc.example.org
248 $ irccdctl server-connect --ssl example irc.example.org 6697
249
250 ## server-disconnect
251
252 Disconnect from a server.
253
254 If server is not specified, irccd disconnects all servers.
255
256 ### Usage
257
258 $ irccdctl server-disconnect [server]
259
260 ### Example
261
262 $ irccdctl server-disconnect
263 $ irccdctl server-disconnect localhost
264
265 ## server-invite
266
267 Invite the specified target on the channel.
268
269 ### Usage
270
271 $ irccdctl server-invite server nickname channel
272
273 ### Example
274
275 $ irccdctl server-invite freenode xorg62 #staff
276
277 ## server-join
278
279 Join the specified channel, the password is optional.
280
281 ### Usage
282
283 $ irccdctl server-join server channel [password]
284
285 ### Example
286
287 $ irccdctl server-join freenode #test
288 $ irccdctl server-join freenode #private-club secret
289
290 ## server-kick
291
292 Kick the specified target from the channel, the reason is optional.
293
294 ### Usage
295
296 $ irccdctl server-kick server target channel [reason]
297
298 ### Example
299
300 $ irccdctl kick freenode jean #staff "Stop flooding"
301
302 ## server-list
303
304 Get the list of all connected servers.
305
306 ### Usage
307
308 $ irccdctl server-list
309
310 ## server-me
311
312 Send an action emote.
313
314 ### Usage
315
316 $ irccdctl server-me server target message
317
318 ### Example
319
320 $ irccdctl server-me freenode #staff "going back soon"
321
322 ## server-message
323
324 Send a message to the specified target or channel.
325
326 ### Usage
327
328 $ irccdctl server-message server target message
329
330 ### Example
331
332 $ irccdctl server-message freenode #staff "Hello from irccd"
333
334 ## server-mode
335
336 Set channel or irccd's user mode.
337
338 ### Usage
339
340 $ server-mode server channel mode [limit] [user] [mask]
341
342 ### Example
343
344 $ irccdctl server-mode local irccd +i # set user mode to +i
345 $ irccdctl server-mode local #staff +o jean # enable operator for jean
346
347 ## server-nick
348
349 Change irccd's nickname.
350
351 ### Usage
352
353 $ irccdctl server-nick server nickname
354
355 ### Example
356
357 $ irccdctl server-nick freenode david
358
359 ## server-notice
360
361 Send a private notice to the specified target.
362
363 ### Usage
364
365 $ irccdctl server-notice server target message
366
367 ### Example
368
369 $ irccdctl server-notice freenode jean "I know you are here."
370
371 ## server-part
372
373 Leave the specified channel, the reason is optional.
374
375 **Warning**: not all IRC servers support giving a reason to leave a channel, do
376 not specify it if this is a concern.
377
378 ### Usage
379
380 $ irccdctl server-part server channel [reason]
381
382 ### Example
383
384 $ irccdctl server-part freenode #staff
385 $ irccdctl server-part freenode #botwar "too noisy"
386
387 ## server-reconnect
388
389 Force reconnection of one or all servers.
390
391 If server is not specified, all servers will try to reconnect.
392
393 ### Usage
394
395 $ irccdctl server-reconnect [server]
396
397 ### Example
398
399 $ irccdctl server-reconnect
400 $ irccdctl server-reconnect wanadoo
401
402 ## server-topic
403
404 Change the topic of the specified channel.
405
406 ### Usage
407
408 $ irccdctl server-topic server channel topic
409
410 ### Example
411
412 $ irccdctl server-topic freenode #wmfs "This is the best channel"
413
414 ## watch
415
416 Start watching irccd events.
417
418 You can use different output formats, native is human readable format, json is
419 pretty formatted json.
420
421 ### Usage
422
423 $ irccdctl watch [-f|--format native|json]
424
425 ### Example
426
427 $ irccdctl watch
428 $ irccdctl watch -f json