Most file systems do not work in a fashion similar to S3 block storage, making the automatic generation of what appears to be a fully-qualified path an automagical process. Generally, to do what you are attempting to do, a person would perform these actions:
mkdir parent
mkdir parent/child
However, if you insist on doing this as a one-liner, you can try this:
mkdir -p ~/{parent/{child}}
What’s nice about this is that you can create multiple directories pretty much simultaneously:
mkdir -p ~/{parent/{child1,child2,child3},uncle,aunt,Morty}
This will give you lots of directories all at once, so long as you remember -p
and the curly brackets 👍🏻
root_squash
or similar?