better delete after updating so we dont end up with an empty hosts file if update...
authorHannes Domschke <redacted>
Sun, 15 Nov 2015 22:23:06 +0000 (23:23 +0100)
committerHannes Domschke <redacted>
Sun, 15 Nov 2015 22:23:06 +0000 (23:23 +0100)
updateHostsFile.py

index 8047d734ec07eb147cd5754f8cd2a727b8f16c5e..9f3b642865df2e9e863146531039c44a897539b8 100755 (executable)
@@ -90,10 +90,10 @@ exclusionRegexs = []
 numberOfRules = 0
 
 def main():
-       removeOldHostsFile()
        promptForUpdate()
        promptForExclusions()
        mergeFile = createInitialFile()
+       removeOldHostsFile()
        finalFile = removeDupsAndExcl(mergeFile)
        finalizeFile(finalFile)
        updateReadme(numberOfRules)
git clone https://git.99rst.org/PROJECT