Skip to content

Instantly share code, notes, and snippets.

@qytang326
Last active July 21, 2021 16:14
Show Gist options
  • Save qytang326/2305bf27696e188b4dba8a83814f7cee to your computer and use it in GitHub Desktop.
Save qytang326/2305bf27696e188b4dba8a83814f7cee to your computer and use it in GitHub Desktop.
Update GFW hosts and Blacklist hosts on Windows
cd C:\Windows\System32\drivers\etc
cp hosts hosts-bak
wget https://raw.githubusercontent.com/lennylxx/ipv6-hosts/master/hosts -O hosts-ipv6
#wget https://raw.githubusercontent.com/racaljk/hosts/master/hosts -O hosts-ipv4
wget https://raw.githubusercontent.com/googlehosts/hosts/master/hosts-files/hosts -O hosts-ipv4
wget https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts -O hosts-blacklist
cat hosts-other hosts-ipv4 hosts-ipv6 hosts-blacklist > hosts
#sed -i '/vidia/d' hosts
ipconfig/flushdns
echo 'end'
pause
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment