SHTOOL-MKDIR.TMP(1)

πŸ“¦
version 2.0.8 Β· 3 versions
, in debian bookworm, debian trixie, ubuntu jammy, ubuntu noble

πŸ’– 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, --mode mode β€” the directory mode applied to the directory, see chmod(1). if you omit mode it skips this step entirely and leaves whatever the operating system default is, which is usually based on umask(1). heads up: some directory modes need superuser privileges to be set. default is to stick with the operating system defaults. πŸ”
  • -o, --owner owner β€” the directory owner name or id applied to the directory, see chown(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, --group group β€” the directory group name or id applied to the directory, see chgrp(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