Useful Everyday Tips

View saved

Check status constantly

Before you add, commit, switch, merge, or pull, run status. It is the quickest way to see where you are.

git status

Write commits for humans

  • One logical change per commit when practical
  • Messages that explain why, not only what
  • Short subject line, optional body for detail
  • No generated clutter or secrets in the snapshot

Use short aliases thoughtfully

Optional aliases can save typing once the underlying commands are familiar.

git config --global alias.st "status"
git config --global alias.lg "log --oneline --graph --decorate"
git st
git lg

Keep a simple daily loop

For most beginner projects: update main, create a branch, commit often, push, open a pull request, and merge after review.

git switch main
git pull
git switch -c feature/my-change
# work, commit, push, open PR on GitHub

Comments

One comment per signed-in account. Comments are saved with this page’s URL.