bgneal@12: # python startup file bgneal@12: import readline bgneal@12: import rlcompleter bgneal@12: import atexit bgneal@12: import os bgneal@12: # tab completion bgneal@12: readline.parse_and_bind('tab: complete') bgneal@12: # history file bgneal@12: histfile = os.path.join(os.environ['HOME'], '.pythonhistory') bgneal@12: try: bgneal@12: readline.read_history_file(histfile) bgneal@12: except IOError: bgneal@12: pass bgneal@12: atexit.register(readline.write_history_file, histfile) bgneal@12: del os, histfile, readline, rlcompleter