|
|
@@ -11,4 +11,21 @@ for path, dirs, files in os.walk(wiki_dir):
|
|
|
with open(file_path, 'r', encoding='utf8') as f:
|
|
|
text = f.read()
|
|
|
matches = re.findall(regex, text)
|
|
|
- print(f"Soubor: {file_path}\nobrazek: {matches}")
|
|
|
+ for match in matches:
|
|
|
+ print(f"Soubor: {file_path}\nobrazek: {match}")
|
|
|
+
|
|
|
+
|
|
|
+
|
|
|
+# match.split("/")[-1]
|
|
|
+# posledni vec za lomitkem
|
|
|
+
|
|
|
+# import requests
|
|
|
+#
|
|
|
+# match
|
|
|
+# 'https://paper-attachments.dropboxusercontent.com/s_24178BD4A5DAB9E5982E958D5E436EA3EE292ED76CE0CE756BCC4AC8A6171443_1711543972132_image.png'
|
|
|
+# resp = requests.get(match)
|
|
|
+# match.split("/")[-1]
|
|
|
+# 's_24178BD4A5DAB9E5982E958D5E436EA3EE292ED76CE0CE756BCC4AC8A6171443_1711543972132_image.png'
|
|
|
+# with open(match.split("/")[-1], "wb") as fp:
|
|
|
+# fp.write(resp.content)
|
|
|
+
|