From a6697d29279bf0d1b96d217ce602d631791c4dc5 Mon Sep 17 00:00:00 2001 From: Sasha Koss Date: Fri, 5 Mar 2021 11:24:24 +0800 Subject: [PATCH] Add date to the changelog --- scripts/release/buildChangelog.ts | 6 +++++- tsconfig.json | 3 ++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/scripts/release/buildChangelog.ts b/scripts/release/buildChangelog.ts index 888fb608a7..64b9be0c15 100644 --- a/scripts/release/buildChangelog.ts +++ b/scripts/release/buildChangelog.ts @@ -1,6 +1,7 @@ import { fromEntries, last, sample, uniq } from 'js-fns' import sg from 'simple-git' import { Octokit } from '@octokit/core' +import format from '../../src/format' const git = sg() const gh = new Octokit({ auth: process.env.GITHUB_TOKEN }) @@ -19,7 +20,10 @@ function renderChangelog(changelog: ChangelogVersion) { (author) => author.login ) - let markdown = `## ${renderVersion(changelog.version)} + let markdown = `## ${renderVersion(changelog.version)} - ${format( + Date.now(), + 'yyyy-MM-dd' + )} ${sample(thanksOptions)!(renderAuthors(authors))}` diff --git a/tsconfig.json b/tsconfig.json index ecf0506e86..0b07ae8a47 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -14,7 +14,8 @@ "importHelpers": true, "baseUrl": ".", "allowSyntheticDefaultImports": true, - "esModuleInterop": true + "esModuleInterop": true, + "allowJs": true }, "exclude": ["node_modules", "dist", "tmp"] }