implemented an input abstraction
This commit is contained in:
+4
-6
@@ -3,11 +3,7 @@
|
||||
#
|
||||
# Created by Luxferre in 2025, released into public domain
|
||||
|
||||
# init the tdeck_repl input where applicable
|
||||
try:
|
||||
from tdeck_repl import input
|
||||
except:
|
||||
pass
|
||||
from deck.input import input
|
||||
|
||||
class DeckChat:
|
||||
def __init__(self, start_state={}, chat_prefix='> ', command_prefix='/', paginate=0):
|
||||
@@ -70,4 +66,6 @@ class DeckChat:
|
||||
print(output)
|
||||
if self.state is None:
|
||||
break
|
||||
except KeyboardInterrupt: break
|
||||
except (KeyboardInterrupt, EOFError):
|
||||
print()
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user