commit 9ef0def38ffba33c9838a6147dc5abe0a4d6bdcc
parent b77b41759991dfd335cdf7ab809713ee2c59e209
Author: Pablo Cárdenas <pablo.cardenas@imca.edu.pe>
Date: Wed, 11 May 2022 19:01:57 -0500
Ensure directory exists for python history
Diffstat:
1 file changed, 2 insertions(+), 0 deletions(-)
diff --git a/linux/.config/python/pythonstartup.py b/linux/.config/python/pythonstartup.py
@@ -7,6 +7,8 @@ history = os.path.join(
"python",
"python_history",
)
+os.makedirs(os.path.dirname(history), exist_ok=True)
+
try:
readline.read_history_file(history)
except OSError: