Update reformat-changelog.ts

This commit is contained in:
Louis Lam 2023-12-10 21:20:08 +08:00
parent a8482ec8ac
commit 80d5c685e5

View File

@ -4,16 +4,24 @@ const input = `
`;
const template = `
> [!WARNING]
>
### 🆕 New Features
### Improvements
### Improvements
### 🐞 Bug Fixes
### 🐛 Bug Fixes
### 🦎 Translation Contributions
### Security Fixes
### Others
- Other small changes, code refactoring and comment/doc updates in this repo:
Please let me know if your username is missing, if your pull request has been merged in this version, or your commit has been included in one of the pull requests.
`;
const lines = input.split("\n").filter((line) => line.trim() !== "");
@ -37,6 +45,12 @@ for (const line of lines) {
}
message = message.split("* ").pop();
console.log("-", pullRequestID, message, `(Thanks ${username})`);
let thanks = "";
if (username != "@louislam") {
thanks = `(Thanks ${username})`;
}
console.log(pullRequestID, message, thanks);
}
console.log(template);