From 70fbb7079eb731e281a556d2ece02fd9d8bd077e Mon Sep 17 00:00:00 2001 From: Dilawar Singh <dilawars@ncbs.res.in> Date: Sat, 15 Apr 2017 14:29:02 +0530 Subject: [PATCH] launched script is now snap friendly. --- CMakeLists.txt | 4 +++- cmake/moose.in | 5 ----- moose | 6 ++++++ 3 files changed, 9 insertions(+), 6 deletions(-) delete mode 100755 cmake/moose.in create mode 100755 moose diff --git a/CMakeLists.txt b/CMakeLists.txt index f073f747..2ee89792 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -85,7 +85,9 @@ install(DIRECTORY ${MOOSE_EXAMPLE_DIR}/ PATTERN "*.pyc" EXCLUDE ) -configure_file( ${CMAKE_SOURCE_DIR}/cmake/moose.in ${CMAKE_BINARY_DIR}/moose ) +# Copy the command to launch moose. +file(COPY ${CMAKE_SOURCE_DIR}/moose DESTINATION ${CMAKE_BINARY_DIR}) + install(PROGRAMS ${CMAKE_BINARY_DIR}/moose DESTINATION bin) ## UNINSTALL diff --git a/cmake/moose.in b/cmake/moose.in deleted file mode 100755 index c1c5872d..00000000 --- a/cmake/moose.in +++ /dev/null @@ -1,5 +0,0 @@ -#!/usr/bin/env bash - -( - cd @CMAKE_INSTALL_PREFIX@/lib/moose && python mgui.py & -) diff --git a/moose b/moose new file mode 100755 index 00000000..05814377 --- /dev/null +++ b/moose @@ -0,0 +1,6 @@ +#!/usr/bin/env bash +SCRIPT_DIR="$(dirname "${BASH_SOURCE[0]}")" +( + # Get the current path of script. + cd $SCRIPT_DIR/../lib/moose/gui && python mgui.py & +) -- GitLab