add proto_command option and use it for termine

This commit is contained in:
2021-07-15 13:20:21 +02:00
parent 808182cd21
commit 5a25cd1f4c
3 changed files with 8 additions and 0 deletions

View File

@@ -134,6 +134,9 @@ def conf2top(top):
if "command" in top:
body = subprocess.run(top["command"], shell=True, text=True, capture_output=True, check=True).stdout
if "proto_command" in top:
protostub = subprocess.run(top["proto_command"], shell=True, text=True, capture_output=True, check=True).stdout
return Top(top["title"], sender, body, protostub)
if __name__ == "__main__":