basename - print the basename of a file
basename string [suffix | /pattern/]
basename prints the file component of a path. A second argument to basename is interpreted as a suffix to remove from the file. If the suffix is sandwiched between slashes, the suffix is considered a Perl regular expression, anything at the end of the string that matches is removed before printing it out.
basename does not accept any options.
The working of basename is not influenced by any environment variables.
basename has no known bugs.
This basename implementation is compliant with the IEEE Std1003.2-1992 specification, also known as POSIX.2.
This basename implementation is compatible with the OpenBSD implementation.
The /pattern/ is specific for this Perl implementation.
The Perl implementation of basename was written by Abigail, perlpowertools@abigail.be.
This program is copyright by Abigail 1999.
This program is free and open software. You may use, copy, modify, distribute and sell this program (and any modified variants) in any way you wish, provided you do not restrict others to do the same.
To install PerlPowerTools, copy and paste the appropriate command in to your terminal.
cpanm
cpanm PerlPowerTools
CPAN shell
perl -MCPAN -e shell install PerlPowerTools
For more information on module installation, please visit the detailed CPAN module installation guide.