realpath needs to be included in all version of Mint

Forum rules
Before you post please read how to get help
lsatenstein
Level 1
Level 1
Posts: 16
Joined: Sat Dec 03, 2011 2:33 pm

realpath needs to be included in all version of Mint

Postby lsatenstein » Fri Jun 27, 2014 12:06 pm

Install with apt-get.

Most useful in shell scripting to resolve paths with ../ That is relative paths to real paths from /

User avatar
xenopeek
Level 23
Level 23
Posts: 19034
Joined: Wed Jul 06, 2011 3:58 am
Location: The Netherlands

Re: realpath needs to be included in all version of Mint

Postby xenopeek » Sat Jun 28, 2014 4:42 am

That similar to what readlink -f does. For example to get the canonical path of parent directory:

Code: Select all

readlink -f ../

readlink is part of coreutils, so present on all GNU/Linux distros.
Image


Return to “Scripts & Bash”

Who is online

Users browsing this forum: No registered users and 1 guest