|
@@ -22,7 +22,6 @@ const gulp = require('gulp'),
|
|
spawn = require('cross-spawn'),
|
|
spawn = require('cross-spawn'),
|
|
fs = require('fs'),
|
|
fs = require('fs'),
|
|
path = require('path'),
|
|
path = require('path'),
|
|
- YAML = require('yaml'),
|
|
|
|
yargs = require('yargs/yargs'),
|
|
yargs = require('yargs/yargs'),
|
|
cp = require('child_process'),
|
|
cp = require('child_process'),
|
|
pkg = require('./package.json'),
|
|
pkg = require('./package.json'),
|
|
@@ -73,34 +72,6 @@ if (!Array.prototype.flat) {
|
|
})
|
|
})
|
|
}
|
|
}
|
|
|
|
|
|
-/**
|
|
|
|
- * Generate CHANGELOG.md
|
|
|
|
- */
|
|
|
|
-gulp.task('changelog', (cb) => {
|
|
|
|
- const content = YAML.parse(fs.readFileSync('./src/pages/_data/changelog.yml', 'utf8')).reverse()
|
|
|
|
- let readme = `# Changelog
|
|
|
|
-
|
|
|
|
-All notable changes to this project will be documented in this file.\n`
|
|
|
|
-
|
|
|
|
- content.forEach((change) => {
|
|
|
|
- readme += `\n\n## \`${change.version}\` - ${change.date}\n\n`
|
|
|
|
-
|
|
|
|
- if (change.description) {
|
|
|
|
- readme += `**${change.description}**\n\n`
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- change.changes.forEach((line) => {
|
|
|
|
- readme += `- ${line}\n`
|
|
|
|
- })
|
|
|
|
-
|
|
|
|
- console.log(change.version);
|
|
|
|
- })
|
|
|
|
-
|
|
|
|
- fs.writeFileSync('CHANGELOG.md', readme)
|
|
|
|
-
|
|
|
|
- cb()
|
|
|
|
-})
|
|
|
|
-
|
|
|
|
/**
|
|
/**
|
|
* Check unused Jekyll partials
|
|
* Check unused Jekyll partials
|
|
*/
|
|
*/
|