forked from github/pelican
Order tag articles per date. Fix #133
This commit is contained in:
parent
086df21ce7
commit
7fc5fa0661
1 changed files with 1 additions and 0 deletions
|
|
@ -167,6 +167,7 @@ class ArticlesGenerator(Generator):
|
|||
# and subfolders after that
|
||||
tag_template = self.get_template('tag')
|
||||
for tag, articles in self.tags.items():
|
||||
articles.sort(key=attrgetter('date'), reverse=True)
|
||||
dates = [article for article in self.dates if article in articles]
|
||||
write('tag/%s.html' % tag, tag_template, self.context, tag=tag,
|
||||
articles=articles, dates=dates,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue