3 set SHARE_NAME=\\chrome-dev\chrome
5 set PATH=%SystemRoot%;%SystemRoot%\system32
8 if errorlevel 1 goto DRIVE_NOT_MAPPED
10 net use %DRIVE_LETTER% | find "%SHARE_NAME%" > nul
11 if not errorlevel 1 goto DRIVE_ALREADY_MAPPED
14 echo %DRIVE_LETTER% Drive mapped to wrong share, disconnecting..
15 net use %DRIVE_LETTER% /DELETE
19 echo %DRIVE_LETTER% Drive already mapped..
23 echo %DRIVE_LETTER% Drive not mapped..
27 echo Mapping %DRIVE_LETTER% to %SHARE_NAME%
28 net use %DRIVE_LETTER% %SHARE_NAME%