chiark / gitweb /
docs update
[disorder] / doc / disorder_config.5.in
CommitLineData
e99d42b1 1
460b9539 2.\"
405fea4e 3.\" Copyright (C) 2004, 2005, 2006, 2007 Richard Kettlewell
460b9539 4.\"
5.\" This program is free software; you can redistribute it and/or modify
6.\" it under the terms of the GNU General Public License as published by
7.\" the Free Software Foundation; either version 2 of the License, or
8.\" (at your option) any later version.
9.\"
10.\" This program is distributed in the hope that it will be useful, but
11.\" WITHOUT ANY WARRANTY; without even the implied warranty of
12.\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13.\" General Public License for more details.
14.\"
15.\" You should have received a copy of the GNU General Public License
16.\" along with this program; if not, write to the Free Software
17.\" Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
18.\" USA
19.\"
20.TH disorder_config 5
21.SH NAME
22pkgconfdir/config - DisOrder jukebox configuration
23.SH DESCRIPTION
24The purpose of DisOrder is to organize and play digital audio files, under the
25control of multiple users. \fIpkgconfdir/config\fR is the primary
26configuration file but this man page currently documents all of its various
27configuration files.
28.SS Tracks
29DisOrder can be configured with multiple collections of tracks, indexing them
30by their filename, and picking players on the basis of filename patterns (for
31instance, "*.mp3").
32.PP
33Although the model is of filenames, it is not inherent that there are
34corresponding real files - merely that they can be interpreted by the chosen
35player. See \fBdisorder\fR(3) for more details about this.
36.PP
37Each track can have a set of preferences associated with it. These are simple
38key-value pairs; they can be used for anything you like, but a number of keys
39have specific meanings. See \fBdisorder\fR(1) for more details about these.
40.SS "Track Names"
41Track names are derived from filenames under the control of regular
42expressions, rather than attempting to interpret format-specific embedded name
43information. They can be overridden by setting preferences.
44.PP
45Names for display are distinguished from names for sorting, so with the right
46underlying filenames an album can be displayed in its original order even if
47the displayed track titles are not lexically sorted.
48.SS "Server State"
49A collection of global preferences define various bits of server state: whether
50random play is enabled, what tags to check for when picking at random, etc.
51.SS "Users And Access Control"
52DisOrder distinguishes between multiple users. This is for access control and
53reporting, not to provide different views of the world: i.e. preferences and so
54on are global.
55.PP
56It's possible to restrict a small number of operations to a specific subset of
57users. However, it is assumed that every user is supposed to be able to do
58most operations - since the users are all sharing the same audio environment
59they are expected to cooperate with each other.
60.PP
61Access control is entirely used-based. If you configure DisOrder to listen for
62TCP/IP connections then it will accept a connection from anywhere provided the
63right password is available. Passwords are never transmitted over TCP/IP
64connections in clear, but everything else is. The expected model is that
65host-based access control is imposed at the network layer.
66.SS "Web Interface"
67The web interface is controlled by a collection of template files, one for each
68kind of page, and a collection of option files. These are split up and
69separate from the main configuration file to make it more convenient to
70override specific bits.
71.PP
72The web interface connects to the DisOrder server like any other user, though
73it is given a special privilege to "become" any other user. (Thus, any process
74with the same UID as the web interface is very powerful as far as DisOrder
25ca855b 75goes. This model will be changed in a future version.)
460b9539 76.PP
77Access control to the web interface is (currently) separate from DisOrder's own
78access control (HTTP authentication is required) but uses the same user
79namespace.
180dcdb0
RK
80.SS "Searching And Tags"
81Search strings contain a list of search terms separated by spaces. A search
82term can either be a single word or a tag, prefixed with "tag:".
83.PP
84Search words are compared without regard to letter case or accents; thus, all
85of the following will be considered to be equal to one another:
86.PP
87.nf
88 LATIN CAPITAL LETTER E
89 LATIN SMALL LETTER E
90 LATIN CAPITAL LETTER E WITH GRAVE
91 LATIN SMALL LETTER E WITH GRAVE
92 LATIN CAPITAL LETTER E plus COMBINING GRAVE ACCENT
93 LATIN SMALL LETTER E plus COMBINING GRAVE ACCENT
94.fi
95.PP
96The same rules apply to tags but in addition leading and trailing whitespace is
97disregarded and all whitespace sequences are treated as equal when they appear
98as internal whitespace.
99.PP
100Where several tags are listed, for instance the tags preference for a track,
101the tags are separated by commas. Therefore tags may not contain commas.
460b9539 102.SH "CONFIGURATION FILE"
103.SS "General Syntax"
104Lines are split into fields separated by whitespace (space, tab, line
105feed, carriage return, form feed). Comments are started by the number
106sign ("#").
107.PP
108Fields may be unquoted (in which case they may not contain spaces and
109may not start with a quotation mark or apostrophe) or quoted by either
110quotation marks or apostrophes. Inside quoted fields every character
111stands for itself, except that a backslash can only appear as part of
112one of the following escape sequences:
113.TP
114.B \e\e
115Backslash
116.TP
117.B \e"
118Quotation mark
119.\" "
120.TP
121.B \e'
122Apostrophe
123.TP
124.B \en
125Line feed
126.PP
127No other escape sequences are allowed.
128.PP
129Within any line the first field is a configuration command and any
130further fields are parameters. Lines with no fields are ignored.
131.PP
132After editing the config file use \fBdisorder reconfigure\fR to make
133it re-read it. If there is anything wrong with it the daemon will
134record a log message and ignore the new config file. (You should fix
135it before next terminating and restarting the daemon, as it cannot
136start up without a valid config file.)
137.SS "Global Configuration"
138.TP
139.B home \fIDIRECTORY\fR
140The home directory for state files. Defaults to
141.IR pkgstatedir .
659d87e8 142The server will create this directory on startup if it does not exist.
460b9539 143.TP
0c6bcae0 144.B plugins \fIPATH\fR
460b9539 145Adds a directory to the plugin path. (This is also used by the web
146interface.)
147.IP
148Plugins are opened the first time they are required and never after,
149so after changing a plugin you must restart the server before it is
150guaranteed to take effect.
40c30921
RK
151.IP
152If
153.B plugins
154is used without arguments the plugin path is cleared.
460b9539 155.SS "Server Configuration"
156.TP
157.B alias \fIPATTERN\fR
158Defines the pattern use construct virtual filenames from \fBtrackname_\fR
159preferences.
160.IP
161Most characters stand for themselves, the exception being \fB{\fR which is used
162to insert a track name part in the form \fB{\fIname\fB}\fR or
163\fB{/\fIname\fB}\fR.
164.IP
165The difference is that the first form just inserts the name part while the
166second prefixes it with a \fB/\fR if it is nonempty.
167.IP
168The pattern should not attempt to include the collection root, which is
169automatically included, but should include the proper extension.
170.IP
171The default is \fB{/artist}{/album}{/title}{ext}\fR.
172.TP
25ca855b 173.B authorization_algorithm \fIALGORITHM\fR
637fdea3
RK
174Defines the algorithm used to authenticate clients. The valid options
175are sha1 (the default), sha256, sha384 and sha512. See
176.BR disorder_protocol (5)
177for more details.
178.TP
30ad4dab 179.B broadcast \fIADDRESS\fR \fIPORT\fR
180Transmit sound data to \fIADDRESS\fR using UDP port \fIPORT\fR. This implies
29573477 181\fBspeaker_backend network\fR.
61941295
RK
182.IP
183See also \fBmulticast_loop\fR and \fBmulticast_ttl\fR.
30ad4dab 184.TP
185.B broadcast_from \fIADDRESS\fR \fIPORT\fR
186Sets the (local) source address used by \fBbroadcast\fR.
187.TP
460b9539 188.B channel \fICHANNEL\fR
189The mixer channel that the volume control should use. Valid names depend on
190your operating system and hardware, but some standard ones that might be useful
191are:
192.RS
193.TP 8
194.B pcm
25ca855b
RK
195Output level for the audio device. This is probably what you want and is the
196default.
460b9539 197.TP
198.B speaker
199Output level for the PC speaker, if that is connected to the sound card.
200.TP
201.B pcm2
202Output level for alternative codec device.
203.TP
204.B vol
205Master output level. The OSS documentation recommends against using this, as
206it affects all output devices.
207.RE
208.IP
25ca855b
RK
209You can also specify channels by number, if you know the right value. NB that
210volume setting only works on OSS systems (including ALSA, via emulation).
460b9539 211.TP
212.B collection \fIMODULE\fR \fIENCODING\fR \fIROOT\fR
213Define a collection of tracks.
214.IP
215\fIMODULE\fR defines which plugin module should be used for this
216collection. Use the supplied \fBfs\fR module for tracks that exists
217as ordinary files in the filesystem.
218.IP
219\fIENCODING\fR defines the encoding of filenames in this collection.
220For \fBfs\fR this would be the encoding you use for filenames.
221Examples might be \fBiso-8859-1\fR or \fButf-8\fR.
222.IP
223\fIROOT\fR is the root in the filesystem of the filenames and is
224passed to the plugin module.
225.TP
226.B device \fINAME\fR
227ALSA device to play raw-format audio. Default is \fBdefault\fR, i.e. to use
228the whatever the ALSA configured default is.
229.TP
230.B gap \fISECONDS\fR
231Specifies the number of seconds to leave between tracks. The default
232is 2.
233.TP
234.B history \fIINTEGER\fR
235Specifies the number of recently played tracks to remember (including
236failed tracks and scratches).
237.TP
238.B listen \fR[\fIHOST\fR] \fISERVICE\fR
239Listen for connections on the address specified by \fIHOST\fR and port
240specified by \fISERVICE\fR. If \fIHOST\fR is omitted then listens on all
241local addresses.
242.IP
243Normally the server only listens on a UNIX domain socket.
244.TP
245.B lock yes\fR|\fBno
246Determines whether the server locks against concurrent operation. Default is
25ca855b
RK
247\fByes\fR. There is no good reason to set this to \fBno\fR and the option will
248probably be removed in a future version.
460b9539 249.TP
250.B mixer \fIPATH\fR
251The path to the mixer device, if you want access to the volume control,
25ca855b 252e.g. \fB/dev/mixer\fR (the default).
460b9539 253.TP
61941295
RK
254.B multicast_loop yes\fR|\fBno
255Determines whether multicast packets are loop backed to the sending host. The
256default is \fByes\fR. This only applies if
257\fBspeaker_backend\fR is set to \fBnetwork\fR and \fBbroadcast\fR is actually a
258multicast address.
259.TP
23205f9c 260.B multicast_ttl \fIHOPS\fR
61941295 261Set the maximum number of hops to send multicast packets. This only applies if
23205f9c 262\fBspeaker_backend\fR is set to \fBnetwork\fR and \fBbroadcast\fR is actually a
25ca855b 263multicast address. The default is 1.
23205f9c 264.TP
460b9539 265.B namepart \fIPART\fR \fIREGEXP\fR \fISUBST\fR [\fICONTEXT\fR [\fIREFLAGS\fR]]
266Determines how to extract trackname part \fIPART\fR from a
267track name (with the collection root part removed).
268Used in \fB@recent@\fR, \fB@playing@\fR and \fB@search@\fR.
269.IP
270Track names can be different in different contexts. For instance the sort
271string might include an initial track number, but this would be stripped for
272the display string. \fICONTEXT\fR should be a glob pattern matching the
273contexts in which this directive will be used.
274.IP
275Valid contexts are \fBsort\fR and \fBdisplay\fR.
276.IP
277All the \fBnamepart\fR directives are considered in order. The
278first directive for the right part, that matches the desired context,
279and with a \fIREGEXP\fR that
280matches the track is used, and the value chosen is constructed from
281\fISUBST\fR according to the substitution rules below.
282.IP
283Note that searches use the raw track name and \fBtrackname_\fR preferences but
284not (currently) the results of \fBnamepart\fR, so generating words via this option
285that aren't in the original track name will lead to confusing results.
286.IP
287If you supply no \fBnamepart\fR directives at all then a default set will be
288supplied automatically. But if you supply even one then you must supply all of
25ca855b
RK
289them. The defaults are equivalent to:
290.PP
291.nf
292namepart title "/([0-9]+ *[-:] *)?([^/]+)\\.[a-zA-Z0-9]+$" $2 display
293namepart title "/([^/]+)\\.[a-zA-Z0-9]+$" $1 sort
294namepart album "/([^/]+)/[^/]+$" $1 *
295namepart artist "/([^/]+)/[^/]+/[^/]+$" $1 *
296namepart ext "(\\.[a-zA-Z0-9]+)$" $1 *
297.fi
460b9539 298.TP
299.B nice_rescan \fIPRIORITY\fR
300Set the recan subprocess priority. The default is 10.
301.IP
302(Note that higher values mean the process gets less CPU time; UNIX priority
04e42396 303values are backwards.)
460b9539 304.TP
305.B nice_server \fIPRIORITY\fR
306Set the server priority. This is applied to the server at startup time (and
307not when you reload configuration). The server does not use much CPU itself
308but this value is inherited by programs it executes. If you have limited CPU
309then it might help to set this to a small negative value. The default is 0.
310.TP
311.B nice_speaker \fIPRIORITY\fR
312Set the speaker process priority. This is applied to the speaker process at
313startup time (and not when you reload the configuration). The speaker process
314is not massively CPU intensive by today's standards but depends on reasonably
315timely scheduling. If you have limited CPU then it might help to set this to a
316small negative value. The default is 0.
317.TP
2a10b70b
RK
318.B noticed_history
319The maximum days that a track can survive in the database of newly added
320tracks. The default is 31.
321.TP
460b9539 322.B player \fIPATTERN\fR \fIMODULE\fR [\fIOPTIONS.. [\fB--\fR]] \fIARGS\fR...
323Specifies the player for files matching the glob \fIPATTERN\fR. \fIMODULE\fR
324specifies which plugin module to use.
325.IP
326The following options are supported:
327.RS
328.TP
329.B --wait-for-device\fR[\fB=\fIDEVICE\fR]
330Waits (for up to a couple of seconds) for the default, or specified, libao
331device to become openable.
332.TP
333.B --
334Defines the end of the list of options. Needed if the first argument to the
335plugin starts with a "-".
336.RE
337.IP
338The following are the standard modules:
339.RS
340.TP
341.B exec \fICOMMAND\fR \fIARGS\fR...
342The command is executed via \fBexecvp\fR(3), not via the shell.
343The \fBPATH\fR environment variable is searched for the executable if it is not
344an absolute path.
345The command is expected to know how to open its own sound device.
346.TP
347.B execraw \fICOMMAND\fR \fIARGS\fR...
348Identical to the \fBexec\fR except that the player is expected to use the
ce6c36be 349DisOrder raw player protocol.
350.BR disorder-decode (8)
351can decode several common audio file formats to this format. If your favourite
352format is not supported, but you have a player which uses libao, there is also
353a libao driver which supports this format; see below for more information about
354this.
460b9539 355.TP
356.B shell \fR[\fISHELL\fR] \fICOMMAND\fR
357The command is executed using the shell. If \fISHELL\fR is specified then that
358is used, otherwise \fBsh\fR will be used. In either case the \fBPATH\fR
359environment variable is searched for the shell executable if it is not an
360absolute path. The track name is stored in the environment variable
361\fBTRACK\fR.
362.IP
363Be careful of the interaction between the configuration file quoting rules and
364the shell quoting rules.
365.RE
366.IP
367If multiple player commands match a track then the first match is used.
62dc3748
RK
368.IP
369For the server to be able to calculate track lengths, there should be a
370.B tracklength
371command corresponding to each
372.B player
373command.
40c30921
RK
374.IP
375If
376.B player
377is used without arguments, the list of players is cleared.
460b9539 378.TP
379.B prefsync \fISECONDS\fR
380The interval at which the preferences log file will be synchronised. Defaults
381to 3600, i.e. one hour.
382.TP
459d4402 383.B queue_pad \fICOUNT\fR
384The target size of the queue. If random play is enabled then randomly picked
25ca855b 385tracks will be added until the queue is at least this big. The default is 10.
459d4402 386.TP
62dc3748
RK
387.B restrict \fR[\fBscratch\fR] [\fBremove\fR] [\fBmove\fR]
388Determine which operations are restricted to the submitter of a
389track. By default, no operations are restricted, i.e. anyone can
390scratch or remove anything.
391.IP
392If \fBrestrict scratch\fR or \fBrestrict remove\fR are set then only the user
393that submitted a track can scratch or remove it, respectively.
394.IP
395If \fBrestrict move\fR is set then only trusted users can move tracks around in
396the queue.
397.IP
398If \fBrestrict\fR is used more than once then only the final use has any
399effect.
400.TP
405fea4e 401.B sample_format \fIBITS\fB/\fIRATE\fB/\fICHANNELS
402Describes the sample format expected by the \fBspeaker_command\fR (below). The
403components of the format specification are as follows:
404.RS
405.TP 10
406.I BITS
407The number of bits per sample. Optionally, may be suffixed by \fBb\fR or
408\fBl\fR for big-endian and little-endian words. If neither is used the native
409byte order is assumed.
410.TP
411.I RATE
412The number of samples per second.
413.TP
414.I CHANNELS
415The number of channels.
416.PP
417The default is
418.BR 16/44100/2 .
937be4c0
RK
419.PP
420With the
421.B network
422backend the sample format is forced to
e99d42b1 423.B 16b/44100/2
937be4c0
RK
424and with the
425.B coreaudio
426backend it is forced to
427.BR 16/44100/2 ,
428in both cases regardless of what is specified in the configuration file.
405fea4e 429.RE
430.TP
460b9539 431.B signal \fINAME\fR
432Defines the signal to be sent to track player process groups when tracks are
433scratched. The default is \fBSIGKILL\fR.
434.IP
435Signals are specified by their full C name, i.e. \fBSIGINT\fR and not \fBINT\fR
436or \fBInterrupted\fR or whatever.
437.TP
29573477 438.B speaker_backend \fINAME\fR
439Selects the backend use by the speaker process. The following options are
440available:
441.RS
442.TP
443.B alsa
444Use the ALSA API. This is only available on Linux systems, on which it is the
445default.
446.TP
937be4c0
RK
447.B coreaudio
448Use Apple Core Audio. This only available on OS X systems, on which it is the
449default.
450.TP
e99d42b1 451.B oss
25ca855b 452Use the OSS (/dev/dsp) API. Not available on all platforms.
e99d42b1 453.TP
29573477 454.B command
455Execute a command. This is the default if
456.B speaker_command
937be4c0 457is specified, or if no native is available.
29573477 458.TP
459.B network
460Transmit audio over the network. This is the default if
803f6e52 461\fBbroadcast\fR is specified. You can use
462.BR disorder-playrtp (1)
463to receive and play the resulting stream on Linux and OS X.
29573477 464.RE
465.TP
5330d674 466.B sox_generation \fB0\fR|\fB1
467Determines whether calls to \fBsox\fR(1) should use \fB-b\fR, \fB-x\fR, etc (if
25ca855b
RK
468the generation is 0) or \fB-\fIbits\fR, \fB-L\fR etc (if it is 1). See the
469documentation for your installed copy of \fBsox\fR to determine which you need.
470The default is 0.
5330d674 471.TP
405fea4e 472.B speaker_command \fICOMMAND
473Causes the speaker subprocess to pipe audio data into shell command
474\fICOMMAND\fR, rather than writing to a local sound card. The sample format is
475determine by
476.B sample_format
477above.
77cfc7a2 478.IP
479Note that if the sample format is wrong then
480.BR sox (1)
481is invoked to translate it. If
482.B sox
483is not installed then this will not work.
405fea4e 484.TP
460b9539 485.B scratch \fIPATH\fR
486Specifies a scratch. When a track is scratched, a scratch track is
487played at random.
488Scratches are played using the same logic as other tracks.
489.IP
490At least for the time being, path names of scratches must be encoded using
491UTF-8 (which means that ASCII will do).
40c30921
RK
492.IP
493If \fBscratch\fR is used without arguments then the list of scratches is
494cleared.
460b9539 495.TP
496.B stopword \fIWORD\fR ...
497Specifies one or more stopwords that should not take part in searches
498over track names.
40c30921
RK
499.IP
500If \fBstopword\fR is used without arguments then the list of stopwords is
501cleared.
62dc3748
RK
502.TP
503.B tracklength \fIPATTERN\fR \fIMODULE\fR
504Specifies the module used to calculate the length of files matching
505\fIPATTERN\fR. \fIMODULE\fR specifies which plugin module to use.
40c30921
RK
506.IP
507If \fBtracklength\fR is used without arguments then the list of modules is
508cleared.
460b9539 509.SS "Client Configuration"
510.TP
ccf0aafa 511.B connect \fIHOST SERVICE\fR
460b9539 512Connect to the address specified by \fIHOST\fR and port specified by
ccf0aafa 513\fISERVICE\fR.
460b9539 514.SS "Web Interface Configuration"
515.TP
516.B refresh \fISECONDS\fR
517Specifies the maximum refresh period in seconds. Default 15.
518.TP
61507e3c
RK
519.B short_display \fICHARACTERS\fR
520Defines the maximum number of characters to include in a \fBshort\fR name
521part. Default 30.
522.TP
460b9539 523.B templates \fIPATH\fR ...
524Specifies the directory containing templates used by the web
525interface. If a template appears in more than one template directory
526then the one in the earliest directory specified is chosen.
527.IP
528See below for further details.
40c30921
RK
529.IP
530If \fBtemplates\fR is used without arguments then the template path is cleared.
460b9539 531.TP
532.B transform \fITYPE\fR \fIREGEXP\fR \fISUBST\fR [\fICONTEXT\fR [\fIREFLAGS\fR]]
533Determines how names are sorted and displayed in track choice displays.
534.IP
535\fITYPE\fR is the type of transformation; usually \fBtrack\fR or
536\fBdir\fR but you can define your own.
537.IP
538\fICONTEXT\fR is a glob pattern matching the context. Standard contexts are
539\fBsort\fR (which determines how directory names are sorted) and \fBdisplay\fR
540(which determines how they are displayed). Again, you can define your
541own.
542.IP
543All the \fBtransform\fR directives are considered in order. If
544the \fITYPE\fR, \fIREGEXP\fR and the \fICONTEXT\fR match
545then a new track name is constructed from
546\fISUBST\fR according to the substitution rules below. If several
547match then each is executed in order.
548.IP
549If you supply no \fBtransform\fR directives at all then a default set will be
550supplied automatically. But if you supply even one then you must supply all of
25ca855b
RK
551them. The defaults are:
552.PP
553.nf
554transform track "^.*/([0-9]+ *[-:] *)?([^/]+)\\.[a-zA-Z0-9]+$" $2 display
555transform track "^.*/([^/]+)\\.[a-zA-Z0-9]+$" $1 sort
556transform dir "^.*/([^/]+)$" $1 *
557transform dir "^(the) ([^/]*)" "$2 $1" sort i
558transform dir "[[:punct:]]" "" sort g
559.fi
460b9539 560.TP
561.B url \fIURL\fR
562Specifies the URL of the web interface. This URL will be used in
563generated web pages.
564.IP
565This must be the full URL, e.g. \fBhttp://myhost/cgi-bin/jukebox\fR and not
566\fB/cgi-bin/jukebox\fR.
567.SS "Authentication Configuration"
568.TP
569.B allow \fIUSERNAME\fR \fIPASSWORD\fR
570Specify a username/password pair.
40c30921
RK
571.IP
572If
573.B allow
574is used without arguments, the list of allowed users is cleared.
460b9539 575.TP
576.B password \fIPASSWORD\fR
577Specify password.
578.TP
579.B trust \fIUSERNAME\fR
580Allow \fIUSERNAME\fR to perform privileged operations such as shutting
581down or reconfiguring the daemon, or becoming another user.
40c30921
RK
582.IP
583If \fBtrust\fR is used without arguments then the list of trusted users is
584cleared.
460b9539 585.TP
586.B user \fIUSER\fR
587Specifies the user to run as. Only makes sense if invoked as root (or
588the target user).
589.TP
590.B username \fIUSERNAME\fR
591Specify username. The default is taken from the environment variable
592\fBLOGNAME\fR.
593.PP
594Configuration files are read in the following order:
595.TP
596.I pkgconfdir/config
597.TP
598.I pkgconfdir/config.private
599Should be readable only by the jukebox group, and contain \fBallow\fR
600commands for authorised users.
36be7e6a
RK
601.IP
602If this file does not exist at startup then the server will create it with a
603randomly chosen password for the root user.
460b9539 604.TP
605.I pkgconfdir/config.\fRUSER
606Per-user system-controlled client configuration. Optional but if it
607exists must be readable only by the relevant user. Would normally
608contain a \fBpassword\fR directive.
609.TP
610.I ~\fRUSER\fI/.disorder/passwd
611Per-user client configuration. Optional but if it exists must be
612readable only by the relevant user. Would normally contain a
613\fBpassword\fR directive.
614.SH "GLOBAL PREFERENCES"
615These are the values set with \fBset-global\fR.
616.TP
617.B required-tags
618If this is set an nonempty then randomly played tracks will always have at
619least one of the listed tags.
460b9539 620.TP
621.B prohibited-tags
622If this is set an nonempty then randomly played tracks will never have any of
623the listed tags.
624.TP
625.B playing
626If unset or \fByes\fR then play is enabled. Otherwise it is disabled. Use
627\fBdisable\fR rather than setting it directly.
628.TP
629.B random-play
630If unset or \fByes\fR then random play is enabled. Otherwise it is disabled.
631Use \fBdisable\fR rather than setting it directly.
f9635e06
RK
632.PP
633Global preferences starting '_' are read-only (in the sense that you cannot
634modify them; the server may modify them as part of its normal operation). They
635are:
636.TP
637.B _dbversion
638The database version string. This is used by DisOrder to detect when it must
639modify the database after an upgrade.
460b9539 640.SH "LIBAO DRIVER"
641.SS "Raw Protocol Players"
642Raw protocol players are expected to use the \fBdisorder\fR libao driver.
643Programs that use libao generally have command line options to select the
644driver and pass options to it.
645.SS "Driver Options"
646The known driver options are:
647.TP
648.B fd
649The file descriptor to write to. If this is not specified then the driver
650looks like the environment variable \fBDISORDER_RAW_FD\fR. If that is not set
651then the default is 1 (i.e. standard output).
652.TP
653.B fragile
654If this is set to a nonzero value then the driver will call \fB_exit\fR(2) if a
655write to the output file descriptor fails. This is a workaround for buggy
656players such as \fBogg123\fR that ignore write errors.
657.SH "WEB TEMPLATES"
658When \fBdisorder.cgi\fR wants to generate a page for an action it searches the
659directories specified with \fBtemplates\fR for a matching file. It is
660suggested that you leave the distributed templates unchanged and put
661any customisations in an earlier entry in the template path.
662.PP
663The supplied templates are:
664.TP
665.B about.html
666Display information about DisOrder.
667.TP
668.B choose.html
669Navigates through the track database to choose a track to play. The
670\fBdir\fR argument gives the directory to look in; if it is missing
671then the root directory is used.
672.TP
673.B choosealpha.html
674Provides a front end to \fBchoose.html\fR which allows subsets of the top level
675directories to be selected by initial letter.
676.TP
d5b6ffd7
RK
677.B new.html
678Lists newly added tracks.
679.TP
460b9539 680.B playing.html
681The "front page", which usually shows the currently playing tracks and
682the queue.
683Gets an HTTP \fBRefresh\fR header.
684.IP
685If the \fBmgmt\fR CGI argument is set to \fBtrue\fR then we include extra
686buttons for moving tracks up and down in the queue. There is some logic in
687\fBdisorder.cgi\fR to ensure that \fBmgmt=true\fR is preserved across refreshes
688and redirects back into itself, but URLs embedded in web pages must include it
689explicitly.
690.TP
691.B prefs.html
692Views preferences. If the \fBfile\fR, \fBname\fR and \fBvalue\fR arguments are
693all set then that preference is modified; if \fBfile\fR and \fBname\fR are set
694but not \fBvalue\fR then the preference is deleted.
695.TP
696.B recent.html
697Lists recently played tracks.
698.TP
699.B search.html
700Presents search results.
701.TP
702.B volume.html
703Primitive volume control.
704.PP
705Additionally, other standard files are included by these:
706.TP
707.B credits.html
708Included at the end of the main content \fB<DIV>\fR element.
709.TP
d5b6ffd7
RK
710.B topbar.html
711Included at the start of the \fB<BODY>\fR element. (This supplants
712\fBsidebar.html\fR, though the latter is still available; override label
713\fBmenu\fR to choose between them.)
460b9539 714.TP
715.B stdhead.html
716Included in the \fB<HEAD>\fR element.
717.TP
718.B stylesheet.html
719Contains the default DisOrder stylesheet. You can override this by editing the
720CSS or by replacing it all with a \fB<LINK>\fR to an external stylesheet.
721.PP
722Templates are ASCII files containing HTML documents, with an expansion
723syntax to enable data supplied by the implementation to be inserted.
724.PP
725If you want to use characters outside the ASCII range, use either the
726appropriate HTML entity, e.g. \fB&eacute;\fR, or an SGML numeric
727character reference, e.g. \fB&#253;\fR. Use \fB&#64;\fR to insert a
728literal \fB@\fR without falling foul of the expansion syntax.
729.SS "Expansion Syntax"
730Expansions are surrounded by at ("@") symbols take the form of a keyword
731followed by zero or more arguments. Arguments may either be quoted by curly
732brackets ("{" and "}") or separated by colons (":"). Both kinds may be mixed
733in a single expansion, though doing so seems likely to cause confusion.
734The descriptions below contain suggested forms for each
735expansion.
736.PP
737Leading and trailing whitespace in unquoted arguments is ignored, as is
738whitespace (including newlines) following a close bracket ("}").
739.PP
740Arguments are recursively expanded before being interpreted, except for
741\fITEMPLATE\fR arguments. These are expanded (possibly more than once) to
742produce the final expansion.
743(More than once means the same argument being expanded more than once
744for different tracks or whatever, not the result of the first
745expansion itself being re-expanded.)
746.PP
747Strings constructed by expansions (i.e. not literally copied from the template
748text) are SGML-quoted: any character which does not stand for itself in #PCDATA
749or a quoted attribute value is replaced by the appropriate numeric character
750reference.
751.PP
752The exception to this is that such strings are \fInot\fR quoted when they are
753generated in the expansion of a parameter.
754.PP
755In the descriptions below, the current track means the one set by
756\fB@playing@\fR, \fB@recent@\fR or \fB@queue@\fR, not the one that is playing.
757If none of these expansions are in force then there is no current track.
758\fIBOOL\fR should always be either \fBtrue\fR or \fBfalse\fR.
759.SS "Expansions"
760The following expansion keywords are defined:
761.TP
762.B @#{\fICOMMENT\fB}@
763Ignored.
764.TP
765.B @action@
766The current action. This reports
767.B manage
768if the action is really
769.B playing
770but
771.B mgmt=true
772was set.
773.TP
774.B @and{\fIBOOL\fB}{\fIBOOL\fB}\fR...\fB@
775If there are no arguments, or all the arguments are \fBtrue\fB, then expands to
776\fBtrue\fR, otherwise to \fBfalse\fR.
777.TP
778.B @arg:\fINAME\fB@
25ca855b 779Expands to the value of CGI argument \fINAME\fR.
460b9539 780.TP
781.B @basename@
782The basename of the current directory component, in \fB@navigate@\fR.
783.TP
784.B @basename{\fIPATH\fB}@
785The base name part of \fIPATH\fR.
786.TP
787.B @choose{\fIWHAT\fB}{\fITEMPLATE\fB}@
788Expands \fITEMPLATE\fR repeatedly for each file or directory under
789\fB@arg:directory@\fR.
790\fIWHAT\fR should be either \fBfile\fR or \fBdirectory\fR.
791Use \fB@file@\fR to get the display name or filename of the file or
792directory.
793Usually used in \fBchoose.html\fR.
794.TP
795.B @dirname@
796The directory of the current directory component, in \fB@navigate@\fR.
797.TP
798.B @dirname{\fIPATH\fB}@
799The directory part of \fIPATH\fR.
800.TP
801.B @enabled@
802Expands to \fBtrue\fR if play is currently enabled, otherwise to \fBfalse\fR.
803.TP
804.B @eq{\fIA\fB}{\fIB\fB}
805Expands to \fBtrue\fR if \fIA\fR and \fIB\fR are identical, otherwise to
806\fBfalse\fR.
807.TP
808.B @file@
809Expands to the filename of the current file or directory, inside the template
810argument to \fBchoose\fR.
811.TP
812.B @files{\fITEMPLATE\fB}
40c30921 813Expands \fITEMPLATE\fR once for each file indicated by the \fBdirectory\fR CGI
460b9539 814arg if it is present, or otherwise for the list of files counted by \fBfiles\fR
815with names \fB0_file\fR, \fB1_file\fR etc.
816.TP
817.B @fullname@
818The full path of the current directory component, in \fB@navigate@\fR.
819.TP
820.B @id@
821The ID of the current track.
822.TP
823.B @if{\fIBOOL\fB}{\fITRUEPART\fB}{\fIFALSEPART\fB}@
824If \fIBOOL\fR expands to \fBtrue\fR then expands to \fITRUEPART\fR, otherwise
825to \fIFALSEPART\fR (which may be omitted).
826.TP
827.B @include:\fIPATH\fR@
828Include the named file as if it were a template file. If \fIPATH\fR
829starts with a \fB/\fR then it is used as-is; otherwise, ".html" is
830appended and the template path is searched.
831.TP
832.B @index@
833Expands to the index of the current file in \fB@queue@\fR, \fB@recent@\fR or
834\fB@files@\fR.
835.TP
836.B @isdirectories@
837Expands to \fBtrue\fR if there are any directories in \fB@arg:directory@\fR,
838otherwise to \fBfalse\fR.
839.TP
840.B @isfiles@
841Expands to \fBtrue\fR if there are any files in \fB@arg:directory@\fR,
842otherwise to \fBfalse\fR.
843.TP
844.B @isfirst@
845Expands to \fBtrue\fR if this is the first repetition of a \fITEMPLATE\fR
846argument in a loop (\fB@queue\fR or similar), otherwise to \fBfalse\fR.
847.TP
848.B @islast@
849Expands to \fBtrue\fR if this is the last repetition of a \fITEMPLATE\fR in a
850loop, otherwise to \fBfalse\fR.
851.TP
d5b6ffd7
RK
852.B @isnew@
853Expands to \fBtrue\fR if the newly added tracks list has any tracks in it,
854otherwise to \fBfalse\fR.
855.TP
460b9539 856.B @isplaying@
857Expands to \fBtrue\fR if a track is playing, otherwise to \fBfalse\fR.
858.TP
859.B @isqueue@
860Expands to \fBtrue\fR if there are any tracks in the queue, otherwise to
861\fBfalse\fR.
862.TP
863.B @isrecent@
864Expands to \fBtrue\fR if the recently played list has any tracks in it,
865otherwise to \fBfalse\fR.
866.TP
867.B @label:\fINAME\fR\fB@
868Expands to the value of label \fINAME\fR. See the shipped \fIoptions.labels\fR
869file for full documentation of the labels used by the standard templates.
870.TP
871.B @length@
872Expands to the length of the current track.
873.TP
874.B @navigate{\fIDIRECTORY\fB}{\fITEMPLATE\fB}
875Expands \fITEMPLATE\fR for each component of \fIDIRECTORY\fR in turn.
876Use \fB@dirname\fR and \fB@basename@\fR to get the components of the path to
877each component.
878Usually used in \fBchoose.html\fR.
879.TP
880.B @ne{\fIA\fB}{\fIB\fB}
881Expands to \fBtrue\fR if \fIA\fR and \fIB\fR differ, otherwise to \fBfalse\fR.
882.TP
d5b6ffd7
RK
883.B @new{\fITEMPLATE\fB}
884Expands \fITEMPLATE\fR for each track in the newly added tracks list, starting
885with the most recent. Used in \fBnew.html\fR.
886.TP
460b9539 887.B @nfiles@
888Expands to the number of files from \fB@files\fR (above).
889.TP
890.B @nonce@
891Expands to a string including the time and process ID, intended to be
892unique across invocations.
893.TP
894.B @not{\fIBOOL\fB}@
895Expands to \fBfalse\fR if \fIBOOL\fR is \fBtrue\fR, otherwise to
896\fBfalse\fR.
897.TP
898.B @or{\fIBOOL\fB}{\fIBOOL\fB}\fR...\fB@
899If at least one argument is \fBtrue\fB, then expands to \fBtrue\fR, otherwise
900to \fBfalse\fR.
901.TP
902.B @parity@
903Expands to \fBeven\fR or \fBodd\fR depending on whether the current track is at
904an even or odd position in \fB@queue@\fR, \fB@recent@\fR or \fB@files@\fR.
905.TP
906.B @part{\fICONTEXT\fB}{\fIPART\fB}@
907Expands to track name part \fIPART\fR using context \fICONTEXT\fR for the
61507e3c 908current track. The context may be omitted and defaults
460b9539 909to \fBdisplay\fR.
61507e3c
RK
910.IP
911The special context \fBshort\fR is equivalent to \fBdisplay\fR but limited to
912the \fBshort_display\fR limit.
460b9539 913.TP
914.B @part{\fICONTEXT\fB}{\fIPART\fB}{\fITRACK\fB}@
915Expands to track name part \fIPART\fR using context \fICONTEXT\fR for
916\fITRACK\fR. In this usage the context may not be omitted.
61507e3c
RK
917.IP
918The special context \fBshort\fR is equivalent to \fBdisplay\fR but limited to
919the \fBshort_display\fR limit.
460b9539 920.TP
921.B @paused@
922Expands to \fBtrue\fR if the current track is paused, else \fBfalse\fR.
923.TP
924.B @playing{\fITEMPLATE\fB}@
925Expands \fITEMPLATE\fR using the playing track as the current track.
926.TP
927.B @pref{\fITRACK\fB}{\fIKEY\fB}@
928Expand to the track preference, or the empty string if it is not set.
929.TP
930.B @prefname@
931Expands to the name of the current preference, in the template
932argument of \fB@prefs@\fR.
933.TP
934.B @prefs{\fIFILE\fB}{\fITEMPLATE\fB}@
935Expands \fITEMPLATE\fR repeatedly, for each preference of track
936\fIFILE\fR.
937Use \fB@prefname@\fR and \fB@prefvalue@\fR to get the name and value.
938.TP
939.B @prefvalue@
940Expands to the value of the current preference, in the template
941argument of \fB@prefs@\fR.
942.TP
943.B @queue{\fITEMPLATE\fB}@
944Expands \fITEMPLATE\fR repeatedly using the each track on the queue in turn as
945the current track. The track at the head of the queue comes first.
946.TP
947.B @random-enabled@
948Expands to \fBtrue\fR if random play is currently enabled, otherwise to
949\fBfalse\fR.
950.TP
951.B @recent{\fITEMPLATE\fB}@
952Expands \fITEMPLATE\fR repeatedly using the each recently played track in turn
953as the current track. The most recently played track comes first.
954.TP
955.B @resolve{\fITRACK\fB}@
956Resolve aliases for \fITRACK\fR and expands to the result.
957.TP
958.B @search{\fIPART\fB}\fR[\fB{\fICONTEXT\fB}\fR]\fB{\fITEMPLATE\fB}@
959Expands \fITEMPLATE\fR once for each group of search results that have
960a common value of track part \fIPART\fR.
961The groups are sorted by the value of the part.
962.IP
963.B @part@
964and
965.B @file@
966within the template will apply to one of the tracks in the group.
967.IP
968If \fICONTEXT\fR is specified it should be either \fBsort\fR or \fBdisplay\fR,
969and determines the context for \fIPART\fR. The default is \fBsort\fR. Usually
970you want \fBdisplay\fR for everything except the title and \fBsort\fR for the
971title. If you use \fBsort\fR for artist and album then you are likely to get
972strange effects.
973.TP
974.B @server-version@
975Expands to the server's version string.
976.TP
977.B @shell{\fICOMMAND\fB}@
978Expands to the output of \fICOMMAND\fR executed via the shell. \fBsh\fR is
979searched for using \fBPATH\fR. If the command fails then this is logged but
980otherwise ignored.
981.TP
982.B @state@
983In \fB@queue@\fR and \fB@recent@\fR, expands to the state of the current
984track. Otherwise the empty string. Known states are:
985.RS
986.TP 12
987.B failed
988The player terminated with nonzero status, but not because the track was
989scratched.
990.TP
991.B isscratch
992A scratch, in the queue.
993.TP
994.B no_player
995No player could be found.
996.TP
997.B ok
998Played successfully.
999.TP
1000.B random
1001A randomly chosen track, in the queue.
1002.TP
1003.B scratched
1004This track was scratched.
1005.TP
1006.B unplayed
1007An explicitly queued track, in the queue.
1008.RE
1009.IP
1010Some additional states only apply to playing tracks, so will never be seen in
1011the queue or recently-played list:
1012.RS
1013.TP 12
1014.B paused
1015The track has been paused.
1016.TP
1017.B quitting
1018Interrupted because the server is shutting down.
1019.TP
1020.B started
1021This track is currently playing.
1022.RE
1023.TP
1024.B @stats@
1025Expands to the server statistics.
1026.TP
1027.B @thisurl@
1028Expands to the URL of the current page. Typically used in
1029.B back
1030arguments. If there is a
1031.B nonce
1032argument then it is changed to a fresh value.
1033.TP
1034.B @track@
1035The current track.
1036.TP
1037.B @trackstate{\fIPATH\fB}@
1038Expands to the current track state: \fBplaying\fR if the track is actually
1039playing now, \fBqueued\fR if it is queued or the empty string otherwise.
1040.TP
1041.B @transform{\fIPATH\fB}{\fITYPE\fB}{\fICONTEXT\fB}@
1042Transform a path according to \fBtransform\fR (see above).
1043\fIPATH\fR should be a raw filename (of a track or directory).
1044\fITYPE\fR should be the transform type (e.g. \fItrack\fR or \fIdir\fR).
1045\fICONTEXT\fR should be the context, and can be omitted (the default
1046is \fBdisplay\fR).
1047.TP
1048.B @url@
1049Expands to the canonical URL as defined in \fIpkgconfdir/config\fR.
1050.TP
1051.B @urlquote{\fISTRING\fB}@
1052URL-quote \fISTRING\fR.
1053.TP
1054.B @version@
1055Expands to \fBdisorder.cgi\fR's version string.
1056.TP
1057.B @volume:\fISPEAKER\fB@
40c30921 1058The volume on the left or right speaker. \fISPEAKER\fR must be \fBleft\fR or
460b9539 1059\fBright\fR.
1060.TP
1061.B @when@
1062When the current track was played (or when it is expected to be played, if it
1063has not been played yet)
1064.TP
1065.B @who@
1066Who submitted the current track.
1067.SH "WEB OPTIONS"
1068This is a file called \fIoptions\fR, searched for in the same manner
1069as templates. It includes numerous options for the control of the web
1070interface. The general syntax is the same as the main configuration
1071file, except that it should be encoded using UTF-8 (though this might
1072change to the current locale's character encoding; stick to ASCII to
1073be safe).
1074.PP
1075The shipped \fIoptions\fR file includes four standard options files.
1076In order, they are:
1077.TP
1078.I options.labels
1079The default labels file. You wouldn't normally edit this directly - instead
1080supply your own commands in \fIoptions.user\fR. Have a look at the shipped
1081version of the file for documentation of labels used by the standard templates.
1082.TP
1083.I options.user
1084A user options file. Here you should put any overrides for the default
1085labels and any extra labels required by your modified templates.
1086.PP
1087Valid directives are:
1088.TP
1089.B columns \fINAME\fR \fIHEADING\fR...
1090Defines the columns used in \fB@playing@\fR and \fB@recent@\fB. \fINAME\fR
1091must be either \fBplaying\fR, \fBrecent\fR or \fBsearch\fR.
1092\fIHEADING\fR... is a list of
1093heading names. If a column is defined more than once then the last definitions
1094is used.
1095.IP
1096The heading names \fBbutton\fR, \fBlength\fR, \fBwhen\fR and \fBwho\fR
1097are built in.
1098.TP
1099.B include \fIPATH\fR
1100Includes another file. If \fIPATH\fR starts with a \fB/\fR then it is
1101taken as is, otherwise it is searched for in the template path.
1102.TP
1103.B label \fINAME\fR \fIVALUE\fR
1104Define a label. If a label is defined more than once then the last definition
1105is used.
1106.SS Labels
1107Some labels are defined inside \fBdisorder.cgi\fR and others by the
1108default templates. You can define your own labels and use them inside
1109a template.
1110.PP
1111When an undefined label is expanded, if it has a dot in its name then
1112the part after the final dot is used as its value. Otherwise the
1113whole name is used as the value.
1114.PP
1115Labels are no longer documented here, see the shipped \fIoptions.labels\fR file
1116instead.
1117.SH "REGEXP SUBSTITUTION RULES"
1118Regexps are PCRE regexps, as defined in \fBpcrepattern\fR(3). The
1119only option used is \fBPCRE_UTF8\fR. Remember that the configuration
1120file syntax means you have to escape backslashes and quotes inside
1121quoted strings.
1122.PP
1123In a \fISUBST\fR string the following sequences are interpreted
1124specially:
1125.TP
1126.B $1 \fR... \fB$9
1127These expand to the first to ninth bracketed subexpression.
1128.TP
1129.B $&
1130This expands to the matched part of the subject string.
1131.TP
1132.B $$
1133This expands to a single \fB$\fR symbol.
1134.PP
1135All other pairs starting with \fB$\fR are undefined (and might be used
1136for something else in the future, so don't rely on the current
1137behaviour.)
1138.PP
1139If \fBi\fR is present in \fIREFLAGS\fR then the match is case-independent. If
1140\fBg\fR is present then all matches are replaced, otherwise only the first
1141match is replaced.
1142.SH "ACTIONS"
1143What the web interface actually does is terminated by the \fBaction\fR CGI
1144argument. The values listed below are supported.
1145.PP
1146Except as specified, all actions redirect back to the \fBplaying.html\fR
1147template unless the \fBback\fR argument is present, in which case the URL it
1148gives is used instead.
1149.PP
1150Redirection to \fBplaying.html\fR preserves \fBmgmt=true\fR if it is present.
1151.TP 8
1152.B "move"
1153Move track \fBid\fR by offset \fBdelta\fR.
1154.TP
1155.B "play"
1156Play track \fBfile\fR, or if that is missing then play all the tracks in
1157\fBdirectory\fR.
1158.TP
1159.B "playing"
1160Don't change any state, but instead compute a suitable refresh time and include
1161that in an HTTP header. Expands the \fBplaying.html\fR template rather than
1162redirecting.
1163.IP
1164This is the default if \fBaction\fR is missing.
1165.TP
1166.B "random-disable"
1167Disables random play.
1168.TP
1169.B "random-enable"
1170Enables random play.
1171.TP
1172.B "disable"
1173Disables play completely.
1174.TP
1175.B "enable"
1176Enables play.
1177.TP
1178.B "pause"
1179Pauses the current track.
1180.TP
1181.B "remove"
1182Remove track \fBid\fR.
1183.TP
1184.B "resume"
1185Resumes play after a pause.
1186.TP
1187.B "scratch"
1188Scratch the playing track. If \fBid\fR is present it must match the playing
1189track.
1190.TP
1191.B "volume"
1192Change the volume by \fBdelta\fR, or if that is missing then set it to the
1193values of \fBleft\fR and \fBright\fR. Expands to the \fBvolume.html\fR template
1194rather than redirecting.
1195.TP
1196.B "prefs"
1197Adjust preferences from the \fBprefs.html\fR template (which it then expands
1198rather than redirecting).
1199.IP
1200If
1201.B parts
1202is set then the cooked interface is assumed. The value of
1203.B parts
1204is used to determine which trackname preferences are set. By default the
1205.B display
1206context is adjusted but this can be overridden with the
1207.B context
1208argument. Also the
1209.B random
1210argument is checked; if it is set then random play is enabled for that track,
1211otherwise it is disabled.
1212.IP
1213Otherwise if the
1214.B name
1215and
1216.B value
1217arguments are set then they are used to set a single preference.
1218.IP
1219Otherwise if just the
1220.B name
1221argument is set then that preference is deleted.
1222.IP
1223It is recommended that links to the \fBprefs\fR action use \fB@resolve@\fR to
1224enure that the real track name is always used. Otherwise if the preferences
1225page is used to adjust a trackname_ preference, the alias may change, leading
1226to the URL going stale.
1227.TP
1228.B "error"
1229This action is generated automatically when an error occurs connecting to the
1230server. The \fBerror\fR label is set to an indication of what the error is.
1231.SH "TRACK NAME PARTS"
1232The traditional track name parts are \fBartist\fR, \fBalbum\fR and \fBtitle\fR,
1233with the obvious intended meaning. These are controlled by configuration and
1234by \fBtrackname_\fR preferences.
1235.PP
1236In addition there are two built-in parts, \fBpath\fR which is the whole path
1237name and \fBext\fR which is the filename extension, including the initial dot
1238(or the empty string if there is not extension).
1239.SH "SEE ALSO"
77cfc7a2 1240\fBdisorder\fR(1), \fBsox\fR(1), \fBdisorderd\fR(8), \fBdisorder-dump\fR(8),
460b9539 1241\fBpcrepattern\fR(3)
1242.\" Local Variables:
1243.\" mode:nroff
1244.\" fill-column:79
1245.\" End: