Skip to content

Commit

Permalink
ignore capitalization in filenames when filtering for the latest file (
Browse files Browse the repository at this point in the history
…#382)

Co-authored-by: konstantin <[email protected]>
  • Loading branch information
DeltaDaniel and hf-kklein authored Jul 29, 2024
1 parent 82419ad commit 466a2b3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/kohlrahbi/docxfilefinder.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@ def filter_latest_version(groups: dict[str, list[Path]]) -> list[Path]:
(
path
for path in group_items
if "KonsolidierteLesefassungmitFehlerkorrekturen" in path.name
or "AußerordentlicheVeröffentlichung" in path.name
if "konsolidiertelesefassungmitfehlerkorrekturen" in path.name.lower()
or "außerordentlicheveröffentlichung" in path.name.lower()
),
key=lambda path: (int(path.stem.split("_")[-1])),
)
Expand Down

0 comments on commit 466a2b3

Please sign in to comment.