DEV Community πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

Discussion on: 20 Git Commands Every Developer Should Know

Collapse
fish1 profile image
Jacob Enders

Good list!

Though I do think the 'git checkout' is a bit dated.

'git switch' is able to switch branches and it's easier to remember. It will also automatically pull remote branches if you switch to something on the remote.
git-scm.com/docs/git-switch

'git checkout' I only use to checkout a specific commit hash if I need to do that

Collapse
krishnaagarwal profile image
Krishna Agarwal Author

Thanks I'll update that.

Collapse
jessekphillips profile image
Jesse Phillips

'git checkout' I only use to checkout a specific commit hash if I need to do that

git switch --detach <hash>

Collapse
krishnaagarwal profile image
Krishna Agarwal Author

Yes
Thanks for sharing