From 389d4879da4aa620ee95d789b19ff9be44eb730a Mon Sep 17 00:00:00 2001 From: Peter Bacon Darwin Date: Wed, 12 Feb 2014 22:47:42 +0000 Subject: chore(doc-gen): new docs chore(doc-gen): implement dgeni --- lib/grunt/plugins.js | 19 +++---------------- 1 file changed, 3 insertions(+), 16 deletions(-) (limited to 'lib/grunt/plugins.js') diff --git a/lib/grunt/plugins.js b/lib/grunt/plugins.js index 59fee2e4..56836aae 100644 --- a/lib/grunt/plugins.js +++ b/lib/grunt/plugins.js @@ -1,6 +1,6 @@ var bower = require('bower'); var util = require('./utils.js'); -var spawn = require('child_process').spawn; +var shelljs = require('shelljs'); module.exports = function(grunt) { @@ -34,21 +34,8 @@ module.exports = function(grunt) { }); - grunt.registerMultiTask('docs', 'create angular docs', function(){ - var done = this.async(); - var files = this.data; - var docs = spawn('node', ['docs/src/gen-docs.js']); - docs.stdout.pipe(process.stdout); - docs.stderr.pipe(process.stderr); - docs.on('exit', function(code){ - if(code !== 0) grunt.fail.warn('Error creating docs'); - grunt.file.expand(files).forEach(function(file){ - var content = util.process(grunt.file.read(file), grunt.config('NG_VERSION'), false); - grunt.file.write(file, content); - }); - grunt.log.ok('docs created'); - done(); - }); + grunt.registerTask('docs', 'create angular docs', function(){ + shelljs.exec('node_modules/gulp/bin/gulp.js --gulpfile docs/gulpfile.js'); }); -- cgit v1.2.3