mirror of
https://github.com/modelec/Initialisation.git
synced 2026-01-19 00:07:20 +01:00
Kill the camera
This commit is contained in:
@@ -72,7 +72,8 @@ monitor_all() {
|
||||
for other_pid in "${pids[@]}"; do
|
||||
if [ "$other_pid" != "$pid" ]; then
|
||||
if ps -p $other_pid -o comm= | grep -q "camera"; then
|
||||
screen -S camera -X quit
|
||||
screen_pid=$(ps -ef | grep "SCREEN -dmS camera" | grep -v grep | awk '{print $2}')
|
||||
kill -SIGKILL $screen_pid 2>/dev/null
|
||||
continue
|
||||
fi
|
||||
kill -SIGKILL $other_pid 2>/dev/null
|
||||
|
||||
Reference in New Issue
Block a user