Merge pull request #5764 from lhchavez/cgraph-needs-refresh commit-graph: Introduce `git_commit_graph_needs_refresh()`