@echo off
@COLOR 2
@echo ------------切换Hosts环境---------------
:Again
@set /p choice="切换模式:A:应用环境,T:测试环境,E:退出【A,T,E】"
@if %choice% equ A goto GoA
@if %choice% equ a goto GoA
@if %choice% equ T goto GoT
@if %choice% equ t goto GoT
@if %choice% equ E goto GoExit
@if %choice% equ e goto GoExit
goto GoEnd 
:GoA
copy hostsApp /y hosts
goto GoEnd
:END

:GoT
copy hoststest /y hosts

goto GoEnd
:END

:GoEnd
@echo 切换成功
goto Again
:END

:GoError
@echo 选择错误,重新选择
goto Again
:END

:GoExit
@echo 已退出
pause;
:END

:END

 

相关文章:

  • 2021-08-10
  • 2021-12-08
猜你喜欢
  • 2021-06-08
  • 2022-03-02
相关资源
相似解决方案