The count of commits in unshallowed copy should always match the actual number of commits in the master repository, so the is no need for workarounds. Signed-off-by: Przemo Firszt <przemo@firszt.eu>
5 lines
108 B
Plaintext
5 lines
108 B
Plaintext
function git_commits_no {
|
|
commits=$(git fetch --unshallow && git rev-list master --count)
|
|
echo $commits
|
|
}
|