Skip to content

Commit

Permalink
Add output fix script
Browse files Browse the repository at this point in the history
  • Loading branch information
BillHuang2001 committed Jan 25, 2025
1 parent 7153212 commit d64ff9b
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions docs/fix_output.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import polib

pattern = "Duplicate implicit target name"

if __name__ == "__main__":
po = polib.pofile("docs/source/locale/zh/LC_MESSAGES/docs.po")
i = 0
while i < len(po):
entry = po[i]
if pattern in entry.msgid:
po.remove(entry)
else:
i += 1

po.save("docs/source/locale/zh/LC_MESSAGES/docs.po")

0 comments on commit d64ff9b

Please # to comment.