made buildscripts running under Linux
This commit is contained in:
parent
8ef469b9f1
commit
d01953409e
@ -10,11 +10,22 @@ import subprocess
|
|||||||
Import("env")
|
Import("env")
|
||||||
Import("projenv")
|
Import("projenv")
|
||||||
|
|
||||||
# Setze die Pfade zu den Tools als Variablen
|
# Überprüfe die Betriebssystemplattform
|
||||||
html_minifier_path = os.path.join(os.getenv("APPDATA"), "npm", "html-minifier.cmd")
|
if platform.system() == "Windows":
|
||||||
uglifyjs_path = os.path.join(os.getenv("APPDATA"), "npm", "uglifyjs.cmd")
|
# Setze die Pfade zu den Tools für Windows
|
||||||
terser_path = os.path.join(os.getenv("APPDATA"), "npm", "terser.cmd")
|
html_minifier_path = os.path.join(os.getenv("APPDATA"), "npm", "html-minifier.cmd")
|
||||||
cssnano_path = os.path.join(os.getenv("APPDATA"), "npm", "cssnano.cmd")
|
uglifyjs_path = os.path.join(os.getenv("APPDATA"), "npm", "uglifyjs.cmd")
|
||||||
|
terser_path = os.path.join(os.getenv("APPDATA"), "npm", "terser.cmd")
|
||||||
|
cssnano_path = os.path.join(os.getenv("APPDATA"), "npm", "cssnano.cmd")
|
||||||
|
elif platform.system() == "Linux":
|
||||||
|
# Setze die Namen der Tools für Linux
|
||||||
|
html_minifier_path = "html-minifier"
|
||||||
|
uglifyjs_path = "uglifyjs"
|
||||||
|
terser_path = "terser"
|
||||||
|
cssnano_path = "cssnano"
|
||||||
|
else:
|
||||||
|
# Hier könntest du weitere Bedingungen für andere Betriebssysteme hinzufügen
|
||||||
|
raise Exception("Unterstütztes Betriebssystem nicht erkannt")
|
||||||
|
|
||||||
|
|
||||||
def minify_html(input_path, output_path):
|
def minify_html(input_path, output_path):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user