mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-01 16:34:53 +01:00
added few basic prelaunch hooks for nuke
This commit is contained in:
parent
88316fe421
commit
b1c587ae83
3 changed files with 54 additions and 0 deletions
18
pype/hooks/hiero/pre_launch_args.py
Normal file
18
pype/hooks/hiero/pre_launch_args.py
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
from pype.lib import PreLaunchHook
|
||||
|
||||
|
||||
class HieroLaunchArguments(PreLaunchHook):
|
||||
order = 0
|
||||
|
||||
def execute(self):
|
||||
"""Prepare suprocess launch arguments for NukeX."""
|
||||
# Get executable
|
||||
executable = self.launch_context.launch_args[0]
|
||||
|
||||
if isinstance(executable, str):
|
||||
executable = [executable]
|
||||
|
||||
# Add `nukex` argument and make sure it's bind to execuable
|
||||
executable.append("--hiero")
|
||||
|
||||
self.launch_context.launch_args[0] = executable
|
||||
18
pype/hooks/nukestudio/pre_launch_args.py
Normal file
18
pype/hooks/nukestudio/pre_launch_args.py
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
from pype.lib import PreLaunchHook
|
||||
|
||||
|
||||
class NukeStudioLaunchArguments(PreLaunchHook):
|
||||
order = 0
|
||||
|
||||
def execute(self):
|
||||
"""Prepare suprocess launch arguments for NukeX."""
|
||||
# Get executable
|
||||
executable = self.launch_context.launch_args[0]
|
||||
|
||||
if isinstance(executable, str):
|
||||
executable = [executable]
|
||||
|
||||
# Add `nukex` argument and make sure it's bind to execuable
|
||||
executable.append("--studio")
|
||||
|
||||
self.launch_context.launch_args[0] = executable
|
||||
18
pype/hooks/nukex/pre_launch_args.py
Normal file
18
pype/hooks/nukex/pre_launch_args.py
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
from pype.lib import PreLaunchHook
|
||||
|
||||
|
||||
class NukeXLaunchArguments(PreLaunchHook):
|
||||
order = 0
|
||||
|
||||
def execute(self):
|
||||
"""Prepare suprocess launch arguments for NukeX."""
|
||||
# Get executable
|
||||
executable = self.launch_context.launch_args[0]
|
||||
|
||||
if isinstance(executable, str):
|
||||
executable = [executable]
|
||||
|
||||
# Add `nukex` argument and make sure it's bind to execuable
|
||||
executable.append("--nukex")
|
||||
|
||||
self.launch_context.launch_args[0] = executable
|
||||
Loading…
Add table
Add a link
Reference in a new issue