shortens the passed path to a short, but unambiguous, path