From feca5738af7234aa11ac2d88e4b437e4ca1e2ba4 Mon Sep 17 00:00:00 2001 From: Gary Katsevman Date: Wed, 5 Oct 2016 16:06:13 -0400 Subject: [PATCH 1/3] prepare changelog for conventional changelog --- CHANGELOG.md | 8 -------- 1 file changed, 8 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1f7be8d359..fe0c75fabe 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,11 +1,3 @@ -CHANGELOG -========= - -## HEAD (Unreleased) -_(none)_ - --------------------- - ## 5.12.2 (2016-09-28) * Changes from 5.11.7 on the 5.12 branch From 7fc2b2fbdaf91a79304d911073e7e08d8a4a61eb Mon Sep 17 00:00:00 2001 From: Gary Katsevman Date: Wed, 5 Oct 2016 16:06:36 -0400 Subject: [PATCH 2/3] add changelog script and conventional-changelog deps --- package.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 55d58f8e01..38e514cf4a 100644 --- a/package.json +++ b/package.json @@ -16,6 +16,7 @@ "homepage": "http://videojs.com", "author": "Steve Heffernan", "scripts": { + "changelog": "conventional-changelog -p videojs -i CHANGELOG.md -s", "build": "grunt dist", "change": "grunt chg-add", "clean": "grunt clean", @@ -55,13 +56,15 @@ "browserify-versionify": "^1.0.4", "bundle-collapser": "^1.2.1", "chg": "^0.3.2", + "conventional-changelog-cli": "^1.2.0", + "conventional-changelog-videojs": "^3.0.0", "es5-shim": "^4.1.3", "es6-shim": "^0.35.1", "ghooks": "^1.3.2", "gkatsev-grunt-sass": "^1.1.1", "grunt": "^0.4.4", - "grunt-babel": "^6.0.0", "grunt-accessibility": "^4.1.0", + "grunt-babel": "^6.0.0", "grunt-banner": "^0.4.0", "grunt-browserify": "3.5.1", "grunt-cli": "~0.1.13", From 112971d264ba865771db7f4c3ce3917293976d17 Mon Sep 17 00:00:00 2001 From: Gary Katsevman Date: Wed, 5 Oct 2016 16:42:19 -0400 Subject: [PATCH 3/3] use conventional-changelog to generate the changelog --- build/grunt.js | 3 ++- contrib.json | 4 ++-- package.json | 1 + 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/build/grunt.js b/build/grunt.js index 25556b11f1..ddf86e2199 100644 --- a/build/grunt.js +++ b/build/grunt.js @@ -1,5 +1,6 @@ import {gruntCustomizer, gruntOptionsMaker} from './options-customizer.js'; import chg from 'chg'; +import nodeCli from 'shelljs-nodecli'; module.exports = function(grunt) { require('time-grunt')(grunt); @@ -31,7 +32,7 @@ module.exports = function(grunt) { release: { tag_name: 'v'+ version.full, name: version.full, - body: chg.find(version.full).changesRaw + body: nodeCli.exec('conventional-changelog', '-p videojs', {silent: true}).output }, }, files: { diff --git a/contrib.json b/contrib.json index c72c91a2d8..dbae370f86 100644 --- a/contrib.json +++ b/contrib.json @@ -280,7 +280,7 @@ [ "git checkout -b temp-release-branch master","Create a temporary branch for the dist" ], [ "grunt version:{{release_type}}", "Bump package versions" ], [ "./build/bin/version", "Return the current VJS Version from the package.json file", "version" ], - [ "grunt chg-release:{{version}}", "Update the changelog with the new release" ], + [ "npm run changelog", "Update the changelog with the new release" ], [ "git commit -am 'v{{version}}'", "Add and commit the package changes" ], [ "git checkout master", "Checkout the developmet branch" ], [ "git merge temp-release-branch", "Merge package changes into the dev brach" ], @@ -306,7 +306,7 @@ [ "grunt test", "Run tests" ], [ "grunt version:{{release_type}}", "Bump package versions" ], [ "./build/bin/version", "Return the current VJS Version from the package.json file", "version" ], - [ "grunt chg-release:{{version}}", "Update the changelog with the new release" ], + [ "npm run changelog", "Update the changelog with the new release" ], [ "git commit -am 'v{{version}}'", "Add and commit the package changes" ], [ "git push upstream stable", "Push the release branch changes to the repo" ], [ "git checkout -b temp-release-branch stable","Create a temporary branch for the dist" ], diff --git a/package.json b/package.json index 38e514cf4a..56e6a778bc 100644 --- a/package.json +++ b/package.json @@ -100,6 +100,7 @@ "markdown-table": "^1.0.0", "proxyquireify": "^3.0.0", "qunitjs": "^1.23.1", + "shelljs-nodecli": "^0.1.1", "sinon": "^1.16.1", "time-grunt": "^1.1.1", "uglify-js": "~2.7.3",