From a56bc9e3b943afb9058897a47c23baf0f91fa808 Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Sun, 3 May 2015 01:26:26 +0300 Subject: [PATCH] Do not start the browser if it is already running Prevent browser-stack.py pop from popping the running browser. --- bin/start-browser | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bin/start-browser b/bin/start-browser index 48a1896..2f65a3a 100755 --- a/bin/start-browser +++ b/bin/start-browser @@ -1,5 +1,7 @@ #! /bin/sh +if pgrep "$1" >/dev/null; then exit 0; fi + browser-stack.py push "$@" "$@" exec browser-stack.py pop "$@" -- 2.39.5