23 lines
673 B
JSON
23 lines
673 B
JSON
{
|
|
"name": "dirname",
|
|
"section": 1,
|
|
"title": "return directory portion of a pathname",
|
|
"synopsis": ["dirname [OPTION]... [OPERAND]..."],
|
|
"description": "Prints the directory portion of each path. -z emits NUL-terminated records (host stdout).",
|
|
"options": [
|
|
{ "flag": "-z, --zero", "meaning": "Separate outputs with NUL (requires process.stdout.write)" }
|
|
],
|
|
"keywords": ["dirname", "bare-os", "coreutils"],
|
|
"examples": [
|
|
{
|
|
"caption": "parent path",
|
|
"code": "dirname /a/b/c.txt"
|
|
},
|
|
{
|
|
"caption": "compose with basename",
|
|
"code": "p=/x/y/z; echo $(dirname $p)/$(basename $p)"
|
|
}
|
|
],
|
|
"listCategory": "coreutils"
|
|
}
|