Skip to content

Commit

Permalink
Improve second latest tag command
Browse files Browse the repository at this point in the history
  • Loading branch information
webpro committed Aug 11, 2021
1 parent 2fc0e94 commit 21cca12
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/plugin/GitBase.js
Expand Up @@ -99,7 +99,7 @@ class GitBase extends Plugin {
const sha = await this.exec(`git rev-list ${latestTag || '--skip=1'} --tags --max-count=1`, {
options
});
return this.exec(`git describe --tags --abbrev=0 ${sha}`, { options }).catch(() => null);
return this.exec(`git describe --tags --abbrev=0 ${sha}^`, { options }).catch(() => null);
}
}

Expand Down

0 comments on commit 21cca12

Please sign in to comment.