Base number of commits off of the branch on origin

This commit is contained in:
Webber 2020-05-02 15:49:08 +02:00 committed by Webber Takken
parent 5328bda08e
commit 44bde7feb9
2 changed files with 6 additions and 2 deletions

File diff suppressed because one or more lines are too long

View File

@ -199,7 +199,11 @@ export default class Versioning {
* Note: HEAD should not be used, as it may be detached, resulting in an additional count.
*/
static async getTotalNumberOfCommits() {
const numberOfCommitsAsString = await System.run('git', ['rev-list', '--count', this.branch]);
const numberOfCommitsAsString = await System.run('git', [
'rev-list',
'--count',
`origin/${this.branch}`,
]);
return Number.parseInt(numberOfCommitsAsString, 10);
}