Browse Source

chore: update changelog script (#35916)

pull/35869/head
xrkffgg 3 years ago
committed by GitHub
parent
commit
d30388915f
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 7
      scripts/print-changelog.js

7
scripts/print-changelog.js

@ -35,7 +35,7 @@ const MAINTAINERS = [
'Rustin-Liu',
'fireairforce',
'kerm1it',
'MadCcc',
'madccc',
].map(author => author.toLowerCase());
const cwd = process.cwd();
@ -47,7 +47,7 @@ function getDescription(entity) {
}
const descEle = entity.element.find('td:last');
let htmlContent = descEle.html();
htmlContent = htmlContent.replace(/<code>([^<]*)<\/code>/g, '`$1`');
htmlContent = htmlContent.replace(/<code class="notranslate">([^<]*)<\/code>/g, '`$1`');
return htmlContent.trim();
}
@ -179,6 +179,9 @@ async function printLog() {
if (str.toLowerCase().includes('fix') || str.includes('修复')) {
icon = '🐞';
}
if (str.toLowerCase().includes('feat')) {
icon = '🆕';
}
let authorText = '';
if (!MAINTAINERS.includes(author.toLowerCase())) {

Loading…
Cancel
Save