RegEx update
This commit is contained in:
parent
3e602070ac
commit
2606b08393
1 changed files with 1 additions and 1 deletions
|
@ -16,7 +16,7 @@ template = '{author} -- {title} -- {year}.{ext}'
|
|||
curdir = os.getcwd()
|
||||
# Компилируем регулярку
|
||||
# https://regexr.com/5q42v
|
||||
bookregex = re.compile(r'[\[\(]*([А-Яа-я\w\s]+?)[\]\)]*[:\.\-\s]*([А-Яа-я\w\d\s]+?)[:\.\-\s]*(\d+)(?:\.(pdf|doc[x]*|epub|fb2|txt))')
|
||||
bookregex = re.compile(r'[\[\(]*([А-Яа-я\w\s]+?)[\]\)]*[:\.\-\s]*([А-Яа-я\w\d\s]+?)[:\.\-\s]*(\d+)(?:\.(pdf|doc[x]*|odf|epub|fb2|txt))')
|
||||
|
||||
# Получаем дерево каталогов и файлов в curdir
|
||||
for rootdir, subdirs, files in os.walk(curdir):
|
||||
|
|
Loading…
Reference in a new issue