Skip to content

Commit

Permalink
Merge branch 'master' into live
Browse files Browse the repository at this point in the history
  • Loading branch information
coldino committed Nov 6, 2023
2 parents c79078d + d288a5f commit 9750f55
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ psutil = "~=5.9.0"
python_version = "3.10"

[scripts]
check = "pipenv check -i 39253 -i 39621 -i 41002 -i 50916 -i 51457"
check = "pipenv check -i 39253 -i 39621 -i 41002 -i 50916 -i 51457 -i 61416"
tests = "pytest --cov=. --cov-report=xml --no-cov-on-fail -m 'not uses_copyright_material'"
tests-nogame = "pytest --cov=. --cov-report=xml --no-cov-on-fail -m 'not uses_copyright_material and not requires_game'"
tests-nocov = "pytest -m 'not uses_copyright_material'"
Expand Down
8 changes: 6 additions & 2 deletions automate/manifest.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
from utils.log import get_logger

MANIFEST_FILENAME = '_manifest.json'
SHRINK_MOD_REGEX = r"{\n\s+(.+: .*),\n\s+(.+: .*),\n\s+(.+: .*)\n\s+}"
SHRINK_MOD_REGEX3 = r"{\n\s+(.+: .*),\n\s+(.+: .*),\n\s+(.+: .*)\n\s+}"
SHRINK_MOD_REGEX4 = r"{\n\s+(.+: .*),\n\s+(.+: .*),\n\s+(.+: .*),\n\s+(.+: .*)\n\s+}"
SHRINK_MOD_REGEX5 = r"{\n\s+(.+: .*),\n\s+(.+: .*),\n\s+(.+: .*),\n\s+(.+: .*),\n\s+(.+: .*)\n\s+}"

__all__ = [
'update_manifest',
Expand Down Expand Up @@ -39,7 +41,9 @@ def _write_manifest(filename: Path, data: Dict[str, Any]):
filename.parent.mkdir(parents=True, exist_ok=True)
with open(filename, 'wt', encoding='utf-8', newline='\n') as f:
content = json.dumps(data, indent='\t')
content = re.sub(SHRINK_MOD_REGEX, r'{ \1, \2, \3 }', content)
content = re.sub(SHRINK_MOD_REGEX3, r'{ \1, \2, \3 }', content)
content = re.sub(SHRINK_MOD_REGEX4, r'{ \1, \2, \3, \4 }', content)
content = re.sub(SHRINK_MOD_REGEX5, r'{ \1, \2, \3, \4, \5 }', content)
f.write(content)


Expand Down

0 comments on commit 9750f55

Please sign in to comment.