Skip to content

Instantly share code, notes, and snippets.

View rcgraves's full-sized avatar

Rich Graves rcgraves

View GitHub Profile
@rcgraves
rcgraves / set-dns.cmd
Last active June 19, 2016 12:37 — forked from n074v41l4bl34u/set-dns.cmd
set static dns for network connection using windows console cmd script
@echo off
set /a whichdns=(%RANDOM%*2/32768)+1
if %whichdns% equ 1 (
set DNS1=137.22.198.40 && set DNS2=137.22.198.41
) else (
set DNS1=137.22.198.41 && set DNS2=137.22.198.40
)
route -4 print | findstr "137.22.195.254" && set DNS1=137.22.194.250