Fanger TSTP-signalet (^Z) hvis konfigurasjonen ber om det.
This commit is contained in:
parent
4cd817c70f
commit
302f5fb7fa
1
conf.py
1
conf.py
|
@ -1,3 +1,4 @@
|
|||
db_url = 'sqlite:///data'
|
||||
quit_allowed = True
|
||||
stop_allowed = False
|
||||
show_tracebacks = True
|
||||
|
|
|
@ -4,6 +4,7 @@ import sqlalchemy
|
|||
import re
|
||||
import sys
|
||||
import traceback
|
||||
import signal
|
||||
from helpers import *
|
||||
|
||||
exit_commands = ['exit', 'abort', 'quit', 'bye', 'eat flaming death']
|
||||
|
@ -682,7 +683,8 @@ def retrieve_product(search_str, session):
|
|||
return search_ui(search_product, search_str, 'product', session)
|
||||
|
||||
|
||||
#main = MainMenu()
|
||||
if not conf.stop_allowed:
|
||||
signal.signal(signal.SIGTSTP, signal.SIG_IGN)
|
||||
main = Menu('Dibbler main menu',
|
||||
items=[BuyMenu(), ProductListMenu(), ShowUserMenu(),
|
||||
AdjustCreditMenu(), TransferMenu(),
|
||||
|
|
Loading…
Reference in New Issue