Config: Add more XDG base directories

This commit is contained in:
Riyyi
2022-08-12 13:57:00 +02:00
parent a4bf47770c
commit 82171e6684
2 changed files with 35 additions and 2 deletions
+19
View File
@@ -0,0 +1,19 @@
# -*- python -*-
import os
import atexit
import readline
history = os.path.join(os.environ['XDG_CACHE_HOME'], 'python_history')
try:
readline.read_history_file(history)
except OSError:
pass
def write_history():
try:
readline.write_history_file(history)
except OSError:
pass
atexit.register(write_history)