docs: Add manpages for all commands
This commit is contained in:
parent
4ec372ad0a
commit
be5582e212
13
docs/commands/index.rst
Normal file
13
docs/commands/index.rst
Normal file
@ -0,0 +1,13 @@
|
||||
.. _commands:
|
||||
|
||||
********
|
||||
Commands
|
||||
********
|
||||
|
||||
Mopidy comes with the following commands:
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
:glob:
|
||||
|
||||
**
|
||||
99
docs/commands/mopidy-convert-config.rst
Normal file
99
docs/commands/mopidy-convert-config.rst
Normal file
@ -0,0 +1,99 @@
|
||||
.. _mopidy-convert-config:
|
||||
|
||||
*****************************
|
||||
mopidy-convert-config command
|
||||
*****************************
|
||||
|
||||
Synopsis
|
||||
========
|
||||
|
||||
mopidy-convert-config
|
||||
[-h] [--version] [-q] [-v]
|
||||
|
||||
|
||||
Description
|
||||
===========
|
||||
|
||||
Mopidy is a music server which can play music both from multiple sources, like
|
||||
your local hard drive, radio streams, and from Spotify and SoundCloud. Searches
|
||||
combines results from all music sources, and you can mix tracks from all
|
||||
sources in your play queue. Your playlists from Spotify or SoundCloud are also
|
||||
available for use.
|
||||
|
||||
The ``mopidy-convert-config`` command is used to convert ``settings.py``
|
||||
configuration files used by ``mopidy`` < 0.14 to the ``mopidy.conf`` config
|
||||
file used by ``mopidy`` >= 0.14.
|
||||
|
||||
|
||||
Options
|
||||
=======
|
||||
|
||||
.. program:: mopidy-convert-config
|
||||
|
||||
This program does not take any options. It looks for the pre-0.14 settings file
|
||||
at ``$XDG_CONFIG_DIR/mopidy/settings.py``, and if it exists it converts it and
|
||||
ouputs a Mopidy 0.14 compatible ini-format configuration. If you don't already
|
||||
have a config file at ``$XDG_CONFIG_DIR/mopidy/mopidy.conf``, you're asked if
|
||||
you want to save the converted config to that file.
|
||||
|
||||
|
||||
Example
|
||||
=======
|
||||
|
||||
Given the following contents in ``~/.config/mopidy/settings.py``:
|
||||
|
||||
::
|
||||
|
||||
LOCAL_MUSIC_PATH = u'~/music'
|
||||
MPD_SERVER_HOSTNAME = u'::'
|
||||
SPOTIFY_PASSWORD = u'secret'
|
||||
SPOTIFY_USERNAME = u'alice'
|
||||
|
||||
Running ``mopidy-convert-config`` will convert the config and create a new
|
||||
``mopidy.conf`` config file:
|
||||
|
||||
.. code-block:: none
|
||||
|
||||
$ mopidy-convert-config
|
||||
Checking /home/alice/.config/mopidy/settings.py
|
||||
Converted config:
|
||||
|
||||
[spotify]
|
||||
username = alice
|
||||
password = ********
|
||||
|
||||
[mpd]
|
||||
hostname = ::
|
||||
|
||||
[local]
|
||||
media_dir = ~/music
|
||||
|
||||
Write new config to /home/alice/.config/mopidy/mopidy.conf? [yN] y
|
||||
Done.
|
||||
|
||||
Contents of ``~/.config/mopidy/mopidy.conf`` after the conversion:
|
||||
|
||||
.. code-block:: ini
|
||||
|
||||
[spotify]
|
||||
username = alice
|
||||
password = secret
|
||||
|
||||
[mpd]
|
||||
hostname = ::
|
||||
|
||||
[local]
|
||||
media_dir = ~/music
|
||||
|
||||
|
||||
See also
|
||||
========
|
||||
|
||||
:ref:`mopidy(1) <mopidy-cmd>`
|
||||
|
||||
|
||||
Reporting bugs
|
||||
==============
|
||||
|
||||
Report bugs to Mopidy's issue tracker at
|
||||
<https://github.com/mopidy/mopidy/issues>
|
||||
59
docs/commands/mopidy-scan.rst
Normal file
59
docs/commands/mopidy-scan.rst
Normal file
@ -0,0 +1,59 @@
|
||||
.. _mopidy-scan-cmd:
|
||||
|
||||
*******************
|
||||
mopidy-scan command
|
||||
*******************
|
||||
|
||||
Synopsis
|
||||
========
|
||||
|
||||
mopidy-scan
|
||||
[-h] [--version] [-q] [-v]
|
||||
|
||||
|
||||
Description
|
||||
===========
|
||||
|
||||
Mopidy is a music server which can play music both from multiple sources, like
|
||||
your local hard drive, radio streams, and from Spotify and SoundCloud. Searches
|
||||
combines results from all music sources, and you can mix tracks from all
|
||||
sources in your play queue. Your playlists from Spotify or SoundCloud are also
|
||||
available for use.
|
||||
|
||||
The ``mopidy-scan`` command is used to index a music library to make it
|
||||
available for playback with ``mopidy``.
|
||||
|
||||
|
||||
Options
|
||||
=======
|
||||
|
||||
.. program:: mopidy-scan
|
||||
|
||||
.. cmdoption:: --version
|
||||
|
||||
Show Mopidy's version number and exit.
|
||||
|
||||
.. cmdoption:: -h, --help
|
||||
|
||||
Show help message and exit.
|
||||
|
||||
.. cmdoption:: -q, --quiet
|
||||
|
||||
Show less output: warning level and higher.
|
||||
|
||||
.. cmdoption:: -v, --verbose
|
||||
|
||||
Show more output: debug level and higher.
|
||||
|
||||
|
||||
See also
|
||||
========
|
||||
|
||||
:ref:`mopidy(1) <mopidy-cmd>`
|
||||
|
||||
|
||||
Reporting bugs
|
||||
==============
|
||||
|
||||
Report bugs to Mopidy's issue tracker at
|
||||
<https://github.com/mopidy/mopidy/issues>
|
||||
124
docs/commands/mopidy.rst
Normal file
124
docs/commands/mopidy.rst
Normal file
@ -0,0 +1,124 @@
|
||||
.. _mopidy-cmd:
|
||||
|
||||
**************
|
||||
mopidy command
|
||||
**************
|
||||
|
||||
Synopsis
|
||||
========
|
||||
|
||||
mopidy
|
||||
[-h] [--version] [-q] [-v] [--save-debug-log] [--show-config]
|
||||
[--show-deps] [--config CONFIG_FILES] [-o CONFIG_OVERRIDES]
|
||||
|
||||
|
||||
Description
|
||||
===========
|
||||
|
||||
Mopidy is a music server which can play music both from multiple sources, like
|
||||
your local hard drive, radio streams, and from Spotify and SoundCloud. Searches
|
||||
combines results from all music sources, and you can mix tracks from all
|
||||
sources in your play queue. Your playlists from Spotify or SoundCloud are also
|
||||
available for use.
|
||||
|
||||
The ``mopidy`` command is used to start the server.
|
||||
|
||||
|
||||
Options
|
||||
=======
|
||||
|
||||
.. program:: mopidy
|
||||
|
||||
.. cmdoption:: -h, --help
|
||||
|
||||
Show help message and exit.
|
||||
|
||||
.. cmdoption:: --version
|
||||
|
||||
Show Mopidy's version number and exit.
|
||||
|
||||
.. cmdoption:: -q, --quiet
|
||||
|
||||
Show less output: warning level and higher.
|
||||
|
||||
.. cmdoption:: -v, --verbose
|
||||
|
||||
Show more output: debug level and higher.
|
||||
|
||||
.. cmdoption:: --save-debug-log
|
||||
|
||||
Save debug log to the file specified in the :confval:`logging/debug_file`
|
||||
config value, typically ``./mopidy.log``.
|
||||
|
||||
.. cmdoption:: --show-config
|
||||
|
||||
Show the current effective config. All configuration sources are merged
|
||||
together to show the effective document. Secret values like passwords are
|
||||
masked out. Config for disabled extensions are not included.
|
||||
|
||||
.. cmdoption:: --show-deps
|
||||
|
||||
Show dependencies, their versions and installation location.
|
||||
|
||||
.. cmdoption:: --config <file>
|
||||
|
||||
Specify config file to use. To use multiple config files, separate them
|
||||
with colon. The later files override the earlier ones if there's a
|
||||
conflict.
|
||||
|
||||
.. cmdoption:: -o <option>, --option <option>
|
||||
|
||||
Specify additional config values in the ``section/key=value`` format. Can
|
||||
be provided multiple times.
|
||||
|
||||
|
||||
Files
|
||||
=====
|
||||
|
||||
/etc/mopidy/mopidy.conf
|
||||
System wide Mopidy configuration file.
|
||||
|
||||
~/.config/mopidy/mopidy.conf
|
||||
Your personal Mopidy configuration file. Overrides any configs from the
|
||||
system wide configuration file.
|
||||
|
||||
|
||||
Examples
|
||||
========
|
||||
|
||||
To start the music server, run::
|
||||
|
||||
mopidy
|
||||
|
||||
To start the server with an additional config file than can override configs
|
||||
set in the default config files, run::
|
||||
|
||||
mopidy --config ./my-config.conf
|
||||
|
||||
To start the server and change a config value directly on the command line,
|
||||
run::
|
||||
|
||||
mopidy --option mpd/enabled=false
|
||||
|
||||
The :option:`--option` flag may be repeated multiple times to change multiple
|
||||
configs::
|
||||
|
||||
mopidy -o mpd/enabled=false -o spotify/bitrate=320
|
||||
|
||||
The :option:`--show-config` output shows the effect of the :option:`--option`
|
||||
flags::
|
||||
|
||||
mopidy -o mpd/enabled=false -o spotify/bitrate=320 --show-config
|
||||
|
||||
|
||||
See also
|
||||
========
|
||||
|
||||
:ref:`mopidy-scan(1) <mopidy-scan-cmd>`, :ref:`mopidy-convert-config(1)
|
||||
<mopidy-convert-config>`
|
||||
|
||||
Reporting bugs
|
||||
==============
|
||||
|
||||
Report bugs to Mopidy's issue tracker at
|
||||
<https://github.com/mopidy/mopidy/issues>
|
||||
27
docs/conf.py
27
docs/conf.py
@ -136,6 +136,33 @@ latex_documents = [
|
||||
]
|
||||
|
||||
|
||||
# -- Options for manpages output ----------------------------------------------
|
||||
|
||||
man_pages = [
|
||||
(
|
||||
'commands/mopidy',
|
||||
'mopidy',
|
||||
'music server',
|
||||
'',
|
||||
'1'
|
||||
),
|
||||
(
|
||||
'commands/mopidy-scan',
|
||||
'mopidy-scan',
|
||||
'index music for playback with mopidy',
|
||||
'',
|
||||
'1'
|
||||
),
|
||||
(
|
||||
'commands/mopidy-convert-config',
|
||||
'mopidy-convert-config',
|
||||
'migrate config files from mopidy pre-0.14',
|
||||
'',
|
||||
'1'
|
||||
),
|
||||
]
|
||||
|
||||
|
||||
# -- Options for extlink extension --------------------------------------------
|
||||
|
||||
extlinks = {'issue': ('https://github.com/mopidy/mopidy/issues/%s', '#')}
|
||||
|
||||
@ -71,6 +71,7 @@ Reference
|
||||
:maxdepth: 2
|
||||
|
||||
glossary
|
||||
commands/index
|
||||
api/index
|
||||
modules/index
|
||||
|
||||
|
||||
128
docs/running.rst
128
docs/running.rst
@ -6,10 +6,17 @@ To start Mopidy, simply open a terminal and run::
|
||||
|
||||
mopidy
|
||||
|
||||
For a complete reference to the Mopidy commands and their command line options,
|
||||
see :ref:`mopidy-cmd` and :ref:`mopidy-scan-cmd`.
|
||||
|
||||
When Mopidy says ``MPD server running at [127.0.0.1]:6600`` it's ready to
|
||||
accept connections by any MPD client. Check out our non-exhaustive
|
||||
:doc:`/clients/mpd` list to find recommended clients.
|
||||
|
||||
|
||||
Stopping Mopidy
|
||||
===============
|
||||
|
||||
To stop Mopidy, press ``CTRL+C`` in the terminal where you started Mopidy.
|
||||
|
||||
Mopidy will also shut down properly if you send it the TERM signal, e.g. by
|
||||
@ -18,124 +25,3 @@ using ``kill``::
|
||||
kill `ps ax | grep mopidy | grep -v grep | cut -d' ' -f1`
|
||||
|
||||
This can be useful e.g. if you create init script for managing Mopidy.
|
||||
|
||||
|
||||
mopidy command
|
||||
==============
|
||||
|
||||
.. program:: mopidy
|
||||
|
||||
.. cmdoption:: --version
|
||||
|
||||
Show Mopidy's version number and exit.
|
||||
|
||||
.. cmdoption:: -h, --help
|
||||
|
||||
Show help message and exit.
|
||||
|
||||
.. cmdoption:: -q, --quiet
|
||||
|
||||
Show less output: warning level and higher.
|
||||
|
||||
.. cmdoption:: -v, --verbose
|
||||
|
||||
Show more output: debug level and higher.
|
||||
|
||||
.. cmdoption:: --save-debug-log
|
||||
|
||||
Save debug log to the file specified in the :confval:`logging/debug_file`
|
||||
config value, typically ``./mopidy.conf``.
|
||||
|
||||
.. cmdoption:: --show-config
|
||||
|
||||
Show the current effective config. All configuration sources are merged
|
||||
together to show the effective document. Secret values like passwords are
|
||||
masked out. Config for disabled extensions are not included.
|
||||
|
||||
.. cmdoption:: --show-deps
|
||||
|
||||
Show dependencies, their versions and installation location.
|
||||
|
||||
.. cmdoption:: --config <file>
|
||||
|
||||
Specify config file to use. To use multiple config files, separate them
|
||||
with colon. The later files override the earlier ones if there's a
|
||||
conflict.
|
||||
|
||||
.. cmdoption:: -o <option>, --option <option>
|
||||
|
||||
Specify additional config values in the ``section/key=value`` format. Can
|
||||
be provided multiple times.
|
||||
|
||||
|
||||
|
||||
mopidy-scan command
|
||||
===================
|
||||
|
||||
.. program:: mopidy-scan
|
||||
|
||||
.. cmdoption:: --version
|
||||
|
||||
Show Mopidy's version number and exit.
|
||||
|
||||
.. cmdoption:: -h, --help
|
||||
|
||||
Show help message and exit.
|
||||
|
||||
.. cmdoption:: -q, --quiet
|
||||
|
||||
Show less output: warning level and higher.
|
||||
|
||||
.. cmdoption:: -v, --verbose
|
||||
|
||||
Show more output: debug level and higher.
|
||||
|
||||
|
||||
.. _mopidy-convert-config:
|
||||
|
||||
mopidy-convert-config command
|
||||
=============================
|
||||
|
||||
.. program:: mopidy-convert-config
|
||||
|
||||
This program does not take any options. It looks for the pre-0.14 settings file
|
||||
at ``$XDG_CONFIG_DIR/mopidy/settings.py``, and if it exists it converts it and
|
||||
ouputs a Mopidy 0.14 compatible ini-format configuration. If you don't already
|
||||
have a config file at ``$XDG_CONFIG_DIR/mopidy/mopidy.conf``, you're asked if
|
||||
you want to save the converted config to that file.
|
||||
|
||||
Example usage::
|
||||
|
||||
$ cat ~/.config/mopidy/settings.py
|
||||
LOCAL_MUSIC_PATH = u'~/music'
|
||||
MPD_SERVER_HOSTNAME = u'::'
|
||||
SPOTIFY_PASSWORD = u'secret'
|
||||
SPOTIFY_USERNAME = u'alice'
|
||||
|
||||
$ mopidy-convert-config
|
||||
Checking /home/alice/.config/mopidy/settings.py
|
||||
Converted config:
|
||||
|
||||
[spotify]
|
||||
username = alice
|
||||
password = ********
|
||||
|
||||
[mpd]
|
||||
hostname = ::
|
||||
|
||||
[local]
|
||||
media_dir = ~/music
|
||||
|
||||
Write new config to /home/alice/.config/mopidy/mopidy.conf? [yN] y
|
||||
Done.
|
||||
|
||||
$ cat ~/.config/mopidy/mopidy.conf
|
||||
[spotify]
|
||||
username = alice
|
||||
password = secret
|
||||
|
||||
[mpd]
|
||||
hostname = ::
|
||||
|
||||
[local]
|
||||
media_dir = ~/music
|
||||
|
||||
Loading…
Reference in New Issue
Block a user