[Reproducible-commits] [debbindiff] 01/01: Do not specify an extension regex for .txt files

Jérémy Bobbio lunar at moszumanska.debian.org
Sun Jan 18 22:09:04 UTC 2015


This is an automated email from the git hooks/post-receive script.

lunar pushed a commit to branch master
in repository debbindiff.

commit 8eaf99a7448655e5bde59f90a0b182541fcd702b
Author: Jérémy Bobbio <lunar at debian.org>
Date:   Sun Jan 18 22:08:14 2015 +0000

    Do not specify an extension regex for .txt files
    
    To compare text files we need to know the encoding. So we need
    to rely solely on libmagic and not match the extension.
---
 debbindiff/comparators/__init__.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/debbindiff/comparators/__init__.py b/debbindiff/comparators/__init__.py
index 11d20bc..11a6654 100644
--- a/debbindiff/comparators/__init__.py
+++ b/debbindiff/comparators/__init__.py
@@ -81,7 +81,7 @@ COMPARATORS = [
     (r'^application/(x-font-ttf|vnd.ms-opentype)(;|$)', r'\.(ttf|otf)$', compare_ttf_files),
     (r'^image/png(;|$)', r'\.png$', compare_png_files),
     (r'^application/pdf(;|$)', r'\.pdf$', compare_pdf_files),
-    (r'^text/plain; charset=(?P<encoding>[a-z0-9-]+)$', r'\.txt$', compare_text_files),
+    (r'^text/plain; charset=(?P<encoding>[a-z0-9-]+)$', None, compare_text_files),
     (None, r'\.a$', compare_static_lib_files),
     ]
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/debbindiff.git



More information about the Reproducible-commits mailing list