So, would you prefer me to change this to use a python regexp, or is it enough as is given that we won't really ever have ../ in the path strings here (dir[0] is always the relative path from the given dir to files found recursively in it, so it can't have ../).