Get a list of all git commits, including the lost ones

Get a list of all git commits, including the lost ones

I accidentally did some unattached commits to the repository and couldn't find them later.

Thanks to the google-oriented programming, I finally find the way to get the lost commits back ✌️

We can use git log --reflog to list all recent commits and then cherry-pick each commit to the current branch.

References: Get a list of all git commits, including the lost ones