From 0ad66a55b35f95b44848ce80e6fefe536af006a3 Mon Sep 17 00:00:00 2001 From: Jeremy Lorelli Date: Mon, 25 Nov 2024 19:20:58 -0800 Subject: [PATCH] Add setup_rogue.fish for fish shell --- CMakeLists.txt | 4 +++- templates/setup_rogue.fish.in | 24 ++++++++++++++++++++++++ 2 files changed, 27 insertions(+), 1 deletion(-) create mode 100644 templates/setup_rogue.fish.in diff --git a/CMakeLists.txt b/CMakeLists.txt index ca4ee1cc1..775513ac8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -336,6 +336,8 @@ configure_file(${PROJECT_SOURCE_DIR}/templates/setup_rogue.csh.in ${PROJECT_BINARY_DIR}/setup_rogue.csh @ONLY) configure_file(${PROJECT_SOURCE_DIR}/templates/setup_rogue.sh.in ${PROJECT_BINARY_DIR}/setup_rogue.sh @ONLY) +configure_file(${PROJECT_SOURCE_DIR}/templates/setup_rogue.fish.in + ${PROJECT_BINARY_DIR}/setup_rogue.fish @ONLY) # Create the python install script configure_file(${PROJECT_SOURCE_DIR}/templates/setup.py.in @@ -357,7 +359,7 @@ install(FILES ${PROJECT_BINARY_DIR}/RogueConfig.cmake DESTINATION ${CMAKE_INSTAL # Copy setup files for local or custom if ((${ROGUE_INSTALL} STREQUAL "custom") OR (${ROGUE_INSTALL} STREQUAL "local")) - install(FILES ${PROJECT_BINARY_DIR}/setup_rogue.sh ${PROJECT_BINARY_DIR}/setup_rogue.csh DESTINATION ${ROGUE_DIR}) + install(FILES ${PROJECT_BINARY_DIR}/setup_rogue.sh ${PROJECT_BINARY_DIR}/setup_rogue.csh ${PROJECT_BINARY_DIR}/setup_rogue.fish DESTINATION ${ROGUE_DIR}) endif() # Install header files for non local installs diff --git a/templates/setup_rogue.fish.in b/templates/setup_rogue.fish.in new file mode 100644 index 000000000..b94be9b70 --- /dev/null +++ b/templates/setup_rogue.fish.in @@ -0,0 +1,24 @@ + +if test -z "$LD_LIBRARY_PATH" + set LD_LIBRARY_PATH "" +end + +if test -z "$PYTHONPATH" + set PYTHONPATH "" +end + +# Rogue directory +export ROGUE_DIR=@ROGUE_DIR@ +export ROGUE_VERSION=@ROGUE_VERSION@ + +# Setup python path +export PYTHONPATH={$ROGUE_DIR}/python:{$PYTHONPATH} + +# Setup library path +export LD_LIBRARY_PATH={$ROGUE_DIR}/lib:{$LD_LIBRARY_PATH} + +# PYDM environment +export PYQTDESIGNERPATH={$ROGUE_DIR}/python/pyrogue/pydm:{$PYQTDESIGNERPATH} +export PYDM_DATA_PLUGINS_PATH={$ROGUE_DIR}/python/pyrogue/pydm/data_plugins +export PYDM_TOOLS_PATH={$ROGUE_DIR}/python/pyrogue/pydm/tools +