28 Feb 2025

My Git workflow for managing code changes

#git

A Git workflow is a structured way to manage code changes.

Here’s my current git workflow, which makes it easier for me to navigate and understand my commits.

  • Create feature branch from base branch.
  • Commit changes regularly.
    • I often use git commit --amend --no-edit, one of my favourite git commands, to refine a commit while preserving a working state.
  • Before a pull request, I like to squash related commits to keep things tidy.
  • For feature branches, I like rebase instead of merge — it keeps commit history clean without extra merge commits.

Further Reading


Other Posts you may like

Your Git Commits Are Talking — What Are They Saying?
Move changes across repositories with git format-patch
Using git rebase for altering git timeline
Git cherry-pick
What are SSH keys?
Git for beginners