aboutsummaryrefslogtreecommitdiffstats
path: root/Gruntfile.js
diff options
context:
space:
mode:
authorTimmy Willison <timmywillisn@gmail.com>2013-12-06 15:55:55 -0500
committerTimmy Willison <timmywillisn@gmail.com>2013-12-06 16:14:27 -0500
commitc2e0dbdaa59dee7201ce53f9993e8477cf68818f (patch)
tree0f19befe4f562f1b7fe72f5e9918056a9308ca02 /Gruntfile.js
parentb869d3f1ac9f8931c97a300616c815be3d6b2b26 (diff)
downloadjquery-c2e0dbdaa59dee7201ce53f9993e8477cf68818f.tar.gz
jquery-c2e0dbdaa59dee7201ce53f9993e8477cf68818f.zip
Manage bower dependencies with grunt-bowercopy
Tracked bower dependencies are located at "src/sizzle" and "test/libs". The source-destination mapping is in the Gruntfile. When updating a bower dependency, update the version in bower.json, run `grunt bower`, and then commit the result. When adding a dependency, update the bowercopy task accordingly. Fixes #14615. Closes gh-1452. Conflicts: bower.json test/index.html
Diffstat (limited to 'Gruntfile.js')
-rw-r--r--Gruntfile.js26
1 files changed, 18 insertions, 8 deletions
diff --git a/Gruntfile.js b/Gruntfile.js
index 84aa02c89..759edfcf1 100644
--- a/Gruntfile.js
+++ b/Gruntfile.js
@@ -10,7 +10,6 @@ module.exports = function( grunt ) {
}
var gzip = require( "gzip-js" ),
- path = require( "path" ),
srcHintOptions = readOptionalJSON( "src/.jshintrc" );
// The concatenated file won't pass onevar
@@ -45,14 +44,22 @@ module.exports = function( grunt ) {
}
}
},
- bower: {
- install: {
+ bowercopy: {
+ options: {
+ clean: true
+ },
+ src: {
+ files: {
+ "src/sizzle": "sizzle"
+ }
+ },
+ tests: {
options: {
- targetDir: "bower_modules",
- cleanup: true,
- layout: function( type ) {
- return path.join( type );
- }
+ destPrefix: "test/libs"
+ },
+ files: {
+ "qunit": "qunit/qunit",
+ "require.js": "requirejs/require.js"
}
}
},
@@ -137,6 +144,9 @@ module.exports = function( grunt ) {
// Integrate jQuery specific tasks
grunt.loadTasks( "build/tasks" );
+ // Alias bower to bowercopy
+ grunt.registerTask( "bower", "bowercopy" );
+
// Short list as a high frequency watch task
grunt.registerTask( "dev", [ "build:*:*", "jshint", "jscs" ] );