Linux.com

Re: Four ways to extract the current directory name

Posted by: Anonymous [ip: 98.135.1.236] on November 07, 2007 05:52 AM
In a compromised system, the proper binaries ("ls", "grep", "sed", etc., and yes, even "pwd") may not be available. You may need something like "echo ${PWD##*/}" to get real, uncompromised output.

#

Return to Four ways to extract the current directory name