Created
June 8, 2018 19:55
-
-
Save id4ehsan/98e0bcaf8431d09e82000ed3ab50e31b to your computer and use it in GitHub Desktop.
an implementation to add item to hosts in CMD
This file contains hidden or 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
| SET NEWLINE=^& echo. | |
| FIND /C /I "176.31.241.10" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 176.31.241.10>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "54.148.249.18" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 54.148.249.18>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "54.68.188.84" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 54.68.188.84>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "54.221.244.28" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 54.221.244.28>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "40.77.226.250" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 40.77.226.250>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "54.187.37.182" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 54.187.37.182>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "serwer2.paka-service.com" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 serwer2.paka-service.com>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "ns386119.ovh.net" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 ns386119.ovh.net>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "mirillis.pl" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 mirillis.pl>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "mirillis.eu" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 mirillis.eu>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "www.mirillis.com" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 www.mirillis.com>>%WINDIR%\system32\drivers\etc\hosts | |
| FIND /C /I "updates.mirillis.com" %WINDIR%\system32\drivers\etc\hosts | |
| IF %ERRORLEVEL% NEQ 0 ECHO %NEWLINE%^ 127.0.0.1 updates.mirillis.com>>%WINDIR%\system32\drivers\etc\hosts |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment