summarylogtreecommitdiffstats
path: root/openhab4.patch
blob: 2bfdce14995053cde2814ed2d4f3c82594b3abd6 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
diff -Nur openhab4.orig/runtime/bin/oh_dir_layout openhab4.new/runtime/bin/oh_dir_layout
--- openhab4.orig/runtime/bin/oh_dir_layout	2020-11-29 18:19:58.000000000 +0100
+++ openhab4.new/runtime/bin/oh_dir_layout	2020-11-30 21:15:26.742400846 +0100
@@ -6,7 +6,7 @@
 export OPENHAB_HOME=`cd "$DIRNAME/../.."; pwd`
 
 if [ -z ${OPENHAB_CONF} ]; then
-    export OPENHAB_CONF="${OPENHAB_HOME}/conf"
+    export OPENHAB_CONF="/etc/openhab4"
 fi
 
 if [ -z ${OPENHAB_RUNTIME} ]; then
@@ -14,11 +14,11 @@
 fi
 
 if [ -z ${OPENHAB_USERDATA} ]; then
-    export OPENHAB_USERDATA="${OPENHAB_HOME}/userdata"
+    export OPENHAB_USERDATA="/var/lib/openhab4"
 fi
 
 if [ -z ${OPENHAB_LOGDIR} ]; then
-    export OPENHAB_LOGDIR="${OPENHAB_USERDATA}/logs"
+    export OPENHAB_LOGDIR="/var/log/openhab4"
 fi
 
 if [ -z ${OPENHAB_BACKUPS} ]; then
diff -Naur openhab4.orig/runtime/bin/backup openhab4.new/runtime/bin/backup
--- openhab4.orig/runtime/bin/backup	2023-09-10 04:59:10.000000000 +1000
+++ openhab4.new/runtime/bin/backup	2023-10-08 15:42:07.852539486 +1100
@@ -84,10 +84,10 @@
   }
 
   ## Set path variables
-  if [ -r /etc/profile.d/openhab.sh ]; then
-    . /etc/profile.d/openhab.sh
-  elif [ -r /etc/default/openhab ]; then
-    . /etc/default/openhab
+  if [ -r /etc/profile.d/openhab4.sh ]; then
+    . /etc/profile.d/openhab4.sh
+  elif [ -r /etc/default/openhab4 ]; then
+    . /etc/default/openhab4
   fi
 
   if [ "$bInteractive" = "0" ];then
diff -Naur openhab4.orig/runtime/bin/restore openhab4.new/runtime/bin/restore
--- openhab4.orig/runtime/bin/restore	2023-09-10 04:59:10.000000000 +1000
+++ openhab4.new/runtime/bin/restore	2023-10-08 15:42:21.468943408 +1100
@@ -68,10 +68,10 @@
   WorkingDir="$(cd "$(dirname "$0")" && cd ../.. && pwd -P)"
 
   ## Set path variables
-  if [ -r /etc/profile.d/openhab.sh ]; then
-    . /etc/profile.d/openhab.sh
-  elif [ -r /etc/default/openhab ]; then
-    . /etc/default/openhab
+  if [ -r /etc/profile.d/openhab4.sh ]; then
+    . /etc/profile.d/openhab4.sh
+  elif [ -r /etc/default/openhab4 ]; then
+    . /etc/default/openhab4
   fi
   if [ -z "$OPENHAB_CONF" ];       then OPENHAB_CONF="$WorkingDir/conf"; fi
   if [ -z "$OPENHAB_USERDATA" ];   then OPENHAB_USERDATA="$WorkingDir/userdata"; fi