MDL-50277 Javascript: Hardcode nodejs dependencies
authorAndrew Nicols <andrew@nicols.co.uk>
Wed, 20 May 2015 01:41:15 +0000 (09:41 +0800)
committerAndrew Nicols <andrew@nicols.co.uk>
Wed, 20 May 2015 01:41:17 +0000 (09:41 +0800)
In order to produce a consistent build across the board, we must hardcode
several package versions. We must additionally specify compatible
versions for any sub-dependency that we have a requirement upon.

In this instance, the only sub-dependency which has an effect upon the
overall output is grunt-contrib-uglify's dependency upon uglify-js.

Since change in uglify-js may lead to changes in the generated output, we
must specify a fixed version of that dependency. That version must be
compatible with the dependency signature for grunt-contrib-uglify or the
dependency manager will just download a different version.

This issue also bumps the version of uglify-js to a version which changes
the output. This is the latest version at time of commit.

package.json
theme/bootstrapbase/amd/build/bootstrap.min.js

index e4128c2..6c3f59b 100644 (file)
@@ -3,9 +3,10 @@
     "private": true,
     "description": "Moodle",
     "devDependencies": {
-        "grunt": "~0.4.5",
-        "grunt-contrib-jshint": "~0.11.0",
-        "grunt-contrib-uglify": "~0.7.0",
-        "shifter": "~0.5.0"
+        "grunt": "0.4.5",
+        "grunt-contrib-jshint": "0.11.2",
+        "grunt-contrib-uglify": "0.9.1",
+        "shifter": "0.5.0",
+        "uglify-js": "2.4.22"
     }
 }
index f1febc2..26de8d8 100644 (file)
Binary files a/theme/bootstrapbase/amd/build/bootstrap.min.js and b/theme/bootstrapbase/amd/build/bootstrap.min.js differ