the before_app_launch hook is located in the tk-multi-launchapp shotgun app,
I have no idea how your shotgun config is setup… but generally speaking… you will have a shotgun project with the following folders inside cache, config, install… if you don’t have a central install for all your apps also known as a shared_install which is no longer the default then your current shotgun installed apps will be located inside the “install” folder.
go inside that folder, and double click on “tk-multi-launchapp”, inside there you will see a version folder (the current installed version), inside that folder you will see a “hooks” folder, go in there and you will see “before_app_launch” DONT EDIT THAT .py FILE!
so… thats where its located… but now you need to make a lot of decisions…I strongly suggest you start reading:
Administrating Hooks
tk-multi-launchapp
There are several embedded links on that page that also highlight hook editing, and managing your project configs.
The general goal is you will copy that before_launch_app hook into your project “@configRoot/configs/hooks/” under a “tk-multi-launchapp” that will need to be created, then inside “@configRoot/env/includes” you will see a “app_launchers_yml” inside there you can define the new location for your “before_launch_app” hook for each piece of software you want to set ENV variables for.
If you are using the new config_default2 it looks like these hook locations are set inside “@configRoot/env/includes/settings” and then there will be a “.yml” called “tk-multi-launchapp.yml”
ConfigDefault2
Example from config_default:
app_launchers_yml:
These are what the settings look like by default.
launch_maya:
defer_keyword: ‘’
engine: tk-maya
extra: {}
hook_app_launch: default
hook_before_app_launch: default
icon: ‘{target_engine}/icon_256.png’
linux_args: ‘’
linux_path: ‘@maya_linux’
location:
version: v0.7.6
type: app_store
name: tk-multi-launchapp
mac_args: ‘’
mac_path: ‘@maya_mac’
menu_name: Launch Maya 2015
versions:
windows_args: ‘’
windows_path: ‘@maya_windows’
you want to change
hook_before_app_launch: default
to:
assuming you have put the new before_launch_app.py into “@configRoot/hooks/tk-multi-launchapp”
“{config}/tk-multi-launchapp/before_app_launch.py”
Hope this helps… It’s a lot of information…anyone that has more info, feel free to add on :D;
-Ross