Last active
July 11, 2017 08:52
-
-
Save fanthos/fcb6dbcdf50928f0540d4be68cadc01f to your computer and use it in GitHub Desktop.
hosts update
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
HOSTS="/tmp/hosts/remote1" | |
MAIN="https://raw.githubusercontent.com/racaljk/hosts/master/hosts" | |
MIRROR="https://coding.net/u/scaffrey/p/hosts/git/raw/master/hosts" | |
TEMPFILE="/tmp/hostsupdate.swp" | |
USEDBLOCKS="Android|Amazon AWS|Apkpure|Archive|Box.com|BundleStars|Cloudfront.net|Disqus|Dropbox|DuckDuckGo|Facebook|Github|Google|Gmail web|gstatic|Googleapis|Googleusercontent|imgur|Instagram|MEGA|OneDrive|pinterest|RawGit|Tor|W3schools|Wikipedia|XboxLive" | |
wget -O $TEMPFILE $MAIN | |
awk "/# (${USEDBLOCKS}) Start/,/#.+End/" $TEMPFILE > $HOSTS |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment