FAQ Database Discussion Community


Grunt tasks stuck in endless loop

javascript,node.js,gruntjs,npm,grunt-contrib-concat
Working on putting together a base Gruntfile.js for some upcoming projects. Starting in on a new computer so everything has been a fresh build. Installed Node and NPM using Homebrew, and then installed Grunt globally, as well as in my local directory. Here is my package.json: { "name": "timespent-prototype", "version":...

ENOTUP using Grunt

javascript,node.js,gruntjs,minify,grunt-contrib-concat
I'm using Grunt to minify and concatenate files for an AngularJS web application. Our source is on a file share and I'm connecting to it via a mapped drive. Whenever Grunt runs over my source directory, I get an error on one of my concat tasks. The error is "ENOTSUP,...

Complex gruntjs tasks

gruntjs,grunt-contrib-concat,grunt-contrib-uglify
I have the following scenario: concat some files uglify some files (based on the concatinated ones) concat a files to another file (that was uglified above) How would I write gruntfile.js? I tried something as this but it didn't work. Thanks module.exports = function(grunt) { grunt.initConfig({ pkg:grunt.file.readJSON('package.json'), concat: { target:...

Loading “Gruntfile.js” tasks…ERROR while running `grunt`

javascript,gruntjs,grunt-contrib-watch,grunt-contrib-concat
I'm new to the Grunt world. After installing grunt-cli, and all the dependencies, here is my : Gruntfile.js /* Grunt installation: ------------------- npm install -g grunt-cli npm install -g grunt-init npm init (creates a `package.json` file) Project Dependencies: --------------------- npm install grunt --save-dev npm install grunt-contrib-concat --save-dev npm install grunt-contrib-watch...

JS files getting duplicate in Grunt concat task

gruntjs,grunt-contrib-concat
I'm facing a weird issue where my some of the files inside usemin blocks are getting duplicated in Grunt build task after Grunt concat. I've searched for it and found various answers like Grunt my code is duplicated in concat.js but not able to fix the solution. I'm using default...

Create a dynamic array for use in grunt concat

json,gruntjs,grunt-contrib-concat
I need to concatenate a set files based on variables I have defined my package.json. // package.json ... "layouts": [ { "page": "home", "version": "a" }, { "page": "about", "version": "a" }, { "page": "contact", "version": "b" } ] ... In grunt I am then building these into a JSON...