Skip to content

Commit

Permalink
Update validation to check for invalid translation files (#542)
Browse files Browse the repository at this point in the history
  • Loading branch information
rcalixte authored Oct 8, 2024
1 parent ac2485b commit a1d0e2a
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions validate-spice
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,11 @@ def validate_xlet(uuid):
if len(glob.glob("files/*/po/*.pot")) > 1:
raise CheckError(f"[{uuid}] Too many .pot files!")

# Check if there are any improperly named file(s)
for file in glob.glob("files/*/po/*"):
if not (file.endswith(".po") or file.endswith(".pot")):
raise CheckError(f"[{uuid}] Invalid file found in translation directory: {file}")

# Check forbidden .nemo_action.in format
keyfile = GLib.KeyFile.new()
try:
Expand Down

0 comments on commit a1d0e2a

Please sign in to comment.