Skip to content

Commit

Permalink
Allow removing fake-hwclock package and disable ntpd
Browse files Browse the repository at this point in the history
  • Loading branch information
uugear committed Aug 19, 2017
1 parent 9850c93 commit 2f76abb
Showing 1 changed file with 18 additions and 1 deletion.
19 changes: 18 additions & 1 deletion installWittyPi.sh
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ ERR=0

echo '================================================================================'
echo '| |'
echo '| Witty Pi 2 Software Installing Script |'
echo '| Witty Pi Software Installation Script |'
echo '| |'
echo '================================================================================'

Expand Down Expand Up @@ -128,6 +128,23 @@ if [ $ERR -eq 0 ]; then
fi
fi

# remove fake-hwclock and disable ntpd to improve reliability
read -p "Remove fake-hwclock package and disable ntpd daemon? (recommended) [y/n] " -n 1 -r
echo
if [[ $REPLY =~ ^[Yy]$ ]] ; then
update-rc.d fake-hwclock remove || ((ERR++))
apt-get remove -y fake-hwclock || ((ERR++))
if [ -f /etc/cron.hourly/fake-hwclock ]; then
rm /etc/cron.hourly/fake-hwclock || ((ERR++))
fi
if [ -f /etc/init.d/fake-hwclock ]; then
rm /etc/init.d/fake-hwclock || ((ERR++))
fi
update-rc.d -f ntp remove || ((ERR++))
else
echo 'Skip fake-hwclock removal and ntpd disabling.'
fi

# install Qt 5 (optional and for Jessie only)
if $isJessieOrStretch ; then
read -p "Do you want to install Qt 5 for GUI running? [y/n] " -n 1 -r
Expand Down

0 comments on commit 2f76abb

Please sign in to comment.