-def resolveFilename(scope, base = ""):
- print "getting scope", scope, "with base", base
+def resolveFilename(scope, base = "", path_prefix = None):
+ if base[0:2] == "~/":
+ # you can only use the ~/ if we have a prefix directory
+ assert path_prefix is not None
+ base = os_path.join(path_prefix, base[2:])
+
+ # don't resolve absolute paths
+ if base[0:1] == '/':
+ return base
+