forked from github/pelican
Cleanup imports
This commit is contained in:
parent
b388057d66
commit
631ac1bdb3
3 changed files with 5 additions and 7 deletions
|
|
@ -27,7 +27,7 @@ from pelican.plugins._utils import get_plugin_name, load_plugins
|
|||
from pelican.readers import Readers
|
||||
from pelican.server import ComplexHTTPRequestHandler, RootedHTTPServer
|
||||
from pelican.settings import read_settings
|
||||
from pelican.utils import (wait_for_changes, clean_output_dir, maybe_pluralize)
|
||||
from pelican.utils import clean_output_dir, maybe_pluralize, wait_for_changes
|
||||
from pelican.writers import Writer
|
||||
|
||||
try:
|
||||
|
|
|
|||
|
|
@ -2,7 +2,6 @@ import locale
|
|||
import logging
|
||||
import os
|
||||
import shutil
|
||||
import time
|
||||
from datetime import timezone
|
||||
from sys import platform
|
||||
from tempfile import mkdtemp
|
||||
|
|
@ -14,7 +13,6 @@ except ModuleNotFoundError:
|
|||
|
||||
from pelican import utils
|
||||
from pelican.generators import TemplatePagesGenerator
|
||||
from pelican.readers import Readers
|
||||
from pelican.settings import read_settings
|
||||
from pelican.tests.support import (LoggedTestCase, get_article,
|
||||
locale_available, unittest)
|
||||
|
|
|
|||
|
|
@ -760,7 +760,9 @@ def order_content(content_list, order_by='slug'):
|
|||
def wait_for_changes(settings_file, reader_class, settings):
|
||||
content_path = settings.get('PATH', '')
|
||||
theme_path = settings.get('THEME', '')
|
||||
ignore_files = set(settings.get('IGNORE_FILES', []))
|
||||
ignore_files = set(
|
||||
fnmatch.translate(pattern) for pattern in settings.get('IGNORE_FILES', [])
|
||||
)
|
||||
|
||||
watching_paths = [
|
||||
settings_file,
|
||||
|
|
@ -780,9 +782,7 @@ def wait_for_changes(settings_file, reader_class, settings):
|
|||
|
||||
return next(watchfiles.watch(
|
||||
*watching_paths,
|
||||
watch_filter=watchfiles.DefaultFilter(
|
||||
ignore_entity_patterns=[fnmatch.translate(pattern) for pattern in ignore_files]
|
||||
),
|
||||
watch_filter=watchfiles.DefaultFilter(ignore_entity_patterns=ignore_files),
|
||||
rust_timeout=0
|
||||
))
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue