From a070d356e3c57dff7df9fffcea0ec98cdc7ae2f3 Mon Sep 17 00:00:00 2001 From: jvoisin Date: Tue, 30 Aug 2011 18:36:08 +0200 Subject: oups, forgot to add this file to the previous commit ! --- mat/mat.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/mat/mat.py b/mat/mat.py index 50bb971..eb71fc7 100644 --- a/mat/mat.py +++ b/mat/mat.py @@ -54,6 +54,7 @@ except ImportError: print('Unable to import python-mutagen: limited audio format support') try: + #FIXME : WIP subprocess.Popen('exiftool_', stdout=open('/dev/null')) import exiftool #STRIPPERS['image/jpeg'] = exiftool.JpegStripper @@ -64,6 +65,17 @@ except: STRIPPERS['image/png'] = images.PngStripper +def get_sharedir(): + ''' + An ugly hack to find where is the "FORMATS" file. + Blame intrigeri. + ''' + if os.path.isfile('FORMATS'): + return '' + elif os.path.exist('/usr/local/share/mat/'): + return '/usr/local/share/mat/' + + class XMLParser(xml.sax.handler.ContentHandler): ''' Parse the supported format xml, and return a corresponding -- cgit v1.3