git log certain commit code example Example: git get latest log output to file git log --oneline -50 > log50_latest_commits.txt