Skip to content

Commit

Permalink
add AYON_LOG_NO_COLORS to 1 by default
Browse files Browse the repository at this point in the history
  • Loading branch information
Joseph HENRY committed Nov 7, 2024
1 parent 0360cf7 commit 1af1d75
Showing 1 changed file with 5 additions and 12 deletions.
17 changes: 5 additions & 12 deletions client/ayon_nuke/addon.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,7 @@ class NukeAddon(AYONAddon, IHostAddon):

def add_implementation_envs(self, env, _app):
# Add requirements to NUKE_PATH
new_nuke_paths = [
os.path.join(NUKE_ROOT_DIR, "startup")
]
new_nuke_paths = [os.path.join(NUKE_ROOT_DIR, "startup")]
old_nuke_path = env.get("NUKE_PATH") or ""
for path in old_nuke_path.split(os.pathsep):
if not path:
Expand Down Expand Up @@ -45,7 +43,8 @@ def add_implementation_envs(self, env, _app):

# Set default values if are not already set via settings
defaults = {
"LOGLEVEL": "DEBUG"
"LOGLEVEL": "DEBUG",
"AYON_LOG_NO_COLORS": "1",
}
for key, value in defaults.items():
if not env.get(key):
Expand All @@ -55,20 +54,14 @@ def add_implementation_envs(self, env, _app):
quick_time_path = "C:/Program Files (x86)/QuickTime/QTSystem"
if platform.system() == "windows" and os.path.exists(quick_time_path):
path_value = env.get("PATH") or ""
path_paths = [
path
for path in path_value.split(os.pathsep)
if path
]
path_paths = [path for path in path_value.split(os.pathsep) if path]
path_paths.append(quick_time_path)
env["PATH"] = os.pathsep.join(path_paths)

def get_launch_hook_paths(self, app):
if app.host_name != self.host_name:
return []
return [
os.path.join(NUKE_ROOT_DIR, "hooks")
]
return [os.path.join(NUKE_ROOT_DIR, "hooks")]

def get_workfile_extensions(self):
return [".nk"]

0 comments on commit 1af1d75

Please sign in to comment.