diff --git a/src/fenrir-package/screen/linux.py b/src/fenrir-package/screen/linux.py index 4000b7ce..b2099d3e 100644 --- a/src/fenrir-package/screen/linux.py +++ b/src/fenrir-package/screen/linux.py @@ -27,6 +27,17 @@ class screen(): environment['runtime']['debug'].writeDebugOut(environment,str(e),debug.debugLevel.ERROR) return currScreen + + def getIgnoreScreens(self): + xlist = [] + try: + x = subprocess.Popen('ps a -o tty,comm | grep -e irssi | grep -v "grep -e irssi"', shell=True, stdout=subprocess.PIPE).stdout.read().decode()[:-1].split('\n') + except: + return xlist + for i in x: + if x[:3].upper() == 'TTY': + xlist.append(i[4]) + return xlist def update(self, environment, trigger='updateScreen'): newTTY = ''