It's often that a long path is mistyped or you get a log file entry that a path does not exist. Is there a command or shell function that navigates the path hierarchy until it finds a matching path?The command line exchange could go like this:$ ls /var/lib/my/supper/complicated/pathFile or directory not found$ fixpath /var/lib/my/supper/complicated/pathFound /var/lib/myAs a bonus feature, a similarity detection would be great:$ fixpath /var/lib/my/supper/complicated/pathFound /var/lib/myDid you mean /var/lib/my/super/complicated/path
How to find/correct error in a path
bash;zsh;directory;path