From 2cc25e8cf13f63f24ceb44346de26909ec34453c Mon Sep 17 00:00:00 2001 From: Michel Roux Date: Tue, 18 May 2021 17:08:23 +0200 Subject: [PATCH] Fix curl --- .drone.yml | 3 ++- livres_en.py | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/.drone.yml b/.drone.yml index 8fee5a5..512baa5 100644 --- a/.drone.yml +++ b/.drone.yml @@ -18,7 +18,8 @@ steps: image: debian commands: - apt-get update - - apt-get install -y --no-install-recommends calibre curl + - apt-get install -y --no-install-recommends calibre + - apt-get install -y curl - bash -x convert.sh - bash -x upload.sh environment: diff --git a/livres_en.py b/livres_en.py index 60e0f84..cc71517 100644 --- a/livres_en.py +++ b/livres_en.py @@ -42,11 +42,13 @@ for volume_tag in tags: for pagination in text.find_all('a'): pagination.decompose() - for image in text.find_all('img'): - image.decompose() for cut in text.find_all('hr'): cut.decompose() + if volume >= 7: + for image in text.find_all('img'): + image.decompose() + print(title) chapter = create_chapter_from_string(str(text), title)