ModelHandle/tools/optimize_svg_files.py
Viktor Kovacs 7b12df99fe Mac OS with zsh - CompressFiles never ends #66
Do not overcomplicate things, just run os.system.
2021-04-30 17:35:57 +02:00

14 lines
325 B
Python

import os
import sys
from lib import tools_lib as Tools
def Main (argv):
currentDir = os.path.dirname (os.path.abspath (__file__))
os.chdir (currentDir)
imagesPath = os.path.abspath (os.path.join ('..', 'website', 'assets', 'images'))
Tools.RunCommand ('svgo', ['-r', imagesPath])
return 0
sys.exit (Main (sys.argv))