summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorkaliko <kaliko@azylum.org>2020-04-22 19:42:06 +0200
committerMax Kellermann <max@musicpd.org>2020-08-14 13:14:34 +0200
commit5f63ffd86cdd27ee98b4451f6445889e1efb3fb5 (patch)
treefb47b2b45d64a4722be02b3210082d96a8a6ec85 /doc
parent9df2469e514d4a5739de9ca045dea9e612aca804 (diff)
Convert raw manpages to reStructured text
Build with `rst2man mpd.1.rst mpd.1`
Diffstat (limited to 'doc')
-rw-r--r--doc/conf.py4
-rw-r--r--doc/meson.build15
-rw-r--r--doc/mpd.155
-rw-r--r--doc/mpd.1.rst56
-rw-r--r--doc/mpd.conf.5180
-rw-r--r--doc/mpd.conf.5.rst189
6 files changed, 262 insertions, 237 deletions
diff --git a/doc/conf.py b/doc/conf.py
index e7be2e6d3..7eccbef68 100644
--- a/doc/conf.py
+++ b/doc/conf.py
@@ -212,3 +212,7 @@ html_static_path = ['_static']
# implements a search results scorer. If empty, the default will be used.
#
# html_search_scorer = 'scorer.js'
+man_pages = [
+ ('mpd.1', 'mpd', 'MPD documentation', [author], 1),
+ ('mpd.conf.5', 'mpd.conf', 'mpd.conf documentation', [author], 5)
+]
diff --git a/doc/meson.build b/doc/meson.build
index 630a25d20..06b66e557 100644
--- a/doc/meson.build
+++ b/doc/meson.build
@@ -1,5 +1,3 @@
-install_man(['mpd.1', 'mpd.conf.5'])
-
if not get_option('html_manual')
subdir_done()
endif
@@ -39,3 +37,16 @@ if get_option('html_manual')
],
)
endif
+
+if get_option('manpages')
+ manpages = custom_target(
+ 'Manpage documentation',
+ output: 'man',
+ input: ['mpd.1.rst', 'mpd.conf.5.rst', 'conf.py'],
+ command: [sphinx, '-q', '-b', 'man', '-d', '@OUTDIR@/man_doctrees', meson.current_source_dir(), '@OUTPUT@'],
+ build_by_default: true,
+ )
+
+ install_data(join_paths(manpages.full_path(), 'mpd.1'), install_dir: join_paths(get_option('mandir'), 'man1'))
+ install_data(join_paths(manpages.full_path(), 'mpd.conf.5'), install_dir: join_paths(get_option('mandir'), 'man5'))
+endif
diff --git a/doc/mpd.1 b/doc/mpd.1
deleted file mode 100644
index 5d2634570..000000000
--- a/doc/mpd.1
+++ /dev/null
@@ -1,55 +0,0 @@
-.TH "Music Player Daemon" 1
-.SH NAME
-MPD \- A daemon for playing music
-.SH SYNOPSIS
-.B mpd
-.RI [ options ]
-.RI [ CONF_FILE ]
-.SH DESCRIPTION
-MPD is a daemon for playing music. Music is played through the configured
-audio output(s) (which are generally local, but can be remote). The daemon
-stores info about all available music, and this info can be easily searched and
-retrieved. Player control, info retrieval, and playlist management can all be
-managed remotely.
-
-MPD searches for a config file in \fB$XDG_CONFIG_HOME/mpd/mpd.conf\fP then
-\fB~/.mpdconf\fP then \fB/etc/mpd.conf\fP or uses CONF_FILE.
-
-Read more about MPD at <\fBhttp://www.musicpd.org/\fP>.
-.SH OPTIONS
-.TP
-.BI \-\-help
-Output a brief help message.
-.TP
-.BI \-\-kill
-Kill the currently running mpd session. The pid_file parameter must be
-specified in the config file for this to work.
-.TP
-.BI \-\-no\-daemon
-Don't detach from console.
-.TP
-.BI \-\-stderr
-Print messages stderr.
-.TP
-.BI \-\-verbose
-Verbose logging.
-.TP
-.BI \-\-version
-Print version information.
-.SH FILES
-.TP
-.BI ~/.mpdconf
-User configuration file.
-.TP
-.BI /etc/mpd.conf
-Global configuration file.
-.SH SEE ALSO
-mpd.conf(5), mpc(1)
-.SH BUGS
-If you find a bug, please report it at
-.br
-<\fBhttps://github.com/MusicPlayerDaemon/MPD/issues/\fP>.
-.SH AUTHORS
-Max Kellermann <max.kellermann@gmail.com>
-
-Special thanks to all the people that provided feedback and patches.
diff --git a/doc/mpd.1.rst b/doc/mpd.1.rst
new file mode 100644
index 000000000..e74f9a8dc
--- /dev/null
+++ b/doc/mpd.1.rst
@@ -0,0 +1,56 @@
+===
+mpd
+===
+
+SYNOPSIS
+--------
+
+``mpd`` [options] [CONF_FILE]
+
+DESCRIPTION
+------------
+
+MPD is a daemon for playing music. Music is played through the configured audio output(s) (which are generally local, but can be remote). The daemon stores info about all available music, and this info can be easily searched and retrieved. Player control, info retrieval, and playlist management can all be managed remotely.
+
+MPD searches for a config file in ``$XDG_CONFIG_HOME/mpd/mpd.conf`` then ``~/.mpdconf`` then ``/etc/mpd.conf`` or uses CONF_FILE.
+
+Read more about MPD at ``<http://www.musicpd.org/>``.
+
+OPTIONS
+-------
+
+--help
+ Output a brief help message.
+
+--kill
+ Kill the currently running mpd session. The pid_file parameter must be specified in the config file for this to work.
+
+--no-daemon
+ Don't detach from console.
+
+--stderr
+ Print messages stderr.
+
+--verbose
+ Verbose logging.
+
+--version
+ Print version information.
+
+FILES
+-----
+
+~/.mpdconf
+ User configuration file.
+
+/etc/mpd.conf
+ Global configuration file.
+
+SEE ALSO
+--------
+
+mpd.conf(5), mpc(1)
+
+BUGS
+----
+If you find a bug, please report it at ``<https://github.com/MusicPlayerDaemon/MPD/issues/>``.
diff --git a/doc/mpd.conf.5 b/doc/mpd.conf.5
deleted file mode 100644
index 58d951b53..000000000
--- a/doc/mpd.conf.5
+++ /dev/null
@@ -1,180 +0,0 @@
-.TH mpd.conf 5
-.SH NAME
-mpd.conf \- Music Player Daemon configuration file
-.SH DESCRIPTION
-\fBmpd.conf\fP is the configuration file for mpd(1). If not specified on the
-command line, MPD first searches for it at \fB$XDG_CONFIG_HOME/mpd/mpd.conf\fP
-then at \fB~/.mpdconf\fP then at \fB~/.mpd/mpd.conf\fP and then in
-\fB/etc/mpd.conf\fP.
-
-Lines beginning with a "#" character are comments. All other non-empty lines
-specify parameters and their values. These lines contain the parameter name
-and parameter value (surrounded by double quotes) separated by whitespace
-(either tabs or spaces). For example:
-
-parameter "value"
-
-The exception to this rule is the audio_output parameter, which is of the form:
-
-audio_output {
-.br
- parameter1 "value"
- parameter2 "value"
-.br
-}
-
-Parameters that take a file or directory as an argument should use absolute
-paths.
-
-See \fBdocs/mpdconf.example\fP in the source tarball for an example
-configuration file.
-
-This manual is not complete, it lists only the most important options.
-Please read the MPD user manual for a complete configuration guide:
-<\fBhttp://www.musicpd.org/doc/user/\fP>
-.SH REQUIRED PARAMETERS
-.TP
-.B db_file <file>
-This specifies where the db file will be stored.
-.TP
-.B log_file <file>
-This specifies where the log file should be located.
-The special value "syslog" makes MPD use the local syslog daemon.
-.SH OPTIONAL PARAMETERS
-.TP
-.B sticker_file <file>
-The location of the sticker database. This is a database which
-manages dynamic information attached to songs.
-.TP
-.B pid_file <file>
-This specifies the file to save mpd's process ID in.
-.TP
-.B music_directory <directory>
-This specifies the directory where music is located.
-If you do not configure this, you can only play streams.
-.TP
-.B playlist_directory <directory>
-This specifies the directory where saved playlists are stored.
-If you do not configure this, you cannot save playlists.
-.TP
-.B state_file <file>
-This specifies if a state file is used and where it is located. The state of
-mpd will be saved to this file when mpd is terminated by a TERM signal or by
-the "kill" command. When mpd is restarted, it will read the state file and
-restore the state of mpd (including the playlist).
-.TP
-.B restore_paused <yes or no>
-Put MPD into pause mode instead of starting playback after startup.
-.TP
-.B user <username>
-This specifies the user that MPD will run as, if set. MPD should
-never run as root, and you may use this option to make MPD change its
-user id after initialization. Do not use this option if you start MPD
-as an unprivileged user.
-.TP
-.B port <port>
-This specifies the port that mpd listens on. The default is 6600.
-.TP
-.B log_level <default, secure, or verbose>
-This specifies how verbose logs are. "default" is minimal logging, "secure"
-reports from what address a connection is opened, and when it is closed, and
-"verbose" records excessive amounts of information for debugging purposes. The
-default is "default".
-.TP
-.B follow_outside_symlinks <yes or no>
-Control if MPD will follow symbolic links pointing outside the music dir.
-You must recreate the database after changing this option.
-The default is "yes".
-.TP
-.B follow_inside_symlinks <yes or no>
-Control if MPD will follow symbolic links pointing inside the music dir,
-potentially adding duplicates to the database.
-You must recreate the database after changing this option.
-The default is "yes".
-.TP
-.B zeroconf_enabled <yes or no>
-If yes, and MPD has been compiled with support for Avahi or Bonjour, service
-information will be published with Zeroconf. The default is yes.
-.TP
-.B zeroconf_name <name>
-If Zeroconf is enabled, this is the service name to publish. This name should
-be unique to your local network, but name collisions will be properly dealt
-with. The default is "Music Player @ %h", where %h will be replaced with the
-hostname of the machine running MPD.
-.TP
-.B audio_output
-See \fBDESCRIPTION\fP and the various \fBAUDIO OUTPUT PARAMETERS\fP sections
-for the format of this parameter. Multiple audio_output sections may be
-specified. If no audio_output section is specified, then MPD will scan for a
-usable audio output.
-.TP
-.B replaygain <off or album or track or auto>
-If specified, mpd will adjust the volume of songs played using ReplayGain tags
-(see <\fBhttp://www.replaygain.org/\fP>). Setting this to "album" will adjust
-volume using the album's ReplayGain tags, while setting it to "track" will
-adjust it using the track ReplayGain tags. "auto" uses the track ReplayGain
-tags if random play is activated otherwise the album ReplayGain tags. Currently
-only FLAC, Ogg Vorbis, Musepack, and MP3 (through ID3v2 ReplayGain tags, not
-APEv2) are supported.
-.TP
-.B replaygain_preamp <\-15 to 15>
-This is the gain (in dB) applied to songs with ReplayGain tags.
-.TP
-.B volume_normalization <yes or no>
-If yes, mpd will normalize the volume of songs as they play. The default is no.
-.TP
-.B filesystem_charset <charset>
-This specifies the character set used for the filesystem. A list of supported
-character sets can be obtained by running "iconv \-l". The default is
-determined from the locale when the db was originally created.
-.TP
-.B save_absolute_paths_in_playlists <yes or no>
-This specifies whether relative or absolute paths for song filenames are used
-when saving playlists. The default is "no".
-.TP
-.B auto_update <yes or no>
-This specifies the whether to support automatic update of music database when
-files are changed in music_directory. The default is to disable autoupdate
-of database.
-.TP
-.B auto_update_depth <N>
-Limit the depth of the directories being watched, 0 means only watch
-the music directory itself. There is no limit by default.
-.SH REQUIRED AUDIO OUTPUT PARAMETERS
-.TP
-.B type <type>
-This specifies the audio output type. See the list of supported outputs in mpd
-\-\-version for possible values.
-.TP
-.B name <name>
-This specifies a unique name for the audio output.
-.SH OPTIONAL AUDIO OUTPUT PARAMETERS
-.TP
-.B format <sample_rate:bits:channels>
-This specifies the sample rate, bits per sample, and number of channels of
-audio that is sent to the audio output device. See documentation for the
-\fBaudio_output_format\fP parameter for more details. The default is to use
-whatever audio format is passed to the audio output.
-Any of the three attributes may be an asterisk to specify that this
-attribute should not be enforced
-.TP
-.B replay_gain_handler <software, mixer or none>
-Specifies how replay gain is applied. The default is "software",
-which uses an internal software volume control. "mixer" uses the
-configured (hardware) mixer control. "none" disables replay gain on
-this audio output.
-.TP
-.B mixer_type <hardware, software or none>
-Specifies which mixer should be used for this audio output: the
-hardware mixer (available for ALSA, OSS and PulseAudio), the software
-mixer or no mixer ("none"). By default, the hardware mixer is used
-for devices which support it, and none for the others.
-.SH FILES
-.TP
-.BI ~/.mpdconf
-User configuration file.
-.TP
-.BI /etc/mpd.conf
-Global configuration file.
-.SH SEE ALSO
-mpd(1), mpc(1)
diff --git a/doc/mpd.conf.5.rst b/doc/mpd.conf.5.rst
new file mode 100644
index 000000000..95da0b506
--- /dev/null
+++ b/doc/mpd.conf.5.rst
@@ -0,0 +1,189 @@
+========
+mpd.conf
+========
+
+
+DESCRIPTION
+------------
+
+``mpd.conf`` is the configuration file for mpd(1). If not specified on the command line, MPD first searches for it at ``$XDG_CONFIG_HOME/mpd/mpd.conf`` then at ``~/.mpdconf`` then at ``~/.mpd/mpd.conf`` and then in ``/etc/mpd.conf``.
+
+Lines beginning with a "#" character are comments. All other non-empty lines
+specify parameters and their values. These lines contain the parameter name and
+parameter value (surrounded by double quotes) separated by whitespace (either
+tabs or spaces). For example:
+
+parameter "value"
+
+The exception to this rule is the audio_output parameter, which is of theform::
+
+ audio_output {
+ parameter1 "value"
+ parameter2 "value"
+ }
+
+
+Parameters that take a file or directory as an argument should use absolute paths.
+
+See ``docs/mpdconf.example`` in the source tarball for an example configuration file.
+
+This manual is not complete, it lists only the most important options.
+Please read the MPD user manual for a complete configuration guide:
+``<http://www.musicpd.org/doc/user/>``
+
+
+REQUIRED PARAMETERS
+-------------------
+
+db_file <file>
+ This specifies where the db file will be stored.
+
+log_file <file>
+ This specifies where the log file should be located. The special value "syslog" makes MPD use the local syslog daemon.
+
+OPTIONAL PARAMETERS
+-------------------
+
+sticker_file <file>
+ The location of the sticker database. This is a database which manages
+ dynamic information attached to songs.
+
+pid_file <file>
+ This specifies the file to save mpd's process ID in.
+
+music_directory <directory>
+ This specifies the directory where music is located. If you do not configure
+ this, you can only play streams.
+
+playlist_directory <directory>
+ This specifies the directory where saved playlists are stored. If
+ you do not configure this, you cannot save playlists.
+
+state_file <file>
+ This specifies if a state file is used and where it is located. The state of
+ mpd will be saved to this file when mpd is terminated by a TERM signal or by
+ the "kill" command. When mpd is restarted, it will read the state file and
+ restore the state of mpd (including the playlist).
+
+restore_paused <yes or no>
+ Put MPD into pause mode instead of starting playback after startup.
+
+user <username>
+ This specifies the user that MPD will run as, if set. MPD should never run
+ as root, and you may use this option to make MPD change its user id after
+ initialization. Do not use this option if you start MPD as an unprivileged
+ user.
+
+port <port>
+ This specifies the port that mpd listens on. The default is 6600.
+
+log_level <default, secure, or verbose>
+ This specifies how verbose logs are. "default" is minimal logging, "secure"
+ reports from what address a connection is opened, and when it is closed, and
+ "verbose" records excessive amounts of information for debugging purposes.
+ The default is "default".
+
+follow_outside_symlinks <yes or no>
+ Control if MPD will follow symbolic links pointing outside the music dir. You
+ must recreate the database after changing this option. The default is "yes".
+
+follow_inside_symlinks <yes or no>
+ Control if MPD will follow symbolic links pointing inside the music dir,
+ potentially adding duplicates to the database. You must recreate the
+ database after changing this option. The default is "yes".
+
+zeroconf_enabled <yes or no>
+ If yes, and MPD has been compiled with support for Avahi or Bonjour, service
+ information will be published with Zeroconf. The default is yes.
+
+zeroconf_name <name>
+ If Zeroconf is enabled, this is the service name to publish. This name should
+ be unique to your local network, but name collisions will be properly dealt
+ with. The default is "Music Player @ %h", where %h will be replaced with the
+ hostname of the machine running MPD.
+
+audio_output
+ See DESCRIPTION and the various ``AUDIO OUTPUT PARAMETERS`` sections for the
+ format of this parameter. Multiple audio_output sections may be specified. If
+ no audio_output section is specified, then MPD will scan for a usable audio
+ output.
+
+replaygain <off or album or track or auto>
+ If specified, mpd will adjust the volume of songs played using ReplayGain
+ tags (see ``<http://www.replaygain.org/>``). Setting this to "album" will
+ adjust volume using the album's ReplayGain tags, while setting it to "track"
+ will adjust it using the track ReplayGain tags. "auto" uses the track
+ ReplayGain tags if random play is activated otherwise the album ReplayGain
+ tags. Currently only FLAC, Ogg Vorbis, Musepack, and MP3 (through ID3v2
+ ReplayGain tags, not APEv2) are supported.
+
+replaygain_preamp <-15 to 15>
+ This is the gain (in dB) applied to songs with ReplayGain tags.
+
+volume_normalization <yes or no>
+ If yes, mpd will normalize the volume of songs as they play. The default is
+ no.
+
+filesystem_charset <charset>
+ This specifies the character set used for the filesystem. A list of supported
+ character sets can be obtained by running "iconv -l". The default is
+ determined from the locale when the db was originally created.
+
+save_absolute_paths_in_playlists <yes or no>
+ This specifies whether relative or absolute paths for song filenames are used
+ when saving playlists. The default is "no".
+
+auto_update <yes or no>
+ This specifies the whether to support automatic update of music database
+ when files are changed in music_directory. The default is to disable
+ autoupdate of database.
+
+auto_update_depth <N>
+ Limit the depth of the directories being watched, 0 means only watch the
+ music directory itself. There is no limit by default.
+
+REQUIRED AUDIO OUTPUT PARAMETERS
+--------------------------------
+
+type <type>
+ This specifies the audio output type. See the list of supported outputs in
+ mpd --version for possible values.
+
+name <name>
+ This specifies a unique name for the audio output.
+
+OPTIONAL AUDIO OUTPUT PARAMETERS
+--------------------------------
+
+format <sample_rate:bits:channels>
+ This specifies the sample rate, bits per sample, and number of channels of
+ audio that is sent to the audio output device. See documentation for the
+ ``audio_output_format`` parameter for more details. The default is to use
+ whatever audio format is passed to the audio output. Any of the three
+ attributes may be an asterisk to specify that this attribute should not be
+ enforced
+
+replay_gain_handler <software, mixer or none>
+ Specifies how replay gain is applied. The default is "software", which uses
+ an internal software volume control. "mixer" uses the configured (hardware)
+ mixer control. "none" disables replay gain on this audio output.
+
+mixer_type <hardware, software or none>
+ Specifies which mixer should be used for this audio output: the hardware
+ mixer (available for ALSA, OSS and PulseAudio), the software mixer or no
+ mixer ("none"). By default, the hardware mixer is used for devices which
+ support it, and none for the others.
+
+FILES
+-----
+
+~/.mpdconf
+ User configuration file.
+
+/etc/mpd.conf
+ Global configuration file.
+
+SEE ALSO
+--------
+
+ mpd(1), mpc(1)