summaryrefslogtreecommitdiff
path: root/tests/Ktext
diff options
context:
space:
mode:
authorUlf Magnusson <ulfalizer@gmail.com>2015-06-07 16:57:46 +0200
committerUlf Magnusson <ulfalizer@gmail.com>2015-06-07 17:46:11 +0200
commitd56e9c1d4c3e6f560382ac71fa2419b2a9bef1cb (patch)
tree6f63cb1c1ed473480789a926244dad353a083694 /tests/Ktext
parent8de05809108aef5adbc9081975f530344c8bce62 (diff)
Do not require $srctree to be set for non-kernel projects.
(It was never required if you explicitly passed a 'base_dir', but it's a bit silly to have to do that too.) This is a bug. I expected os.path.expandvars() to replace references non-set environment variables with nothing, but it leaves them as is. Work around it by letting base_dir = None be special and the default. It uses $srctree if set and the current directory otherwise. This has the following advantages: - It avoids having to reimplement a different version of os.path.expandvars() and special-casing "" to mean the current directory. - It means '$' can appear in paths. (Though it probably never will.) Maybe the expansion behavior could be removed too, but keep it for now to be backwards compatible.
Diffstat (limited to 'tests/Ktext')
0 files changed, 0 insertions, 0 deletions