From aaedaf135f73082d5af3eafc6e9181b6fd1e76bf Mon Sep 17 00:00:00 2001 From: Roy Nieterau Date: Fri, 11 Aug 2017 14:57:56 +0200 Subject: [PATCH] Support running correctly from server --- colorbleed/maya/__init__.py | 5 ----- colorbleed/maya/menu.py | 4 ---- maya_environment.bat | 5 +++++ set_environment.bat | 3 --- 4 files changed, 5 insertions(+), 12 deletions(-) diff --git a/colorbleed/maya/__init__.py b/colorbleed/maya/__init__.py index 2a28f61684..60266cef75 100644 --- a/colorbleed/maya/__init__.py +++ b/colorbleed/maya/__init__.py @@ -21,11 +21,6 @@ CREATE_PATH = os.path.join(PLUGINS_DIR, "maya", "create") def install(): - # add local pipeline library to the paths - site.addsitedir(r"P:\pipeline\dev\git\cb") - site.addsitedir(r"C:\Users\User\Documents\development\cbra") - site.addsitedir(r"C:\Users\User\Documents\development\pyblish-cb") - pyblish.register_plugin_path(PUBLISH_PATH) avalon.register_plugin_path(avalon.Loader, LOAD_PATH) avalon.register_plugin_path(avalon.Creator, CREATE_PATH) diff --git a/colorbleed/maya/menu.py b/colorbleed/maya/menu.py index a59d0310c7..de7b252554 100644 --- a/colorbleed/maya/menu.py +++ b/colorbleed/maya/menu.py @@ -10,16 +10,12 @@ import maya.cmds as cmds self = sys.modules[__name__] self._menu = "colorbleed" -# set colorbleed scripts path in environment keys -os.environ["COLORBLEED_SCRIPTS"] = "P:\pipeline\dev\git\cbMayaScripts\cbMayaScripts" - log = logging.getLogger(__name__) def deferred(): # todo: replace path with server / library path - site.addsitedir("C:\Users\User\Documents\development\scriptsmenu\python") from scriptsmenu import launchformaya import scriptsmenu.scriptsmenu as menu diff --git a/maya_environment.bat b/maya_environment.bat index efeb2d4063..ceb50bbd74 100644 --- a/maya_environment.bat +++ b/maya_environment.bat @@ -12,6 +12,11 @@ if "%CB_MAYA_SHARED%" == "" ( ) +:: For scripts menu tool +set PYTHONPATH=%CB_PIPELINE%\git\scriptsmenu;%PYTHONPATH% +set CB_SCRIPTS=%CB_PIPELINE%\git\cbMayaScripts\cbMayaScripts +set COLORBLEED_SCRIPTS=%CB_SCRIPTS% + :: Colorbleed Maya set PYTHONPATH=%CB_PIPELINE%\git\cbMayaScripts;%PYTHONPATH% set PYTHONPATH=%CB_PIPELINE%\git\inventory\python;%PYTHONPATH% diff --git a/set_environment.bat b/set_environment.bat index 832d1de1d5..6af25d9d6a 100644 --- a/set_environment.bat +++ b/set_environment.bat @@ -14,8 +14,6 @@ if "%CB_APP_SHARED%" == "" ( echo setting STORAGE.. set STORAGE=P: -set LAUNCHER_ROOT=%~dp0/launchers - :: Core echo Add cb core.. set PYTHONPATH=%CB_PIPELINE%\git\cb;%PYTHONPATH% @@ -25,7 +23,6 @@ set PYTHONPATH=%CB_PIPELINE%\git\cbra;%PYTHONPATH% set PYTHONPATH=%CB_PIPELINE%\git\pyseq;%PYTHONPATH% set PYTHONPATH=%CB_PIPELINE%\git\Qt.py;%PYTHONPATH% - :: Ftrack-connect ::set PYTHONPATH=%CB_PIPELINE%\git\ftrack-connect\source;%PYTHONPATH%