init changelog script
This commit is contained in:
@@ -25,6 +25,7 @@
|
||||
"build:bundles": "rollup -c rollup.config.js",
|
||||
"optimize": "npx babel-node ./scripts/optimizeSvgs.js --presets @babel/env",
|
||||
"addtags": "npx babel-node ./scripts/addMissingKeysToTags.js --presets @babel/env",
|
||||
"generate:changelog": "npx babel-node ./scripts/generateChangelog.js --presets @babel/env",
|
||||
"test": "jest"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
||||
29
scripts/generateChangelog.js
Normal file
29
scripts/generateChangelog.js
Normal file
@@ -0,0 +1,29 @@
|
||||
// 'https://api.github.com/repos/lucide-icons/lucide/compare/v0.13.0...master'
|
||||
import output from './tempOutput.json';
|
||||
|
||||
const iconFolderRegex = /icons\/(.*)\.svg/g;
|
||||
|
||||
const changedFiles = output.files.filter(
|
||||
({ filename }) => !filename.match(/site\/(.*)|(.*)package\.json/g),
|
||||
);
|
||||
|
||||
const addedIcons = changedFiles.filter(
|
||||
({ status, filename }) => status === 'added' && filename.match(iconFolderRegex),
|
||||
);
|
||||
|
||||
const modifiedIcons = changedFiles.filter(
|
||||
({ status, filename }) => status === 'modified' && filename.match(iconFolderRegex),
|
||||
);
|
||||
|
||||
// const addedIconsWithcommits
|
||||
// console.log(modifiedIcons);
|
||||
|
||||
const topics = {
|
||||
newIcons: 'New Icons',
|
||||
modifiedIcons: 'Modified Icons',
|
||||
codeChanges: 'Code improvements',
|
||||
docs: 'Docs',
|
||||
lucide: 'Lucide Package',
|
||||
lucideReact: 'Lucide React Package',
|
||||
lucideVue: 'Lucide Vue Package',
|
||||
};
|
||||
Reference in New Issue
Block a user