SHTOOL-MKDIR.TMP(1)
π SHTOOL-MKDIR.TMP(1) π
ok so bestie, this is the page for shtool-mkdir, living inside the GNU Portable Shell Tool (yes, that's the manual name, that's the vibe) β¨
πΈ NAME πΈ
shtool-mkdir β the GNU shtool mkdir(1) style command π
β¨ SYNOPSIS β¨
shtool mkdir [-t|--trace] [-f|--force] [-p|--parents] [-m|--mode mode]
[-o|--owner owner] [-g|--group group] dir [dir ...]
like, that's the whole shape of it, no cap π
π¦ DESCRIPTION π¦
So this is a mkdir(1) style command, but it comes with extra options and it's smart β it knows what to do when the directory is already there, which is literally the whole reason it exists, because installation procedures need that. π
π OPTIONS π
here's everything you can hand it, bestie:
-t,--traceβ shows you the shell commands that are actually involved. it's giving behind-the-scenes. π-f,--forceβ forces it to keep going and says nothing when the directory already exists, no complaints, we move. by default it terminates with an error instead. π€-p,--parentsβ auto-creates the parent directories for you. by default it only makes the last directory in the path and just fails if the parents aren't there. π«Ά-m,--modemode β the directory mode applied to the directory, seechmod(1). if you omit mode it skips this step entirely and leaves whatever the operating system default is, which is usually based onumask(1). heads up: some directory modes need superuser privileges to be set. default is to stick with the operating system defaults. π-o,--ownerowner β the directory owner name or id applied to the directory, seechown(1). this one requires superuser privileges to execute. default is to skip the step and leave the operating system default, which is usually based on the executing uid or the parent setuid directory. π-g,--groupgroup β the directory group name or id applied to the directory, seechgrp(1). this also requires superuser privileges to execute to the fullest extent β otherwise, on most operating systems, your choice of group is limited. default is to skip the step and leave the operating system default, which is usually based on the executing gid or the parent setgid directory. π
π EXAMPLE π
here's how it looks in the wild, bestie:
# Makefile
install:
shtool mkdir -f -p -m 755 $(bindir)
shtool mkdir -f -p -m 755 $(mandir)/man1
:
π HISTORY π
The GNU shtool mkdir command was originally written for Public Domain by Noah Friedman, and then later revised by Ralf S. Engelschall <rse@engelschall.com> in 1999 so it could be included into GNU shtool. a little origin story for you π§
β SEE ALSO β
ok that's the whole page, you ate it, periodt π β¨ this was shtool 2.0.8, dated 18-Jul-2008 β mwah, go make some directories bestie ππ¦
π¦ where this page comes from
- debian bookworm: shtool 2.0.8-10 Β· GPL-2.0-or-later
- debian trixie: shtool 2.0.8-10 Β· GPL-2.0-or-later
- ubuntu jammy: shtool 2.0.8-10 Β· GPL-2.0-or-later
- ubuntu noble: shtool 2.0.8-10 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms