Skip to content

Commit a9fe4e2

Browse files
author
Matt Karl
committed
Upgraded to project-grunt 0.5.0
1 parent 2937780 commit a9fe4e2

File tree

3 files changed

+14
-32
lines changed

3 files changed

+14
-32
lines changed

Gruntfile.js

Lines changed: 12 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -5,30 +5,13 @@ module.exports = function(grunt)
55

66
// Combine the game builder and current project
77
// configs into one object
8-
var config = _.extend(
9-
10-
// Setup the default game tasks
11-
require('grunt-game-builder')(grunt, { autoInit: false }),
12-
13-
// Setup the current project tasks
14-
require('load-grunt-config')(grunt, {
15-
// The path for the tasks
16-
configPath: path.join(process.cwd(), 'tasks'),
17-
autoInit: false,
18-
19-
// We don't want to reload builder
20-
loadGruntTasks: { pattern: [
21-
'grunt-*',
22-
'!grunt-game-builder'
23-
] },
24-
25-
// Share the deploy folder with the tasks
26-
data: {
27-
buildDir : './build',
28-
installerDir : './installer',
29-
}
30-
})
31-
);
8+
var config = require('project-grunt')(grunt, {
9+
autoInit: false,
10+
data: {
11+
buildDir : './build',
12+
installerDir : './installer',
13+
}
14+
});
3215

3316
// Add the modules to config
3417
var build = grunt.file.readJSON('build.json');
@@ -84,8 +67,9 @@ module.exports = function(grunt)
8467
config.jshint.main.push(js);
8568

8669
// Add to source maps
87-
config.concat_sourcemap[name] = {
88-
files: output
70+
config.concat[name] = {
71+
src: js,
72+
dest: '<%= jsFolder %>/'+name+'.js'
8973
};
9074

9175
// add files to clean
@@ -96,13 +80,13 @@ module.exports = function(grunt)
9680

9781
config.watch.main.files.push(js);
9882
config.watch.main.tasks.push(
99-
'concat_sourcemap:'+name,
83+
'concat:'+name,
10084
'replace:'+name
10185
);
10286

10387
moduleTasks.push('uglify:'+name);
10488
moduleTasksDebug.push(
105-
'concat_sourcemap:'+name,
89+
'concat:'+name,
10690
'replace:'+name+'App'
10791
);
10892
}

package.json

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,8 @@
44
"dependencies": {
55
"grunt": "~0.4.5",
66
"grunt-exec": "~0.4.6",
7-
"grunt-game-builder": "^0.3.6",
7+
"project-grunt": "~0.5.0",
88
"grunt-node-webkit-builder": "~0.2.2",
9-
"load-grunt-config": "~0.13.1",
10-
"load-grunt-tasks": "*",
119
"lodash": "~2.4.1"
1210
}
1311
}

tasks/aliases.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ module.exports = function(grunt)
1515
grunt.registerTask('app-debug', 'Build the Application in debug mode', [
1616
'clean:main',
1717
'jshint:main',
18-
'concat_sourcemap:main',
18+
'concat:main',
1919
'replace:app',
2020
'clean:css',
2121
'less:development',

0 commit comments

Comments
 (0)