@echo off
tasklist /FI "IMAGENAME eq firefox.exe" 2>NUL | find /I /N "firefox.exe">NUL
if "%ERRORLEVEL%"=="0" (
curl -X POST "https://notify-api.line.me/api/notify" -H^
"Authorization: Bearer xxxxxxxxxxxxxxxxxxxxxxxxxxxx" -F "message=service firefox start"
) else (
curl -X POST "https://notify-api.line.me/api/notify" -H^
"Authorization: Bearer xxxxxxxxxxxxxxxxxxxxxxxxx" -F "message=service firefox stop"
)
exit
0 ความคิดเห็น