#1891 RTL update v0.10.0 (#1892)

This commit is contained in:
/rootzoll 2020-12-21 21:54:33 +01:00 committed by rootzoll
parent 10a36361ed
commit a6a5319032
2 changed files with 8 additions and 3 deletions

View File

@ -1,6 +1,6 @@
#!/bin/bash
pinnedVersion="v0.9.3"
pinnedVersion="v0.10.0"
# command info
if [ $# -eq 0 ] || [ "$1" = "-h" ] || [ "$1" = "-help" ]; then

View File

@ -24,11 +24,16 @@ if [ "$1" == "off" ]; then
# remove service paragraph
sudo sed -i "/# Hidden Service for ${service}/,/^\s*$/{d}" /etc/tor/torrc
# remove double empty lines
sudo awk 'NF > 0 {blank=0} NF == 0 {blank++} blank < 2' /etc/tor/torrc > /mnt/hdd/temp/tmp && sudo mv /mnt/hdd/temp/tmp /etc/tor/torrc
sudo cp /etc/tor/torrc /mnt/hdd/temp/tmp
sudo chmod 777 /mnt/hdd/temp/tmp
sudo awk 'NF > 0 {blank=0} NF == 0 {blank++} blank < 2' /etc/tor/torrc > /mnt/hdd/temp/tmp
sudo mv /mnt/hdd/temp/tmp /etc/tor/torrc
sudo chmod 644 /etc/tor/torrc
sudo chown bitcoin:bitcoin /etc/tor/torrc
echo "# OK service is removed - restarting TOR ..."
sudo chmod 644 /etc/tor/torrc
sudo systemctl restart tor
sleep 10
echo "# Done"