SyntaxFix
Write A Post
Hire A Developer
Questions
You can use a combination of pwd and basename. E.g.
#!/bin/bash CURRENT=`pwd` BASENAME=`basename "$CURRENT"` echo "$BASENAME" exit;