We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents ab58b65 + 6d80685 commit 8cad89eCopy full SHA for 8cad89e
mathicsscript/termshell.py
@@ -55,12 +55,17 @@
55
write_history_file,
56
)
57
58
+# Set up mathicsscript configuration directory
59
+CONFIGHOME = os.environ.get("XDG_CONFIG_HOME", osp.expanduser("~/.config"))
60
+CONFIGDIR = os.path.join(CONFIGHOME, "mathicsscript")
61
+os.makedirs(CONFIGDIR, exist_ok=True)
62
+
63
try:
64
HISTSIZE = int(os.environ.get("MATHICSSCRIPT_HISTSIZE", 50))
65
except:
66
HISTSIZE = 50
67
-HISTFILE = osp.expanduser("~/.mathicsscript_hist")
68
+HISTFILE = os.path.join(CONFIGDIR, "history")
69
70
RL_COMPLETER_DELIMS_WITH_BRACE = " \t\n_~!@#%^&*()-=+{]}|;:'\",<>/?"
71
RL_COMPLETER_DELIMS = " \t\n_~!@#%^&*()-=+[{]}\\|;:'\",<>/?"
0 commit comments