Fix setup entries for i18n files for minimal packages
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
"""
|
"""
|
||||||
Dummy Qt Translation File
|
Qt Base Translation File
|
||||||
=========================
|
========================
|
||||||
|
|
||||||
This file causes Qt Linguist to generate translation entries for the Qt
|
This file causes Qt Linguist to generate translation entries for the Qt
|
||||||
elements that need translation in novelWriter for those languages who do
|
elements that need translation in novelWriter for those languages who do
|
||||||
+1
-1
@@ -1,5 +1,5 @@
|
|||||||
SOURCES += \
|
SOURCES += \
|
||||||
i18n/dummy_qtbase.py \
|
i18n/qtbase.py \
|
||||||
nw/core/document.py \
|
nw/core/document.py \
|
||||||
nw/core/project.py \
|
nw/core/project.py \
|
||||||
nw/core/tokenizer.py \
|
nw/core/tokenizer.py \
|
||||||
|
|||||||
@@ -371,6 +371,7 @@ def makeMinimalPackage(targetOS):
|
|||||||
with ZipFile(outFile, "w", compression=ZIP_DEFLATED, compresslevel=9) as zipObj:
|
with ZipFile(outFile, "w", compression=ZIP_DEFLATED, compresslevel=9) as zipObj:
|
||||||
|
|
||||||
if targetOS != OS_WIN:
|
if targetOS != OS_WIN:
|
||||||
|
# Not needed for Windows as the icons are in nw/assets/icons
|
||||||
for nRoot, _, nFiles in os.walk("setup"):
|
for nRoot, _, nFiles in os.walk("setup"):
|
||||||
print("Adding Folder: %s [%d files]" % (nRoot, len(nFiles)))
|
print("Adding Folder: %s [%d files]" % (nRoot, len(nFiles)))
|
||||||
for aFile in nFiles:
|
for aFile in nFiles:
|
||||||
@@ -388,15 +389,6 @@ def makeMinimalPackage(targetOS):
|
|||||||
continue
|
continue
|
||||||
zipObj.write(os.path.join(nRoot, aFile))
|
zipObj.write(os.path.join(nRoot, aFile))
|
||||||
|
|
||||||
for aFile in os.listdir("i18n"):
|
|
||||||
i18File = os.path.join("i18n", aFile)
|
|
||||||
if not os.path.isfile(i18File):
|
|
||||||
continue
|
|
||||||
|
|
||||||
if i18File.endswith((".json", ".qm")):
|
|
||||||
zipObj.write(i18File)
|
|
||||||
print("Adding File: %s" % i18File)
|
|
||||||
|
|
||||||
if targetOS == OS_WIN:
|
if targetOS == OS_WIN:
|
||||||
zipObj.write("novelWriter.py", "novelWriter.pyw")
|
zipObj.write("novelWriter.py", "novelWriter.pyw")
|
||||||
print("Adding File: novelWriter.pyw")
|
print("Adding File: novelWriter.pyw")
|
||||||
@@ -409,7 +401,6 @@ def makeMinimalPackage(targetOS):
|
|||||||
print("Adding File: novelWriter.py")
|
print("Adding File: novelWriter.py")
|
||||||
|
|
||||||
for aFile in rootFiles:
|
for aFile in rootFiles:
|
||||||
assert os.path.isfile(aFile)
|
|
||||||
print("Adding File: %s" % aFile)
|
print("Adding File: %s" % aFile)
|
||||||
zipObj.write(aFile)
|
zipObj.write(aFile)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user