Add gitlab-ci
This commit is contained in:
parent
aa893e9d61
commit
e313ddb721
5
.gitlab-ci.yml
Normal file
5
.gitlab-ci.yml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
test:
|
||||||
|
script:
|
||||||
|
- apt-get update -qy
|
||||||
|
- apt-get install -qy --no-install-recommends python3-mutagen python3-gi-cairo gir1.2-poppler-0.18 gir1.2-gdkpixbuf-2.0 libimage-exiftool-perl
|
||||||
|
- python3 -m unittest discover -v
|
@ -19,7 +19,7 @@ class JPGParser(abstract.AbstractParser):
|
|||||||
|
|
||||||
def get_meta(self):
|
def get_meta(self):
|
||||||
out = subprocess.check_output(['exiftool', '-json', self.filename])
|
out = subprocess.check_output(['exiftool', '-json', self.filename])
|
||||||
meta = json.loads(out)[0]
|
meta = json.loads(out.decode('utf-8'))[0]
|
||||||
for key in self.meta_whitelist:
|
for key in self.meta_whitelist:
|
||||||
meta.pop(key, None)
|
meta.pop(key, None)
|
||||||
return meta
|
return meta
|
||||||
|
@ -16,7 +16,7 @@ class PNGParser(abstract.AbstractParser):
|
|||||||
|
|
||||||
def get_meta(self):
|
def get_meta(self):
|
||||||
out = subprocess.check_output(['exiftool', '-json', self.filename])
|
out = subprocess.check_output(['exiftool', '-json', self.filename])
|
||||||
meta = json.loads(out)[0]
|
meta = json.loads(out.decode('utf-8'))[0]
|
||||||
for key in self.meta_whitelist:
|
for key in self.meta_whitelist:
|
||||||
meta.pop(key, None)
|
meta.pop(key, None)
|
||||||
return meta
|
return meta
|
||||||
|
Loading…
Reference in New Issue
Block a user