Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/owncloud/client.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/admin
diff options
context:
space:
mode:
authorHannah von Reth <hannah.vonreth@owncloud.com>2020-04-02 12:12:02 +0300
committerHannah von Reth <vonreth@kde.org>2020-04-02 15:00:41 +0300
commit19a9c0538f237d50afa5c81836ed80570689b831 (patch)
treee777526db93b7b24f08363f5375a7b6f539fe671 /admin
parent7964e47a28411605930d81441400acdb30953c8c (diff)
Mac Package: Kill the correct process
Diffstat (limited to 'admin')
-rw-r--r--admin/osx/post_install.sh.cmake4
-rw-r--r--admin/osx/pre_install.sh.cmake8
2 files changed, 11 insertions, 1 deletions
diff --git a/admin/osx/post_install.sh.cmake b/admin/osx/post_install.sh.cmake
index dbc14eb53..9d7bd41e9 100644
--- a/admin/osx/post_install.sh.cmake
+++ b/admin/osx/post_install.sh.cmake
@@ -1,4 +1,8 @@
#!/bin/bash
+#exec > ~/owncloud-install-post.log
+#exec 2>&1
+#BASH_XTRACEFD=1
+#set -x
LOGGED_IN_USER_ID=$(id -u "${USER}")
diff --git a/admin/osx/pre_install.sh.cmake b/admin/osx/pre_install.sh.cmake
index 51809adc4..10ff4fba4 100644
--- a/admin/osx/pre_install.sh.cmake
+++ b/admin/osx/pre_install.sh.cmake
@@ -1,6 +1,12 @@
#!/bin/bash
+#exec > ~/owncloud-install-pre.log
+# exec 2>&1
+# BASH_XTRACEFD=1
+# set -x
-OC_INSTANCE=$(ps aux | grep "/Applications/@APPLICATION_EXECUTABLE@.app/Contents/MacOS/@APPLICATION_EXECUTABLE@")
+# don't grep in one line, to avaoid grepping the grep process...
+PROCESSES=$(ps aux)
+OC_INSTANCE=$(echo "${PROCESSES}" | grep "/Applications/@APPLICATION_EXECUTABLE@.app/Contents/MacOS/@APPLICATION_EXECUTABLE@")
if [[ "${OC_INSTANCE}" != "" ]]; then
kill $(echo ${OC_INSTANCE} | awk '{print $2}')