Thursday, April 25, 2024
HomeC Programmingpwd command in Linux - syntax, choices, use and instance

pwd command in Linux – syntax, choices, use and instance


pwd stands for Print Working Listing. It prints the entire absolute path of present listing you might be in.

Whereas working with Linux information and directories, you progress round from one listing to a different. Anytime if you wish to know during which listing you might be in then, pwd command tells you that.

Syntax

pwd [-LP]

The place L and P are elective choices.

Choices

Choices Description
-L Shows the logical path of present working listing. This logical path consists of the symbolic hyperlink path of present working listing.

That is the default choice, if no choices specified.

-P Shows the bodily path of present working listing after resolving symbolic hyperlinks. It reveals the complete pathname with out symbolic hyperlink of the present working listing.

Notice: When no choice is specified with the command pwd , it routinely considers -L into motion.

Examples

Allow us to attempt some enjoyable with pwd command and see the place we exist.

To know present working listing simply hit both pwd or pwd -L in any listing.

pwd or pwd -L each are equal.

Allow us to now attempt pwd with -P choice. Because it shows the bodily path of present working listing after resolving symbolic hyperlinks. Therefore we have to create a symbolic hyperlink to check.

Be happy to drop you feedback recommendations in feedback part.

Pleased coding 😉

About Bandna Paikaray

Bandna Paikaray is a trainer by career and doing MCA from IGNOU. Optimistic and enthusiastic even have eager curiosity in portray and singing, which comes within the first place for her. She take pleasure in her personal firm. She consider in being actual to your self and others additionally. She at all times admire and admire creativity. Besides this studying and writing can also be what she like essentially the most and might spend hours with out losing interest. In her views being artistic is the primary key to assume out of the field and discover increasingly.

Observe on:

RELATED ARTICLES

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Most Popular

Recent Comments