How to get relative path from two absolute paths in linux shell?
- by Zebooka
We have two paths. First one is directory, second either dir or file.
/a/b/c and /a/d/e.txt
Relative path from first path to second will be:
../../d/e.txt
How to get it in linux terminal?
PS: For those who ask "what is use case?" - creating lots of relative symlinks (just as an example)