changeset 5996:332bb015cd9e

Expand ~ in PATH before diff with environment.pickle
author Graham Percival <graham@percival-music.ca>
date Mon, 11 Oct 2010 17:46:32 +0100
parents 00328ff601cd
children 5ae0f63b2207
files bin/gub
diffstat 1 files changed, 3 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/bin/gub	Sun Aug 29 14:54:10 2010 +0200
+++ b/bin/gub	Mon Oct 11 17:46:32 2010 +0100
@@ -279,6 +279,9 @@
     environment = dict ()
     if os.path.exists (environment_file):
         environment = dict (pickle.loads (open (environment_file, 'rb').read ()))
+    # expand any ~ in the PATH
+    os.environ['PATH'] = ":".join( map( lambda(x):os.path.expanduser(x),
+                                        os.environ['PATH'].split(':')))
     differ = []
     for key in list (misc.uniq (sorted (environment.keys ()
                                         + os.environ.keys ()))):