From 2d8bfc33fce069e6061169e6a1b1ea3fe47b3c98 Mon Sep 17 00:00:00 2001 From: Toni Gundogdu Date: Tue, 15 Oct 2013 16:38:52 +0300 Subject: [PATCH] scan: Add support for embedded vzaar.com media URLs Signed-off-by: Toni Gundogdu --- share/Makefile.am | 1 + share/scan/vzaar.lua | 30 ++++++++++++++++++++++++++++++ 2 files changed, 31 insertions(+) create mode 100644 share/scan/vzaar.lua diff --git a/share/Makefile.am b/share/Makefile.am index 19b496f..a4cbece 100644 --- a/share/Makefile.am +++ b/share/Makefile.am @@ -115,6 +115,7 @@ dist_playlist_DATA=\ scandir=$(pkgdatadir)/$(VERSION)/scan dist_scan_DATA=\ + scan/vzaar.lua\ scan/youtube.lua install-data-hook: diff --git a/share/scan/vzaar.lua b/share/scan/vzaar.lua new file mode 100644 index 0000000..f6ed657 --- /dev/null +++ b/share/scan/vzaar.lua @@ -0,0 +1,30 @@ +-- libquvi-scripts +-- Copyright (C) 2013 Toni Gundogdu +-- +-- This file is part of libquvi-scripts . +-- +-- This program is free software: you can redistribute it and/or +-- modify it under the terms of the GNU Affero General Public +-- License as published by the Free Software Foundation, either +-- version 3 of the License, or (at your option) any later version. +-- +-- This program is distributed in the hope that it will be useful, +-- but WITHOUT ANY WARRANTY; without even the implied warranty of +-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +-- GNU Affero General Public License for more details. +-- +-- You should have received a copy of the GNU Affero General +-- Public License along with this program. If not, see +-- . +-- + +-- Parse the scan properties. +function parse(qargs) + qargs.media_url = {} + for u in qargs.content:gmatch('(https?://view%.vzaar%.com/%d+/player)') do + table.insert(qargs.media_url, u) + end + return qargs +end + +-- vim: set ts=2 sw=2 tw=72 expandtab: -- 2.11.4.GIT