scripts: 0-pad release tags

This commit is contained in:
Patrik Oldsberg
2021-01-07 18:08:43 +01:00
parent 28b6d518eb
commit 9dfca68706
+4 -3
View File
@@ -35,9 +35,10 @@ async function main() {
const octokit = new Octokit({ auth: GITHUB_TOKEN });
const date = new Date();
const baseTagName = `release-${date.getUTCFullYear()}-${
date.getUTCMonth() + 1
}-${date.getUTCDate()}`;
const yyyy = date.getUTCFullYear();
const mm = String(date.getUTCMonth() + 1).padStart(2, '0');
const dd = String(date.getUTCDate()).padStart(2, '0');
const baseTagName = `release-${yyyy}-${mm}-${dd}`;
console.log('Requesting existing tags');