lua.wetgenes.path.relative_cd
Resolve path and if the path begins with the currentdir then replace that path with "./" so we may have a shorter path relative to the current dir.
path = wpath.relative_cd(path)
Note this only makes the path relative if makes sense to do so, if you always want to force the path relative to the current dir then use
path = wpath.relative( wpath.currentdir() , path )