Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion ydict
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ import random
import ConfigParser
from multiprocessing import Process, Queue, Pool
import xml.etree.ElementTree as ET
import readline
import atexit


version="ydict 1.3.4"
Expand Down Expand Up @@ -382,7 +384,13 @@ if __name__ == '__main__':
elif options.listall:
wordlist()
cleanup()


histfile = os.path.join(os.path.expanduser("~"), ".ydict_hist")
try:
readline.read_history_file(histfile)
except IOError:
pass
atexit.register(readline.write_history_file, histfile)
while(1):
try:
word=raw_input("<PyDict> ")
Expand Down