summaryrefslogtreecommitdiffstats
path: root/DOCS
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-08-02 13:19:23 +0200
committerwm4 <wm4@nowhere>2013-08-02 13:19:23 +0200
commitac6b150e941ac5df0e7e7655fa7f71a0d201cc87 (patch)
tree8a04ef0f6400c0dff4b420b315d3860d616c2d83 /DOCS
parent7cec9b1ffe1e696e1732778202c4ab71c108a5b6 (diff)
downloadmpv-ac6b150e941ac5df0e7e7655fa7f71a0d201cc87.tar.bz2
mpv-ac6b150e941ac5df0e7e7655fa7f71a0d201cc87.tar.xz
manpage: document exit codes
Diffstat (limited to 'DOCS')
-rw-r--r--DOCS/man/en/mpv.rst18
1 files changed, 18 insertions, 0 deletions
diff --git a/DOCS/man/en/mpv.rst b/DOCS/man/en/mpv.rst
index 781b78ad22..875faa77d5 100644
--- a/DOCS/man/en/mpv.rst
+++ b/DOCS/man/en/mpv.rst
@@ -588,6 +588,24 @@ libavformat:
``no_proxy``
FIXME: Document this.
+EXIT CODES
+==========
+
+Normally **mpv** returns 0 as exit code after finishing playback successfully.
+If errors happen, the following exit codes can be returned:
+
+ :1: Error initializing mpv. This is also returned if unknown options are
+ passed to mpv.
+ :2: The file passed to mpv couldn't be played. This is somewhat fuzzy:
+ currently, playback of a file is considered to be successful if
+ initialization was mostly successful, even if playback fails
+ immediately after initialization.
+ :3: There were some files that could be played, and some files which
+ couldn't (using the definition of success from above).
+
+Note that quitting the player manually will always lead to exit code 0,
+overriding the exit code that would be returned normally. Also, the ``quit``
+input command can take an exit code: in this case, that exit code is returned.
FILES
=====