+49 (0) 89 2154 7447
Provenexpert
★★★★★
Google
★★★★★

How to get full file path Linux? Get the absolute path of a file?

In this tutorial, we will guide you about how to get the Absolute Path of a File in the Linux Operating System and How to get full file path Linux.

Readlink linux command to get full file path Linux:

readlink command in Linux is used to print resolved symbolic links or canonical file names. Whenever we have a symbolic link and we want to know what full path it refers to. You could use the readlink command to display the actual path of the symbolic link.

Print value of a symbolic link or canonical file name.

Syntax:

readlink [OPTION]... FILE...
OPTION:
  -f, --canonicalize            canonicalize by following every symlink in
                                every component of the given name recursively;
                                all but the last component must exist
  -e, --canonicalize-existing   canonicalize by following every symlink in
                                every component of the given name recursively,
                                all components must exist
  -m, --canonicalize-missing    canonicalize by following every symlink in
                                every component of the given name recursively,
                                without requirements on components existence
  -n, --no-newline              do not output the trailing delimiter
  -q, --quiet
  -s, --silent                  suppress most error messages (on by default)
  -v, --verbose                 report error messages
  -z, --zero                    end each output line with NUL, not newline
      --help     display this help and exit
      --version  output version information and exit

Example

readlink -f myfile.txt

Output

/home/user/dos2021/myfile.txt

More from our latest blogs

Magento Product Preview Plugin

Product preview extension for Magento 2 is built to display a preview for the product

News Vaid Ali May 7, 2021

Magento Cross Selling Plugin

Cross-Selling extension from BrandCrock recommends products to customers complimenting their purchases. This extension allows shop

News Vaid Ali May 6, 2021

Shopware 6 Plugin BigBuy Dropshipping Shopware Connector

Synchronize your E-Commerce with the BigBuy catalogs for Shopware. If you want to automatically synchronize

News Vaid Ali Apr 1, 2021

Magento Promo Banners Plugin

Promo banners extension from BrandCrock provides 15 patterns to customize and display promotional banners to

News Alan Bradford Mar 22, 2021
1 23 24 25 26 27 43
Scroll to Top