From 53490cd368e4dc32e1a5b47d0a90aec22a25412b Mon Sep 17 00:00:00 2001 From: Steve-Mcl Date: Sat, 27 Jun 2020 11:24:06 +0100 Subject: [PATCH] Add developer options - permits npm run build-dev. skips minification & doesnt launch nodemon - permits npm run dev for those without grunt installed globally --- Gruntfile.js | 4 ++++ package.json | 2 ++ 2 files changed, 6 insertions(+) diff --git a/Gruntfile.js b/Gruntfile.js index 32556f0a4..8c18dc0fb 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -623,6 +623,10 @@ module.exports = function(grunt) { grunt.registerTask('build', 'Builds editor content', ['clean:build','jsonlint','concat:build','concat:vendor','copy:build','uglify:build','sass:build','attachCopyright']); + + grunt.registerTask('build-dev', + 'Developer mode: build dev version', + ['clean:build','concat:build','concat:vendor','copy:build','sass:build','setDevEnv']); grunt.registerTask('dev', 'Developer mode: run node-red, watch for source changes and build/restart', diff --git a/package.json b/package.json index 6e1636e07..2f20c08db 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,8 @@ "start": "node packages/node_modules/node-red/red.js", "test": "grunt", "build": "grunt build", + "dev": "grunt dev", + "build-dev": "grunt build-dev", "docs": "grunt docs" }, "contributors": [