Renamed a few extension-less python handlers with a .py extension for consistency
This commit is contained in:
parent
667e661c46
commit
8b3792026f
@ -14,8 +14,8 @@ share/pixmaps/recoll.png
|
||||
%%DATADIR%%/filters/hotrecoll.py
|
||||
%%DATADIR%%/filters/rclabw
|
||||
%%DATADIR%%/filters/rclaptosidman
|
||||
%%DATADIR%%/filters/rclaudio
|
||||
%%DATADIR%%/filters/rclchm
|
||||
%%DATADIR%%/filters/rclaudio.py
|
||||
%%DATADIR%%/filters/rclchm.py
|
||||
%%DATADIR%%/filters/rcldjvu
|
||||
%%DATADIR%%/filters/rcldoc
|
||||
%%DATADIR%%/filters/rcldvi
|
||||
@ -23,11 +23,11 @@ share/pixmaps/recoll.png
|
||||
%%DATADIR%%/filters/rclfb2
|
||||
%%DATADIR%%/filters/rclflac
|
||||
%%DATADIR%%/filters/rclgaim
|
||||
%%DATADIR%%/filters/rclics
|
||||
%%DATADIR%%/filters/rclics.py
|
||||
%%DATADIR%%/filters/rclid3
|
||||
%%DATADIR%%/filters/rclimg
|
||||
%%DATADIR%%/filters/rclinfo
|
||||
%%DATADIR%%/filters/rclkar
|
||||
%%DATADIR%%/filters/rclinfo.py
|
||||
%%DATADIR%%/filters/rclkar.py
|
||||
%%DATADIR%%/filters/rclkwd
|
||||
%%DATADIR%%/filters/rcllatinclass.py
|
||||
%%DATADIR%%/filters/rcllatinstops.zip
|
||||
@ -41,7 +41,7 @@ share/pixmaps/recoll.png
|
||||
%%DATADIR%%/filters/rclps
|
||||
%%DATADIR%%/filters/rclpurple
|
||||
%%DATADIR%%/filters/rclpython
|
||||
%%DATADIR%%/filters/rclrar
|
||||
%%DATADIR%%/filters/rclrar.py
|
||||
%%DATADIR%%/filters/rclrtf
|
||||
%%DATADIR%%/filters/rclscribus
|
||||
%%DATADIR%%/filters/rclshowinfo
|
||||
@ -51,11 +51,11 @@ share/pixmaps/recoll.png
|
||||
%%DATADIR%%/filters/rcltex
|
||||
%%DATADIR%%/filters/rcltext
|
||||
%%DATADIR%%/filters/rcluncomp
|
||||
%%DATADIR%%/filters/rclwar
|
||||
%%DATADIR%%/filters/rclwar.py
|
||||
%%DATADIR%%/filters/rclwpd
|
||||
%%DATADIR%%/filters/rclxls
|
||||
%%DATADIR%%/filters/rclzip
|
||||
%%DATADIR%%/filters/rcl7z
|
||||
%%DATADIR%%/filters/rclzip.py
|
||||
%%DATADIR%%/filters/rcl7z.py
|
||||
%%DATADIR%%/filters/xdg-open
|
||||
%%DATADIR%%/images/aptosid-book.png
|
||||
%%DATADIR%%/images/aptosid-manual.png
|
||||
|
||||
@ -60,40 +60,40 @@ index f41a9f39..dc3085a4 100755
|
||||
#
|
||||
# This Source Code Form is subject to the terms of the Mozilla Public
|
||||
# License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
diff --git filters/rcl7z filters/rcl7z
|
||||
diff --git filters/rcl7z.py filters/rcl7z.py
|
||||
index c68c8bcb..ac50c4ec 100755
|
||||
--- filters/rcl7z
|
||||
+++ filters/rcl7z
|
||||
--- filters/rcl7z.py
|
||||
+++ filters/rcl7z.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
|
||||
# 7-Zip file filter for Recoll
|
||||
|
||||
diff --git filters/rclaudio filters/rclaudio
|
||||
diff --git filters/rclaudio.py filters/rclaudio.py
|
||||
index 94ca0be7..08d6375a 100755
|
||||
--- filters/rclaudio
|
||||
+++ filters/rclaudio
|
||||
--- filters/rclaudio.py
|
||||
+++ filters/rclaudio.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
|
||||
# Audio tag filter for Recoll, using mutagen
|
||||
|
||||
diff --git filters/rclchm filters/rclchm
|
||||
diff --git filters/rclchm.py filters/rclchm.py
|
||||
index f9811c37..3bc9b16d 100755
|
||||
--- filters/rclchm
|
||||
+++ filters/rclchm
|
||||
--- filters/rclchm.py
|
||||
+++ filters/rclchm.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
"""Extract Html files from a Microsoft Compiled Html Help file (.chm)
|
||||
Needs at least python 2.2 for HTMLParser (chmlib needs 2.2 too)"""
|
||||
|
||||
diff --git filters/rcldia filters/rcldia
|
||||
diff --git filters/rcldia.py filters/rcldia.py
|
||||
index 282148eb..a480294b 100755
|
||||
--- filters/rcldia
|
||||
+++ filters/rcldia
|
||||
--- filters/rcldia.py
|
||||
+++ filters/rcldia.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
@ -120,30 +120,30 @@ index e8fa1831..b92b185d 100755
|
||||
from __future__ import print_function
|
||||
|
||||
import rclexecm
|
||||
diff --git filters/rclepub filters/rclepub
|
||||
diff --git filters/rclepub.py filters/rclepub.py
|
||||
index 8042d7f9..51786af1 100755
|
||||
--- filters/rclepub
|
||||
+++ filters/rclepub
|
||||
--- filters/rclepub.py
|
||||
+++ filters/rclepub.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
"""Extract Html content from an EPUB file (.epub)"""
|
||||
from __future__ import print_function
|
||||
|
||||
diff --git filters/rclepub1 filters/rclepub1
|
||||
diff --git filters/rclepub.py1 filters/rclepub.py1
|
||||
index bd44f635..a7ea6c06 100755
|
||||
--- filters/rclepub1
|
||||
+++ filters/rclepub1
|
||||
--- filters/rclepub.py1
|
||||
+++ filters/rclepub.py1
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
"""Extract Html content from an EPUB file (.chm), concatenating all sections"""
|
||||
from __future__ import print_function
|
||||
|
||||
diff --git filters/rclics filters/rclics
|
||||
diff --git filters/rclics.py filters/rclics.py
|
||||
index 0ef04f2d..de177024 100755
|
||||
--- filters/rclics
|
||||
+++ filters/rclics
|
||||
--- filters/rclics.py
|
||||
+++ filters/rclics.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
@ -160,20 +160,20 @@ index 7eb1da91..4eb6c9b0 100755
|
||||
|
||||
# Python-based Image Tag extractor for Recoll. This is less thorough
|
||||
# than the Perl-based rclimg script, but useful if you don't want to
|
||||
diff --git filters/rclinfo filters/rclinfo
|
||||
diff --git filters/rclinfo.py filters/rclinfo.py
|
||||
index f353d19e..36cf34e0 100755
|
||||
--- filters/rclinfo
|
||||
+++ filters/rclinfo
|
||||
--- filters/rclinfo.py
|
||||
+++ filters/rclinfo.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
|
||||
# Read a file in GNU info format and output its nodes as subdocs,
|
||||
# interfacing with recoll execm
|
||||
diff --git filters/rclkar filters/rclkar
|
||||
diff --git filters/rclkar.py filters/rclkar.py
|
||||
index d6570dd5..34b8d2a2 100755
|
||||
--- filters/rclkar
|
||||
+++ filters/rclkar
|
||||
--- filters/rclkar.py
|
||||
+++ filters/rclkar.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
@ -230,10 +230,10 @@ index 615455b3..1e411890 100755
|
||||
# -*- coding: iso-8859-1 -*-
|
||||
"""
|
||||
MoinMoin - Python source parser and colorizer
|
||||
diff --git filters/rclrar filters/rclrar
|
||||
diff --git filters/rclrar.py filters/rclrar.py
|
||||
index 8f723fa5..5f6adfb0 100755
|
||||
--- filters/rclrar
|
||||
+++ filters/rclrar
|
||||
--- filters/rclrar.py
|
||||
+++ filters/rclrar.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
@ -280,10 +280,10 @@ index 8c1b8aea..cee17324 100755
|
||||
# Copyright (C) 2014 J.F.Dockes
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
diff --git filters/rcltar filters/rcltar
|
||||
diff --git filters/rcltar.py filters/rcltar.py
|
||||
index d8bf100d..ab4b306e 100755
|
||||
--- filters/rcltar
|
||||
+++ filters/rcltar
|
||||
--- filters/rcltar.py
|
||||
+++ filters/rcltar.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
@ -320,10 +320,10 @@ index 32a11c1a..eab3b257 100644
|
||||
from __future__ import print_function
|
||||
|
||||
import rclexecm
|
||||
diff --git filters/rclwar filters/rclwar
|
||||
diff --git filters/rclwar.py filters/rclwar.py
|
||||
index b654f3b3..301e28e9 100755
|
||||
--- filters/rclwar
|
||||
+++ filters/rclwar
|
||||
--- filters/rclwar.py
|
||||
+++ filters/rclwar.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
@ -360,10 +360,10 @@ index 158e1222..602769af 100755
|
||||
# Copyright (C) 2016 J.F.Dockes
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
diff --git filters/rclzip filters/rclzip
|
||||
diff --git filters/rclzip.py filters/rclzip.py
|
||||
index 35739625..0c597fbd 100755
|
||||
--- filters/rclzip
|
||||
+++ filters/rclzip
|
||||
--- filters/rclzip.py
|
||||
+++ filters/rclzip.py
|
||||
@@ -1,4 +1,4 @@
|
||||
-#!/usr/bin/env python2
|
||||
+#!/usr/bin/env python2.7
|
||||
|
||||
@ -686,31 +686,31 @@ filters/openxml-xls-body.xsl \
|
||||
filters/openxml-word-body.xsl \
|
||||
filters/openxml-meta.xsl \
|
||||
filters/ppt-dump.py \
|
||||
filters/rcl7z \
|
||||
filters/rcl7z.py \
|
||||
filters/rclaptosidman \
|
||||
filters/rclaudio \
|
||||
filters/rclaudio.py \
|
||||
filters/rclbasehandler.py \
|
||||
filters/rclbibtex.sh \
|
||||
filters/rclcheckneedretry.sh \
|
||||
filters/rclchm \
|
||||
filters/rcldia \
|
||||
filters/rclchm.py \
|
||||
filters/rcldia.py \
|
||||
filters/rcldjvu.py \
|
||||
filters/rcldoc.py \
|
||||
filters/rcldvi \
|
||||
filters/rclepub \
|
||||
filters/rclepub1 \
|
||||
filters/rclepub.py \
|
||||
filters/rclepub1.py \
|
||||
filters/rclexec1.py \
|
||||
filters/rclexecm.py \
|
||||
filters/rclfb2.py \
|
||||
filters/rclgaim \
|
||||
filters/rclgenxslt.py \
|
||||
filters/rclhwp.py \
|
||||
filters/rclics \
|
||||
filters/rclics.py \
|
||||
filters/rclimg \
|
||||
filters/rclimg.py \
|
||||
filters/rclinfo \
|
||||
filters/rclinfo.py \
|
||||
filters/rclipynb.py \
|
||||
filters/rclkar \
|
||||
filters/rclkar.py \
|
||||
filters/rclkwd \
|
||||
filters/rcllatinclass.py \
|
||||
filters/rcllatinstops.zip \
|
||||
@ -729,21 +729,21 @@ filters/rclps \
|
||||
filters/rclpst.py \
|
||||
filters/rclpurple \
|
||||
filters/rclpython.py \
|
||||
filters/rclrar \
|
||||
filters/rclrar.py \
|
||||
filters/rclrtf.py \
|
||||
filters/rclscribus \
|
||||
filters/rclshowinfo \
|
||||
filters/rcltar \
|
||||
filters/rcltar.py \
|
||||
filters/rcltex \
|
||||
filters/rcltext.py \
|
||||
filters/rcluncomp \
|
||||
filters/rcluncomp.py \
|
||||
filters/rclwar \
|
||||
filters/rclwar.py \
|
||||
filters/rclxls.py \
|
||||
filters/rclxml.py \
|
||||
filters/rclxmp.py \
|
||||
filters/rclxslt.py \
|
||||
filters/rclzip \
|
||||
filters/rclzip.py \
|
||||
filters/recoll-we-move-files.py \
|
||||
filters/recollepub.zip \
|
||||
filters/svg.xsl \
|
||||
|
||||
@ -2763,8 +2763,8 @@ Chapter 4. Programming interface
|
||||
|
||||
If you can program and want to write an execm handler, it should not be
|
||||
too difficult to make sense of one of the existing modules. For example,
|
||||
look at rclzip which uses Zip file paths as identifiers (ipath), and
|
||||
rclics, which uses an integer index. Also have a look at the comments
|
||||
look at rclzip.py which uses Zip file paths as identifiers (ipath), and
|
||||
rclics.py, which uses an integer index. Also have a look at the comments
|
||||
inside the internfile/mh_execm.h file and possibly at the corresponding
|
||||
module.
|
||||
|
||||
@ -2819,7 +2819,7 @@ Chapter 4. Programming interface
|
||||
|
||||
text/rtf = exec unrtf --nopict --html; charset=iso-8859-1; mimetype=text/html
|
||||
|
||||
application/x-chm = execm rclchm
|
||||
application/x-chm = execm rclchm.py
|
||||
|
||||
The fragment specifies that:
|
||||
|
||||
|
||||
@ -1 +1 @@
|
||||
1.31.6
|
||||
1.32.0
|
||||
|
||||
@ -148,7 +148,7 @@ not set, the daemon uses skippedPaths.
|
||||
.TP
|
||||
.BI "zipUseSkippedNames = "bool
|
||||
Use skippedNames inside Zip archives. Fetched
|
||||
directly by the rclzip handler. Skip the patterns defined by skippedNames
|
||||
directly by the rclzip.py handler. Skip the patterns defined by skippedNames
|
||||
inside Zip archives. Can be redefined for subdirectories.
|
||||
See https://www.lesbonscomptes.com/recoll/faqsandhowtos/FilteringOutZipArchiveMembers.html
|
||||
|
||||
@ -195,7 +195,7 @@ lets you turn off md5 computation for selected types. It is global (no
|
||||
redefinition for subtrees). At the moment, it only has an effect for
|
||||
external handlers (exec and execm). The file types can be specified by
|
||||
listing either MIME types (e.g. audio/mpeg) or handler names
|
||||
(e.g. rclaudio).
|
||||
(e.g. rclaudio.py).
|
||||
.TP
|
||||
.BI "compressedfilemaxkbs = "int
|
||||
Size limit for compressed
|
||||
|
||||
@ -112,7 +112,7 @@ not set, the daemon uses skippedPaths.
|
||||
<varlistentry id="RCL.INSTALL.CONFIG.RECOLLCONF.ZIPUSESKIPPEDNAMES">
|
||||
<term><varname>zipUseSkippedNames</varname></term>
|
||||
<listitem><para>Use skippedNames inside Zip archives. Fetched
|
||||
directly by the rclzip handler. Skip the patterns defined by skippedNames
|
||||
directly by the rclzip.py handler. Skip the patterns defined by skippedNames
|
||||
inside Zip archives. Can be redefined for subdirectories.
|
||||
See https://www.lesbonscomptes.com/recoll/faqsandhowtos/FilteringOutZipArchiveMembers.html
|
||||
</para></listitem></varlistentry>
|
||||
@ -162,7 +162,7 @@ lets you turn off md5 computation for selected types. It is global (no
|
||||
redefinition for subtrees). At the moment, it only has an effect for
|
||||
external handlers (exec and execm). The file types can be specified by
|
||||
listing either MIME types (e.g. audio/mpeg) or handler names
|
||||
(e.g. rclaudio).
|
||||
(e.g. rclaudio.py).
|
||||
</para></listitem></varlistentry>
|
||||
<varlistentry id="RCL.INSTALL.CONFIG.RECOLLCONF.COMPRESSEDFILEMAXKBS">
|
||||
<term><varname>compressedfilemaxkbs</varname></term>
|
||||
|
||||
@ -6581,9 +6581,10 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
|
||||
<p>All the Python handlers share at least the
|
||||
<code class="filename">rclexecm.py</code> module,
|
||||
which handles the communication. Have a look at,
|
||||
for example, <code class="filename">rclzip</code>
|
||||
for a handler which uses <code class=
|
||||
"filename">rclexecm.py</code> directly.</p>
|
||||
for example, <code class=
|
||||
"filename">rclzip.py</code> for a handler which
|
||||
uses <code class="filename">rclexecm.py</code>
|
||||
directly.</p>
|
||||
</li>
|
||||
<li class="listitem">
|
||||
<p>Most Python handlers which process
|
||||
@ -6633,7 +6634,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
|
||||
"_top">Git repository</a> (the sample not in the
|
||||
distributed release at the moment).</p>
|
||||
<p>You can also have a look at the slightly more complex
|
||||
<span class="command"><strong>rclzip</strong></span>
|
||||
<span class="command"><strong>rclzip.py</strong></span>
|
||||
which uses Zip file paths as identifiers (<code class=
|
||||
"literal">ipath</code>).</p>
|
||||
<p><code class="literal">execm</code> handlers sometimes
|
||||
@ -6726,7 +6727,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
|
||||
|
||||
text/rtf = exec unrtf --nopict --html; charset=iso-8859-1; mimetype=text/html
|
||||
|
||||
application/x-chm = execm rclchm
|
||||
application/x-chm = execm rclchm.py
|
||||
</pre>
|
||||
<p>The fragment specifies that:</p>
|
||||
<div class="itemizedlist">
|
||||
@ -6880,7 +6881,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
|
||||
"literal">setfield()</code> helper method. This avoids
|
||||
the necessity to produce HTML, and any issue with HTML
|
||||
quoting. See, for example, <code class=
|
||||
"filename">rclaudio</code> in <span class=
|
||||
"filename">rclaudio.py</code> in <span class=
|
||||
"application">Recoll</span> 1.23 and later for an example
|
||||
of handler which outputs <code class=
|
||||
"literal">text/plain</code> and uses <code class=
|
||||
@ -9081,9 +9082,10 @@ hasextract = False
|
||||
"RCL.INSTALL.CONFIG.RECOLLCONF.ZIPUSESKIPPEDNAMES"></a><span class="term"><code class="varname">zipUseSkippedNames</code></span></dt>
|
||||
<dd>
|
||||
<p>Use skippedNames inside Zip archives. Fetched
|
||||
directly by the rclzip handler. Skip the patterns
|
||||
defined by skippedNames inside Zip archives. Can
|
||||
be redefined for subdirectories. See
|
||||
directly by the rclzip.py handler. Skip the
|
||||
patterns defined by skippedNames inside Zip
|
||||
archives. Can be redefined for subdirectories.
|
||||
See
|
||||
https://www.lesbonscomptes.com/recoll/faqsandhowtos/FilteringOutZipArchiveMembers.html</p>
|
||||
</dd>
|
||||
<dt><a name=
|
||||
@ -9155,7 +9157,8 @@ hasextract = False
|
||||
moment, it only has an effect for external
|
||||
handlers (exec and execm). The file types can be
|
||||
specified by listing either MIME types (e.g.
|
||||
audio/mpeg) or handler names (e.g. rclaudio).</p>
|
||||
audio/mpeg) or handler names (e.g.
|
||||
rclaudio.py).</p>
|
||||
</dd>
|
||||
<dt><a name=
|
||||
"RCL.INSTALL.CONFIG.RECOLLCONF.COMPRESSEDFILEMAXKBS"
|
||||
|
||||
@ -4957,7 +4957,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
|
||||
is).</para></listitem> <listitem><para>All the Python handlers
|
||||
share at least the <filename>rclexecm.py</filename> module, which
|
||||
handles the communication. Have a look at, for
|
||||
example, <filename>rclzip</filename> for a handler which
|
||||
example, <filename>rclzip.py</filename> for a handler which
|
||||
uses <filename>rclexecm.py</filename>
|
||||
directly.</para></listitem> <listitem><para>Most Python handlers
|
||||
which process single-document files by executing another command
|
||||
@ -4994,7 +4994,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
|
||||
the moment).</para>
|
||||
|
||||
<para>You can also have a look at the slightly more complex
|
||||
<command>rclzip</command> which uses Zip
|
||||
<command>rclzip.py</command> which uses Zip
|
||||
file paths as identifiers (<literal>ipath</literal>).</para>
|
||||
|
||||
<para><literal>execm</literal> handlers sometimes need to make
|
||||
@ -5062,7 +5062,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
|
||||
|
||||
text/rtf = exec unrtf --nopict --html; charset=iso-8859-1; mimetype=text/html
|
||||
|
||||
application/x-chm = execm rclchm
|
||||
application/x-chm = execm rclchm.py
|
||||
</programlisting>
|
||||
|
||||
<para>The fragment specifies that:
|
||||
@ -5205,7 +5205,7 @@ text/html [file:///Users/uncrypted-dockes/projets/bateaux/ilur/factEtCie/r
|
||||
method to produce metadata, by calling the
|
||||
<literal>setfield()</literal> helper method. This avoids the
|
||||
necessity to produce HTML, and any issue with HTML quoting. See,
|
||||
for example, <filename>rclaudio</filename> in &RCL; 1.23 and
|
||||
for example, <filename>rclaudio.py</filename> in &RCL; 1.23 and
|
||||
later for an example of handler which outputs
|
||||
<literal>text/plain</literal> and uses
|
||||
<literal>setfield()</literal> to produce metadata.</para>
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
# 7-Zip file filter for Recoll
|
||||
|
||||
# Thanks to Recoll user Martin Ziegler
|
||||
# This is a modified version of rclzip, with some help from rcltar
|
||||
# This is a modified version of rclzip.py, with some help from rcltar.py
|
||||
#
|
||||
# Normally using py7zr https://github.com/miurahr/py7zr
|
||||
#
|
||||
@ -6,7 +6,7 @@ from __future__ import print_function
|
||||
# stefan.friedel@iwr.uni-heidelberg.de 2012
|
||||
#
|
||||
# add the following to ~/.recoll/mimeconf into the [index] section:
|
||||
# application/x-dia-diagram = execm rcldia;mimetype=text/plain;charset=utf-8
|
||||
# application/x-dia-diagram = execm rcldia.py;mimetype=text/plain;charset=utf-8
|
||||
# and into the [icons] section:
|
||||
# application/x-dia-diagram = drawing
|
||||
# and finally under [categories]:
|
||||
@ -372,7 +372,7 @@ def main(proto, extract):
|
||||
|
||||
params = {'filename' : makebytes(path)}
|
||||
|
||||
# Some filters (e.g. rclaudio) need/get a MIME type from the indexer.
|
||||
# Some filters (e.g. rclaudio.py) need/get a MIME type from the indexer.
|
||||
# We make a half-assed attempt to emulate:
|
||||
mimetype = _g_config.mimeType(path)
|
||||
if not mimetype and not _g_mswindows:
|
||||
|
||||
@ -141,7 +141,7 @@ class InfoSimpleSplitter:
|
||||
if name == b'File':
|
||||
infofile = value
|
||||
except Exception as err:
|
||||
print("rclinfo: bad line in %s: [%s] %s\n" % \
|
||||
print("rclinfo.py: bad line in %s: [%s] %s\n" % \
|
||||
(infofile, line, err), file = sys.stderr)
|
||||
nodename = prevnodename
|
||||
node += line
|
||||
@ -60,7 +60,7 @@ except Exception as ex:
|
||||
# (https://www.rarlab.com/rar_add.htm). The unrar-free version fails
|
||||
# with the message "Failed the read enough data"
|
||||
#
|
||||
# This is identical to rclzip except I did a search/replace from zip
|
||||
# This is identical to rclzip.py except I did a search/replace from zip
|
||||
# to rar, and changed this comment.
|
||||
class RarExtractor:
|
||||
def __init__(self, em):
|
||||
@ -2,7 +2,7 @@
|
||||
|
||||
# Tar-file filter for Recoll
|
||||
# Thanks to Recoll user Martin Ziegler
|
||||
# This is a modified version of /usr/share/recoll/filters/rclzip
|
||||
# This is a modified version of /usr/share/recoll/filters/rclzip.py
|
||||
# It works not only for tar-files, but automatically for gzipped and
|
||||
# bzipped tar-files at well.
|
||||
|
||||
@ -51,7 +51,7 @@ if not hasrclconfig:
|
||||
# and stores it in the catalog as an unicode object. Else it uses the
|
||||
# binary string, which it decodes as CP437 (zip standard).
|
||||
#
|
||||
# When reading the file, the input file name is used by rclzip
|
||||
# When reading the file, the input file name is used by rclzip.py
|
||||
# directly as an index into the catalog.
|
||||
#
|
||||
# When we send the file name data to the indexer, we have to serialize
|
||||
@ -51,7 +51,7 @@ using namespace std;
|
||||
// The internal path element separator. This can't be the same as the rcldb
|
||||
// file to ipath separator : "|"
|
||||
// We replace it with a control char if it comes out of a filter (ie:
|
||||
// rclzip or rclchm can do this). If you want the SOH control char
|
||||
// rclzip.py or rclchm.py can do this). If you want the SOH control char
|
||||
// inside an ipath, you're out of luck (and a bit weird).
|
||||
static const string cstr_isep(":");
|
||||
|
||||
|
||||
@ -82,8 +82,7 @@ bool MimeHandlerExec::set_document_file_impl(const std::string& mt,
|
||||
tpsread = true;
|
||||
if (!nomd5tps.empty()) {
|
||||
if (params.size() &&
|
||||
nomd5tps.find(path_getsimple(params[0])) !=
|
||||
nomd5tps.end()) {
|
||||
nomd5tps.find(path_getsimple(params[0])) != nomd5tps.end()) {
|
||||
m_handlernomd5 = true;
|
||||
}
|
||||
// On windows the 1st param is often a script interp
|
||||
|
||||
@ -73,7 +73,7 @@ text/plainData: 10
|
||||
* time). Absent during indexing (ipaths are generated and sent back from
|
||||
* the script)
|
||||
* - Mimetype: this is the mime type for the (possibly container) file.
|
||||
* Can be useful to filters which handle multiple types, like rclaudio.
|
||||
* Can be useful to filters which handle multiple types, like rclaudio.py.
|
||||
*
|
||||
* The script answers with messages having the following fields:
|
||||
* - Document: translated document data.
|
||||
|
||||
@ -209,30 +209,30 @@ mac {
|
||||
../filters/openxml-word-body.xsl \
|
||||
../filters/openxml-meta.xsl \
|
||||
../filters/ppt-dump.py \
|
||||
../filters/rcl7z \
|
||||
../filters/rcl7z.py \
|
||||
../filters/rclaptosidman \
|
||||
../filters/rclaudio \
|
||||
../filters/rclaudio.py \
|
||||
../filters/rclbasehandler.py \
|
||||
../filters/rclbibtex.sh \
|
||||
../filters/rclcheckneedretry.sh \
|
||||
../filters/rclchm \
|
||||
../filters/rcldia \
|
||||
../filters/rclchm.py \
|
||||
../filters/rcldia.py \
|
||||
../filters/rcldjvu.py \
|
||||
../filters/rcldoc.py \
|
||||
../filters/rcldvi \
|
||||
../filters/rclepub \
|
||||
../filters/rclepub1 \
|
||||
../filters/rclepub.py \
|
||||
../filters/rclepub1.py \
|
||||
../filters/rclexec1.py \
|
||||
../filters/rclexecm.py \
|
||||
../filters/rclfb2.py \
|
||||
../filters/rclgaim \
|
||||
../filters/rclgenxslt.py \
|
||||
../filters/rclhwp.py \
|
||||
../filters/rclics \
|
||||
../filters/rclics.py \
|
||||
../filters/rclimg \
|
||||
../filters/rclimg.py \
|
||||
../filters/rclinfo \
|
||||
../filters/rclkar \
|
||||
../filters/rclinfo.py \
|
||||
../filters/rclkar.py \
|
||||
../filters/rclkwd \
|
||||
../filters/rcllatinclass.py \
|
||||
../filters/rcllatinstops.zip \
|
||||
@ -250,21 +250,21 @@ mac {
|
||||
../filters/rclpst.py \
|
||||
../filters/rclpurple \
|
||||
../filters/rclpython.py \
|
||||
../filters/rclrar \
|
||||
../filters/rclrar.py \
|
||||
../filters/rclrtf.py \
|
||||
../filters/rclscribus \
|
||||
../filters/rclshowinfo \
|
||||
../filters/rcltar \
|
||||
../filters/rcltar.py \
|
||||
../filters/rcltex \
|
||||
../filters/rcltext.py \
|
||||
../filters/rcluncomp \
|
||||
../filters/rcluncomp.py \
|
||||
../filters/rclwar \
|
||||
../filters/rclwar.py \
|
||||
../filters/rclxls.py \
|
||||
../filters/rclxml.py \
|
||||
../filters/rclxmp.py \
|
||||
../filters/rclxslt.py \
|
||||
../filters/rclzip \
|
||||
../filters/rclzip.py \
|
||||
../filters/recoll-we-move-files.py \
|
||||
../filters/recollepub.zip \
|
||||
../filters/svg.xsl \
|
||||
|
||||
@ -148,25 +148,25 @@ application/vnd.sun.xml.writer.template = \
|
||||
body content.xml opendoc-body.xsl
|
||||
|
||||
#application/x-mobipocket-ebook = execm rclmobi
|
||||
#application/x-tar = execm rcltar
|
||||
#application/x-tar = execm rcltar.py
|
||||
|
||||
application/epub+zip = execm rclepub
|
||||
application/epub+zip = execm rclepub.py
|
||||
application/x-ipynb+json = exec jupyter nbconvert --to script --stdout ; mimetype = text/plain
|
||||
application/javascript = internal text/plain
|
||||
application/ogg = execm rclaudio
|
||||
application/ogg = execm rclaudio.py
|
||||
application/pdf = execm rclpdf.py
|
||||
application/postscript = exec rclps
|
||||
application/sql = internal text/plain
|
||||
application/vnd.wordperfect = exec wpd2html;mimetype=text/html
|
||||
application/x-7z-compressed = execm rcl7z
|
||||
application/x-7z-compressed = execm rcl7z.py
|
||||
application/x-abiword = internal xsltproc abiword.xsl
|
||||
application/x-awk = internal text/plain
|
||||
application/x-chm = execm rclchm
|
||||
application/x-dia-diagram = execm rcldia;mimetype=text/plain
|
||||
application/x-chm = execm rclchm.py
|
||||
application/x-dia-diagram = execm rcldia.py;mimetype=text/plain
|
||||
application/x-dvi = exec rcldvi
|
||||
application/x-flac = execm rclaudio
|
||||
application/x-flac = execm rclaudio.py
|
||||
application/x-gnote = execm rclxml.py
|
||||
application/x-gnuinfo = execm rclinfo
|
||||
application/x-gnuinfo = execm rclinfo.py
|
||||
application/x-gnumeric = internal xsltproc gnumeric.xsl
|
||||
application/x-hwp = execm rclhwp.py
|
||||
application/x-kword = exec rclkwd
|
||||
@ -175,22 +175,22 @@ application/x-mimehtml = internal message/rfc822
|
||||
application/x-okular-notes = internal xsltproc okular-note.xsl
|
||||
application/x-perl = internal text/plain
|
||||
application/x-php = internal text/plain
|
||||
application/x-rar = execm rclrar;charset=default
|
||||
application/x-rar = execm rclrar.py;charset=default
|
||||
application/x-ruby = internal text/plain
|
||||
application/x-scribus = exec rclscribus
|
||||
application/x-shellscript = internal text/plain
|
||||
application/x-tex = exec rcltex
|
||||
application/x-webarchive = execm rclwar
|
||||
application/x-webarchive = execm rclwar.py
|
||||
application/x-zerosize = internal
|
||||
application/zip = execm rclzip;charset=default
|
||||
audio/aac = execm rclaudio
|
||||
audio/ape = execm rclaudio
|
||||
audio/mp4 = execm rclaudio
|
||||
audio/mpeg = execm rclaudio
|
||||
audio/ogg = execm rclaudio
|
||||
audio/x-karaoke = execm rclkar
|
||||
audio/x-musepack = execm rclaudio
|
||||
audio/x-wavpack = execm rclaudio
|
||||
application/zip = execm rclzip.py;charset=default
|
||||
audio/aac = execm rclaudio.py
|
||||
audio/ape = execm rclaudio.py
|
||||
audio/mp4 = execm rclaudio.py
|
||||
audio/mpeg = execm rclaudio.py
|
||||
audio/ogg = execm rclaudio.py
|
||||
audio/x-karaoke = execm rclkar.py
|
||||
audio/x-musepack = execm rclaudio.py
|
||||
audio/x-wavpack = execm rclaudio.py
|
||||
image/gif = execm rclimg
|
||||
image/jp2 = execm rclimg
|
||||
image/jpeg = execm rclimg
|
||||
@ -203,7 +203,7 @@ image/x-xcf = execm rclimg
|
||||
inode/symlink = internal
|
||||
inode/x-empty = internal application/x-zerosize
|
||||
message/rfc822 = internal
|
||||
text/calendar = execm rclics;mimetype=text/plain
|
||||
text/calendar = execm rclics.py;mimetype=text/plain
|
||||
text/css = internal text/plain
|
||||
text/html = internal
|
||||
text/plain = internal
|
||||
@ -234,7 +234,7 @@ text/x-ruby = internal
|
||||
text/x-shellscript = internal text/plain
|
||||
text/x-srt = internal text/plain
|
||||
text/x-tex = exec rcltex
|
||||
video/mp4 = execm rclaudio
|
||||
video/mp4 = execm rclaudio.py
|
||||
video/x-msvideo = execm rclimg
|
||||
|
||||
|
||||
|
||||
@ -107,7 +107,7 @@
|
||||
.maff = application/zip
|
||||
.7z = application/x-7z-compressed
|
||||
|
||||
# The rcltar module can handle compressed tar formats internally so we
|
||||
# The rcltar.py module can handle compressed tar formats internally so we
|
||||
# use application/x-tar for all tar files compressed or not. Note that tar
|
||||
# file indexing is disabled by default, you'll need to copy and uncomment
|
||||
# the application/x-tar commented line from mimeconf into your personal config
|
||||
|
||||
@ -155,7 +155,7 @@ skippedPaths = /media
|
||||
# <var name="zipUseSkippedNames" type="bool">
|
||||
#
|
||||
# <brief>Use skippedNames inside Zip archives.</brief><descr>Fetched
|
||||
# directly by the rclzip handler. Skip the patterns defined by skippedNames
|
||||
# directly by the rclzip.py handler. Skip the patterns defined by skippedNames
|
||||
# inside Zip archives. Can be redefined for subdirectories.
|
||||
# See https://www.lesbonscomptes.com/recoll/faqsandhowtos/FilteringOutZipArchiveMembers.html
|
||||
# </descr></var>
|
||||
@ -206,9 +206,9 @@ skippedPaths = /media
|
||||
# redefinition for subtrees). At the moment, it only has an effect for
|
||||
# external handlers (exec and execm). The file types can be specified by
|
||||
# listing either MIME types (e.g. audio/mpeg) or handler names
|
||||
# (e.g. rclaudio).</descr>
|
||||
# (e.g. rclaudio.py).</descr>
|
||||
# </var>
|
||||
nomd5types = rclaudio
|
||||
nomd5types = rclaudio.py
|
||||
|
||||
# <var name="compressedfilemaxkbs" type="int"><brief>Size limit for compressed
|
||||
# files.</brief><descr>We need to decompress these in a
|
||||
|
||||
@ -131,36 +131,36 @@ application/vnd.sun.xml.writer.template = \
|
||||
body content.xml opendoc-body.xsl
|
||||
|
||||
#application/postscript = exec rclps
|
||||
#application/x-gnuinfo = execm python rclinfo
|
||||
#application/x-tar = execm python rcltar
|
||||
#application/x-gnuinfo = execm python rclinfo.py
|
||||
#application/x-tar = execm python rcltar.py
|
||||
|
||||
application/epub+zip = execm python rclepub
|
||||
application/epub+zip = execm python rclepub.py
|
||||
application/x-ipynb+json = execm python rclipynb.py
|
||||
application/javascript = internal text/plain
|
||||
application/ogg = execm python rclaudio
|
||||
application/ogg = execm python rclaudio.py
|
||||
application/pdf = execm python rclpdf.py
|
||||
application/sql = internal text/plain
|
||||
application/vnd.wordperfect = exec wpd/wpd2html;mimetype=text/html
|
||||
application/x-7z-compressed = execm python rcl7z
|
||||
application/x-7z-compressed = execm python rcl7z.py
|
||||
application/x-abiword = internal xsltproc abiword.xsl
|
||||
application/x-awk = internal text/plain
|
||||
application/x-chm = execm python rclchm
|
||||
application/x-dia-diagram = execm python rcldia;mimetype=text/plain
|
||||
application/x-flac = execm python rclaudio
|
||||
application/x-chm = execm python rclchm.py
|
||||
application/x-dia-diagram = execm python rcldia.py;mimetype=text/plain
|
||||
application/x-flac = execm python rclaudio.py
|
||||
application/x-gnote = execm python rclxml.py
|
||||
application/x-hwp = execm python rclhwp.py
|
||||
application/x-mimehtml = internal message/rfc822
|
||||
application/x-perl = internal text/plain
|
||||
application/x-php = internal text/plain
|
||||
application/x-rar = execm python rclrar;charset=default
|
||||
application/x-rar = execm python rclrar.py;charset=default
|
||||
application/x-shellscript = internal text/plain
|
||||
application/x-webarchive = execm python rclwar
|
||||
application/x-webarchive = execm python rclwar.py
|
||||
application/x-zerosize = internal
|
||||
application/zip = execm python rclzip;charset=default
|
||||
audio/aac = execm python rclaudio
|
||||
audio/mp4 = execm python rclaudio
|
||||
audio/mpeg = execm python rclaudio
|
||||
audio/x-karaoke = execm python rclkar
|
||||
application/zip = execm python rclzip.py;charset=default
|
||||
audio/aac = execm python rclaudio.py
|
||||
audio/mp4 = execm python rclaudio.py
|
||||
audio/mpeg = execm python rclaudio.py
|
||||
audio/x-karaoke = execm python rclkar.py
|
||||
image/gif = execm rclimg.exe
|
||||
image/jp2 = execm rclimg.exe
|
||||
image/jpeg = execm rclimg.exe
|
||||
@ -171,7 +171,7 @@ image/vnd.djvu = execm python rcldjvu.py
|
||||
inode/symlink = internal
|
||||
inode/x-empty = internal application/x-zerosize
|
||||
message/rfc822 = internal
|
||||
text/calendar = execm python rclics;mimetype=text/plain
|
||||
text/calendar = execm python rclics.py;mimetype=text/plain
|
||||
text/css = internal text/plain
|
||||
text/html = internal
|
||||
text/plain = internal
|
||||
|
||||
@ -8,4 +8,4 @@
|
||||
# values is identical.
|
||||
|
||||
[index]
|
||||
application/x-tar = execm rcltar
|
||||
application/x-tar = execm rcltar.py
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user