From 9e3b790fd7c05e438b7195806688ed14857fc7f6 Mon Sep 17 00:00:00 2001
From: Francois Cartegnie <fcvlcdev@free.fr>
Date: Fri, 26 Sep 2014 23:04:14 +0200
Subject: [PATCH] lua: add missing documentation for scopes

---
 share/Makefile.am         |  2 ++
 share/lua/meta/README.txt | 24 ++++++++++++++++++++++++
 2 files changed, 26 insertions(+)
 create mode 100644 share/lua/meta/README.txt

diff --git a/share/Makefile.am b/share/Makefile.am
index 105ed0cbe203..8c7c36c9ac91 100644
--- a/share/Makefile.am
+++ b/share/Makefile.am
@@ -160,6 +160,7 @@ nobase_doc_DATA = \
 	lua/extensions/README.txt \
 	lua/intf/README.txt \
 	lua/intf/dumpmeta.lua \
+	lua/meta/README.txt \
 	lua/meta/art/README.txt \
 	lua/meta/art/01_googleimage.lua \
 	lua/meta/fetcher/README.txt \
@@ -198,6 +199,7 @@ EXTRA_DIST += \
 	lua/intf/modules/host.lua \
 	lua/intf/modules/httprequests.lua \
 	lua/intf/telnet.lua \
+	lua/meta/README.txt \
 	lua/meta/art/README.txt \
 	lua/meta/art/02_frenchtv.lua \
 	lua/meta/art/03_lastfm.lua \
diff --git a/share/lua/meta/README.txt b/share/lua/meta/README.txt
new file mode 100644
index 000000000000..774250327e0e
--- /dev/null
+++ b/share/lua/meta/README.txt
@@ -0,0 +1,24 @@
+## Generic instructions about VLC Lua meta scripts.
+$Id$
+
+There is 3 types of Lua meta modules: art, fetcher and reader.
+See their own README.txt for documentation.
+
+See lua/README.txt for generic documentation about Lua usage in VLC.
+
+## API
+
+VLC Lua meta modules should define a descriptor function:
+  * descriptor(): returns a table with information about the module.
+    This table has the following member:
+      .scope: Search scope of the script. Can be "network" or "local".
+              and defaults to "network".
+              "local" scripts are considered fast and processed first.
+              "network" scripts are considered slow and processed in a
+              second pass only if policy allows it.
+
+    Example:
+    function descriptor()
+        return { scope="network" }
+    end
+
-- 
GitLab