mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Add option to stringtablediag to only show markdown
This commit is contained in:
parent
41761bc196
commit
24505f59e1
@ -57,12 +57,14 @@ def main():
|
||||
projectpath = os.path.dirname(os.path.dirname(scriptpath))
|
||||
projectpath = os.path.join(projectpath, "addons")
|
||||
|
||||
if "--markdown" not in sys.argv:
|
||||
print("#########################")
|
||||
print("# Stringtable Diag Tool #")
|
||||
print("#########################")
|
||||
|
||||
languages = get_all_languages(projectpath)
|
||||
|
||||
if "--markdown" not in sys.argv:
|
||||
print("\nLanguages present in the repo:")
|
||||
print(", ".join(languages))
|
||||
|
||||
@ -76,19 +78,21 @@ def main():
|
||||
if keynumber == 0:
|
||||
continue
|
||||
|
||||
if "--markdown" not in sys.argv:
|
||||
print("\n# " + module)
|
||||
|
||||
keysum += keynumber
|
||||
for i in range(len(localized)):
|
||||
if "--markdown" not in sys.argv:
|
||||
print(" %s %s / %i" % ((languages[i]+":").ljust(10), str(localized[i]).ljust(3), keynumber))
|
||||
localizedsum[i] += localized[i]
|
||||
if localized[i] < keynumber:
|
||||
missing[i].append(module)
|
||||
|
||||
if "--markdown" not in sys.argv:
|
||||
print("\n###########")
|
||||
print("# RESULTS #")
|
||||
print("###########")
|
||||
|
||||
print("\nTotal number of keys: %i\n" % (keysum))
|
||||
|
||||
for i in range(len(languages)):
|
||||
@ -98,9 +102,9 @@ def main():
|
||||
print("%s %s missing stringtable entry/entries." % ((languages[i] + ":").ljust(12), str(keysum - localizedsum[i]).rjust(4)), end="")
|
||||
print(" ("+", ".join(missing[i])+")")
|
||||
|
||||
print("\n\n### MARKDOWN ###")
|
||||
print("\n\n### MARKDOWN ###\n")
|
||||
|
||||
print("\nTotal number of keys: %i\n" % (keysum))
|
||||
print("Total number of keys: %i\n" % (keysum))
|
||||
|
||||
print("| Language | Missing Entries | Relevant Modules | % done |")
|
||||
print("|----------|----------------:|------------------|--------|")
|
||||
|
Loading…
Reference in New Issue
Block a user