splitname(1f) - [FUNIX] strip pathname into components {dir,name,basename,extension} (LICENSE:PD)
Synopsis
Description
Options
Examples
See Also
Author
License
splitname [NAME1 NAME2 ... |[ -d -b -l -e]|-help|-version]
Output each pathname broken into components directory, leaf name, basename, extensionOutput is always in the form and order
"dir" "name" "basename" "ext"
NAMES pathnames to split -d print director name -l print leaf name -b print base name sans any suffix -e print suffix extension --stdin flag to read pathnames from stdin instead of command line --help display this help and exit --version output version information and exit
Sample program executions:
splitname /usr/bin/ -> "/usr/bin" "" "" "" splitname /usr/bin -> "/usr" "bin" "" "" splitname stdio.h -> "" "studio.h" "studio" ".h"
dirname(1), basename(1), readlink(1), realpath(1)
John S. Urban
Public Domain
Nemo Release 3.1 | splitname (1) | February 23, 2025 |