From 11c8e6f1c3f54ba6ca6e86df8776850a3e40b98c Mon Sep 17 00:00:00 2001 From: manu Date: Fri, 12 May 2017 09:45:32 +0200 Subject: [PATCH] catch keyboard interrupt --- shreddit/app.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/shreddit/app.py b/shreddit/app.py index d98b4c1..abfed3c 100644 --- a/shreddit/app.py +++ b/shreddit/app.py @@ -55,4 +55,8 @@ def main(): if __name__ == "__main__": - main() + try: + main() + except KeyboardInterrupt: + print("Shreddit aborted by user") + quit()