diff --git a/mathicsscript/__main__.py b/mathicsscript/__main__.py index 4bf37dc..051dacd 100755 --- a/mathicsscript/__main__.py +++ b/mathicsscript/__main__.py @@ -288,7 +288,9 @@ def main( definitions, style, want_readline, completion, unicode, prompt ) - load_settings(shell) + # FIXME: why does load_settings fail when execute (-e) is set? + if not execute: + load_settings(shell) if run: with open(run, "r") as ifile: feeder = MathicsFileLineFeeder(ifile) @@ -378,6 +380,7 @@ def main( TeXForm = Symbol("System`TeXForm") definitions.set_line_no(0) + while True: try: if have_readline and shell.using_readline: @@ -389,11 +392,11 @@ def main( "Settings`$ShowFullFormInput" ).replace.to_python() style = definitions.get_ownvalue("Settings`$PygmentsStyle") - fmt = lambda x: x + fmt = lambda x: x # noqa if style: style = style.replace.get_string_value() if shell.terminal_formatter: - fmt = lambda x: highlight( + fmt = lambda x: highlight( # noqa str(query), mma_lexer, shell.terminal_formatter ) diff --git a/mathicsscript/data/inputrc-no-unicode b/mathicsscript/data/inputrc-no-unicode index 23fdc01..c1cb63c 100644 --- a/mathicsscript/data/inputrc-no-unicode +++ b/mathicsscript/data/inputrc-no-unicode @@ -1,5 +1,5 @@ # GNU Readline input unicode translations -# Autogenerated from mathics_scanner.generate.rl_inputrc on Wed Oct 26 04:49:35 PM EDT 2022 +# Autogenerated from mathics_scanner.generate.rl_inputrc on Wed Oct 26 05:37:20 PM EDT 2022 "\ea'\e": "á" "\ea-\e": "ā" diff --git a/mathicsscript/data/inputrc-unicode b/mathicsscript/data/inputrc-unicode index 23fdc01..c1cb63c 100644 --- a/mathicsscript/data/inputrc-unicode +++ b/mathicsscript/data/inputrc-unicode @@ -1,5 +1,5 @@ # GNU Readline input unicode translations -# Autogenerated from mathics_scanner.generate.rl_inputrc on Wed Oct 26 04:49:35 PM EDT 2022 +# Autogenerated from mathics_scanner.generate.rl_inputrc on Wed Oct 26 05:37:20 PM EDT 2022 "\ea'\e": "á" "\ea-\e": "ā"