Skip to content

Commit f15f40d

Browse files
committed
Use head for tags
1 parent 866f364 commit f15f40d

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

action/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/model/versioning.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,8 @@ export default class Versioning {
162162
* identifies the current commit.
163163
*/
164164
static async getVersionDescription() {
165-
return this.git(['describe', '--long', '--tags', '--always', '--debug', this.ref]);
165+
const commitIsh = (await this.getTag()) ? 'HEAD' : `origin/${this.branch}`;
166+
return this.git(['describe', '--long', '--tags', '--always', '--debug', commitIsh]);
166167
}
167168

168169
/**

0 commit comments

Comments
 (0)