What is Nostr?
yes, it's me, liza 🇵🇷 🦛 🦦 /
npub18x7…p6e7
2024-06-12 21:53:06

yes, it's me, liza 🇵🇷 🦛 🦦 on Nostr: #BASH NERDLETTES! am trying to understand why y'all say «mkdir -p -- "$1" && cd -- ...

#BASH NERDLETTES!
am trying to understand why y'all say «mkdir -p -- "$1" && cd -- "$1"» works.

i have something like this for creating site folders in Backdrop & Drupal multisite installations.

the scripts DO create the folders and update & copy all the files that go into them; but it bothers me that the terminal prompt never switches me into the folder.

my expectation is that "cd" moves my prompt into the new folder, not the bash process.

so is that what's happening when in a function?
Author Public Key
npub18x75k7r3stplr9jylm2eyn8jfhudvnteyv0c6u76y9hc3y37cpuqqsp6e7