source: frontend/node_modules/tailwindcss/scripts/release-notes.js

Last change on this file was 9af201e, checked in by MBK <marija.karapandzova@…>, 11 days ago

Fix frontend appearance

  • Property mode set to 100644
File size: 673 bytes
Line 
1// Given a version, figure out what the release notes are so that we can use this to pre-fill the
2// relase notes on a GitHub release for the current version.
3
4let path = require('path')
5let fs = require('fs')
6
7let version =
8 process.argv[2] || process.env.npm_package_version || require('../package.json').version
9
10let changelog = fs.readFileSync(path.resolve(__dirname, '..', 'CHANGELOG.md'), 'utf8')
11let match = new RegExp(
12 `## \\[${version}\\] - (.*)\\n\\n([\\s\\S]*?)\\n(?:(?:##\\s)|(?:\\[))`,
13 'g'
14).exec(changelog)
15
16if (match) {
17 let [, , notes] = match
18 console.log(notes.trim())
19} else {
20 console.log(`Placeholder release notes for version: v${version}`)
21}
Note: See TracBrowser for help on using the repository browser.