From f58ad9590cf67a7f07199247ddae804d3c6b88af Mon Sep 17 00:00:00 2001 From: moshferatu Date: Sun, 22 Oct 2023 14:49:51 -0700 Subject: [PATCH] Batch script for launching Komorebi window manager at startup --- komorebi.bat | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 komorebi.bat diff --git a/komorebi.bat b/komorebi.bat new file mode 100644 index 0000000..8b5b19e --- /dev/null +++ b/komorebi.bat @@ -0,0 +1,19 @@ +@echo off +SETLOCAL EnableDelayedExpansion + +:: List of processes to check +set processesToKill=komorebi.exe whkd.exe + +:: Loop through each process in the list +for %%A in (%processesToKill%) do ( + :: Check if the process is running + tasklist /FI "IMAGENAME eq %%A" 2>NUL | find /I /N "%%A" >NUL + if "!errorlevel!"=="0" ( + echo Killing process: %%A + taskkill /F /IM %%A + ) else ( + echo Process not running: %%A + ) +) + +komorebic start -c %USERPROFILE%\komorebi.json --whkd \ No newline at end of file