💾 Archived View for idiomdrottning.org › git-clone captured on 2022-01-08 at 13:43:02. Gemini links have been rewritten to link to archived content

View Raw

More Information

⬅️ Previous capture (2021-12-03)

➡️ Next capture (2024-02-05)

-=-=-=-=-=-=-

git clone yadda.yadda/yadda; cd yadda

I can’t believe there isn’t a flag to git clone to also cd into the newly cloned directory.

If there is please let me know. (Apparently that’s going to be unpossible since the shell is a parent process.)

Writing a shell command for it for now because if I have to type cd obvious-name one more time my hands will fall off.

gitc () { git clone "$1"; cd "`basename "$1" .git`" }

(Thanks to mhd for writing in and suggesting basename from coreutils instead of my home-made path-remover!♥)