Created
June 9, 2010 05:56
-
-
Save taka2/431117 to your computer and use it in GitHub Desktop.
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
| @echo off | |
| set SERVICE_NAME=Themes | |
| REM -------------------------------------------------- | |
| REM サービスが既に起動しているかどうかチェック | |
| REM -------------------------------------------------- | |
| net start | findstr %SERVICE_NAME% | |
| if %ERRORLEVEL% == 0 goto error10 | |
| REM -------------------------------------------------- | |
| REM サービスを起動 | |
| REM -------------------------------------------------- | |
| net start %SERVICE_NAME% | |
| REM -------------------------------------------------- | |
| REM サービスが起動したかどうかチェック | |
| REM -------------------------------------------------- | |
| net start | findstr %SERVICE_NAME% | |
| if %ERRORLEVEL% == 1 goto error20 | |
| goto end | |
| :error10 | |
| exit /b 10 | |
| goto end | |
| :error20 | |
| exit /b 20 | |
| goto end | |
| :end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment