Skip to content

Commit

Permalink
Do not persist messages across generation sessions
Browse files Browse the repository at this point in the history
  • Loading branch information
DarkFenX committed Oct 27, 2020
1 parent 566c87f commit da78c24
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
1 change: 1 addition & 0 deletions scripts/compile_lang.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,5 @@
if not os.path.isfile(name):
path = os.path.join(locale_path, name, 'LC_MESSAGES', 'lang')
sys.argv[1:] = [path + '.po']
msgfmt.reset()
msgfmt.main()
6 changes: 6 additions & 0 deletions scripts/msgfmt.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,12 @@ def generate():
return output


def reset():
"Reset module state."
global MESSAGES
MESSAGES.clear()


def make(filename, outfile):
ID = 1
STR = 2
Expand Down

0 comments on commit da78c24

Please sign in to comment.