TIL – Find the git commit that deleted a file in a git repository

The below command filters commits that deleted file using diff-filter from git log git log --diff-filter=D -- deleted_file.example It takes advantage of the flag diff-filter.

TIL – Renaming a Git Branch

To rename a git branch locally type the following: git branch -m <new_branch_name> Example of renaming a local git branch Let's say we had a branch `patch_stikcynavbar` and we want to fix the spelling then we just type: git checkout patch_stikcynavbar git branch -m patch_stickynavbar Example of renaming a remote git branch First, we rename…