From f13dfc77f852dc74e85f1c88df03c689a6e6122c Mon Sep 17 00:00:00 2001 From: Alvie Rahman Date: Wed, 1 Sep 2021 14:08:00 +0100 Subject: [PATCH] Sort browsing entries case-insensetive --- notes2web.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/notes2web.py b/notes2web.py index 7ca6b27..74c218d 100755 --- a/notes2web.py +++ b/notes2web.py @@ -302,7 +302,7 @@ def main(args): 'isdirectory': fullpath.is_dir() }) - indexentries.sort(key=lambda entry: str(entry['title'])) + indexentries.sort(key=lambda entry: str(entry['title']).lower()) indexentries.sort(key=lambda entry: entry['isdirectory'], reverse=True) html = re.sub(r'\$title\$', str(directory), INDEX_TEMPLATE_HEAD)