Skip to content

Instantly share code, notes, and snippets.

@sagnitude
Created October 10, 2018 04:23
Show Gist options
  • Save sagnitude/a88401577fadac73c03e0bc53467a9c7 to your computer and use it in GitHub Desktop.
Save sagnitude/a88401577fadac73c03e0bc53467a9c7 to your computer and use it in GitHub Desktop.
start_jar.bat
@echo off
cd /d C:\path\to\jar
for /f "tokens=1" %%A in ('jps -ml ^| find "jarFileName.jar"') do (taskkill /F /PID %%A )
start /b "" java -jar jarFileName.jar >nohup.log 2>&1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment