Export package version in Grunt file so docs template can access

This commit is contained in:
Nick O'Leary 2021-04-16 11:56:23 +01:00
parent 04a3c4bb22
commit 0167c25e08
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9
1 changed files with 6 additions and 2 deletions

View File

@ -40,8 +40,11 @@ module.exports = function(grunt) {
if (nonHeadless) {
process.env.NODE_RED_NON_HEADLESS = true;
}
let packageFile = grunt.file.readJSON('package.json')
process.env.NODE_RED_PACKAGE_VERSION = packageFile.version;
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
pkg: packageFile,
paths: {
dist: ".dist"
},
@ -467,7 +470,8 @@ module.exports = function(grunt) {
],
options: {
destination: 'docs',
configure: './jsdoc.json'
configure: './jsdoc.json',
fred: "hi there"
}
},
_editor: {