Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion lfric_styling.py → lfric_styling/lfric_styling.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ def lowercase_keywords(file):
with open(file, "r") as fp:
lines = fp.read()
for keyword in NEW_KEYWORDS:
# regex to check if a keyword is preceded with a '!' symbol or it matches a keyword and group each.
# regex to check if a keyword is preceded with a '!' symbol
# or if it matches a keyword and group each.
pattern = rf"((?:(?<=!)).*|(\b{re.escape(keyword.upper())}\b))"
lines = re.sub(pattern, convert_to_lower, lines, flags=re.MULTILINE)

Expand Down
File renamed without changes.
25 changes: 0 additions & 25 deletions script_updater.sh

This file was deleted.

Loading