diff options
author | Philip Balister <philip@balister.org> | 2008-02-12 13:42:34 +0000 |
---|---|---|
committer | Philip Balister <philip@balister.org> | 2008-02-12 13:42:34 +0000 |
commit | 64efb6d640ada9fffcb4c98a1e4ae4f8d2bd0e9c (patch) | |
tree | c5581b96374be871d59809b2934aa791ccc5bfdf /packages/python/python-2.5.1 | |
parent | 73c9713cacf49f300e034bbb6b47df17caf29d4f (diff) | |
parent | 3168ff71a18d3bfa339f0ccdace03878ab2094f2 (diff) |
merge of '967336334b2d3b22623c9851eb0ab8a2f5ad19c2'
and 'f1ce41fae2ee4dc6bfc75fb8d991a37869ef24d8'
Diffstat (limited to 'packages/python/python-2.5.1')
-rw-r--r-- | packages/python/python-2.5.1/sitecustomize.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/packages/python/python-2.5.1/sitecustomize.py b/packages/python/python-2.5.1/sitecustomize.py index b5e78d3200..4c0ba3f0da 100644 --- a/packages/python/python-2.5.1/sitecustomize.py +++ b/packages/python/python-2.5.1/sitecustomize.py @@ -7,11 +7,11 @@ # * load command line history on startup # * save command line history on exit -HISTORY_FILENAME = "/tmp/python-history-file.txt" +import os def __exithandler(): try: - readline.write_history_file( HISTORY_FILENAME ) + readline.write_history_file( "%s/.python-history" % os.getenv( "HOME", "/tmp" ) ) except IOError: pass @@ -22,7 +22,7 @@ def __registerExitHandler(): def __enableReadlineSupport(): readline.parse_and_bind("tab: complete") try: - readline.read_history_file( "/tmp/python-history-file.txt" ) + readline.read_history_file( "%s/.python-history" % os.getenv( "HOME", "/tmp" ) ) except IOError: pass |