brain/src/dev/tools/git.md

439 B

Git

Fetch a remote branch

  • Create a local branch that tracks a remote branch
git checkout --track origin/develop

If you want to change the name of the local branch (NOT A GOOD IDEA)

git checkout --track -b gniagnia origin/develop

Ammend without editing commit message

git commit --ammend --no-edit

Copy current HEAD sha sum to clipboard

git rev-parse HEAD | xclip