forked from github/pelican
... and add a way to deactivate it.
This commit is contained in:
parent
7dc847f5b2
commit
4c85555d33
2 changed files with 2 additions and 2 deletions
|
|
@ -73,8 +73,7 @@ class ArticlesProcessor(Processor):
|
|||
if category != '':
|
||||
metadatas['category'] = unicode(category)
|
||||
|
||||
# fallback on filesystem date
|
||||
if 'date' not in metadatas.keys():
|
||||
if 'date' not in metadatas.keys() and context['FALLBACK_ON_FS_DATE']:
|
||||
metadatas['date'] = datetime.fromtimestamp(os.stat(f).st_ctime)
|
||||
|
||||
article = Article(content, metadatas, settings=generator.settings,
|
||||
|
|
|
|||
|
|
@ -13,6 +13,7 @@ _DEFAULT_CONFIG = {'PATH': None,
|
|||
'DISPLAY_PAGES_ON_MENU': True,
|
||||
'PDF_PROCESSOR': False,
|
||||
'DEFAULT_CATEGORY': 'misc',
|
||||
'FALLBACK_ON_FS_DATE': True,
|
||||
}
|
||||
|
||||
def read_settings(filename):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue