add -e flag

This commit is contained in:
chrys 2018-03-25 16:20:12 +02:00
parent d2cc7192b3
commit 333ac59cc6
2 changed files with 6 additions and 1 deletions

View File

@ -40,6 +40,7 @@ class fenrirManager():
parser.add_argument('-o', '--options', metavar='SECTION#SETTING=VALUE,..', default='', help='Overwrite options in given settings file')
parser.add_argument('-d', '--debug', action='store_true', help='Turns on Debugmode')
parser.add_argument('-p', '--print', action='store_true', help='Print debug messages on screen')
parser.add_argument('-e', '--emulation', action='store_true', help='Use PTY emulation')
try:
args = parser.parse_args()
except Exception as e:

View File

@ -292,7 +292,11 @@ class settingsManager():
self.setOptionArgDict('general', 'debugLevel', 3)
if cliArgs.print:
self.setOptionArgDict('general', 'debugLevel', 3)
self.setOptionArgDict('general', 'debugMode', 'PRINT')
self.setOptionArgDict('general', 'debugMode', 'PRINT')
if cliArgs.emulation:
self.setOptionArgDict('screen', 'driver', 'ptyDriver')
self.setOptionArgDict('keyboard', 'driver', 'dummyDriver')
self.setOptionArgDict('general', 'debugFile', '/tmp/fenrir-pty.log')
self.setFenrirKeys(self.getSetting('general','fenrirKeys'))
self.setScriptKeys(self.getSetting('general','scriptKeys'))