Skip to content

Commit

Permalink
addon will remove its monitoring settings at uninstall
Browse files Browse the repository at this point in the history
  • Loading branch information
thkl committed May 1, 2020
1 parent e56d1bf commit 267829a
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ This RaspberryMatic / CCU3 addon will allow you to access your HomeMatic devices
All this runs on your RaspberryMatic / CCU3. You will not need any extra hardware.

# Installation
Download the addon: https://github.com/thkl/hap-homematic/raw/master/addon_installer/hap-homematic-0.0.10.tar.gz and install it via system preferences.
Download the addon: https://github.com/thkl/hap-homematic/raw/master/addon_installer/hap-homematic-0.0.11.tar.gz and install it via system preferences.

A little bit later (the addon will install all other needed software) you will have a HomeKit button in your ccu system preference page.

Expand Down
2 changes: 1 addition & 1 deletion addon_installer/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.0.10
0.0.11
Binary file removed addon_installer/hap-homematic-0.0.10.tar.gz
Binary file not shown.
Binary file added addon_installer/hap-homematic-0.0.11.tar.gz
Binary file not shown.
Binary file removed addon_installer/hap-homematic-0.0.9.tar.gz
Binary file not shown.
10 changes: 9 additions & 1 deletion addon_installer/rc.d/hap-homematic
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ HAPROOT=/usr/local/addons/hap-homematic/
CONFIG_URL=/addons/hap-homematic/index.html
CONFIG_DIR=/usr/local/etc/config
PIDFILE=/var/run/hap-homematic.pid
VER=0.0.10
VER=0.0.11
PSPID=`ps -o pid,comm,args | awk '{if ($2=="node" && $4 ~ /hap-homematic/){print $1}}'`
PSPID2=`ps -o pid,comm,args | awk '{if ($2=="hap-homematic-c"){print $1}}'`
case "$1" in
Expand Down Expand Up @@ -64,6 +64,14 @@ case "$1" in
rm /usr/local/etc/config/rc.d/hap-homematic
rm -R /usr/local/etc/config/addons/www/hap-homematic
rm -R /usr/local/etc/config/addons/hap-homematic

# remove the monit settings if there are leftovers
if [ -f /usr/local/etc/monit_hap-homematic.cfg ]; then
rm /usr/local/etc/monit_hap-homematic.cfg
# and reload the monit
/usr/bin/monit reload
fi

;;

*)
Expand Down

0 comments on commit 267829a

Please sign in to comment.