Skip to content

Commit 5841386

Browse files
committed
Install Fan SHIM where psutil already installed
1 parent a226d95 commit 5841386

1 file changed

Lines changed: 13 additions & 1 deletion

File tree

examples/install-service.sh

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,20 @@ else
172172
printf "rpi.gpio >= 0.7.0 already installed\n"
173173
fi
174174

175+
printf "Checking for Fan SHIM\n"
176+
python3 - > /dev/null 2>&1 <<EOF
177+
import fanshim
178+
EOF
179+
180+
if [ $? -ne 0 ]; then
181+
printf "Installing Fan SHIM\n"
182+
pip3 install fanshim
183+
else
184+
printf "Fan SHIM already installed\n"
185+
fi
186+
175187
printf "Checking for psutil\n"
176-
python3 - <<EOF
188+
python3 - > /dev/null 2>&1 <<EOF
177189
import psutil
178190
EOF
179191

0 commit comments

Comments
 (0)