Icons: Make blender_icons_geom_update.py support macOS

This commit is contained in:
William Reynish
2019-03-03 19:02:14 +01:00
parent 657205530c
commit 932d0ec676

View File

@@ -3,6 +3,7 @@
# This script updates icons from the BLEND file
import os
import subprocess
import sys
def run(cmd):
@@ -39,6 +40,11 @@ blender_bin = os.environ.get("BLENDER_BIN", "blender")
if not os.path.exists(blender_bin):
blender_bin = os.path.join(ROOTDIR, "blender.bin")
if sys.platform == 'darwin':
blender_app_path = '/Applications/blender.app/Contents/MacOS/blender'
if os.path.exists(blender_app_path):
blender_bin = blender_app_path
icons_blend = (
os.path.join(ROOTDIR, "..", "lib", "resources", "icon_geom.blend"),
)