2
0
mirror of https://github.com/tenrok/axios.git synced 2026-06-05 16:42:32 +03:00

chore(ci): fixed release notification action; (#6063)

This commit is contained in:
Dmitriy Mozgovoy
2023-11-08 20:14:12 +02:00
committed by GitHub
parent f6d2cf9763
commit 7144f10dc5
7 changed files with 87 additions and 19 deletions
+12
View File
@@ -105,6 +105,18 @@ export default class GithubAPI {
} catch (e) {
}
}
static async getLatestTag() {
try{
const {stdout} = await exec(`git for-each-ref refs/tags --sort=-taggerdate --format='%(refname)' --count=1`);
return stdout.split('/').pop();
} catch (e) {}
}
static normalizeTag(tag){
return tag ? 'v' + tag.replace(/^v/, '') : '';
}
}
const {prototype} = GithubAPI;