Skip to content

Commit

Permalink
Grunt: Added task for generating the list of authors.
Browse files Browse the repository at this point in the history
  • Loading branch information
scottgonzalez committed May 14, 2012
1 parent d4318a5 commit 6b1fea9
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions grunt.js
Original file line number Diff line number Diff line change
Expand Up @@ -572,6 +572,30 @@ grunt.registerTask( "clean", function() {
require( "rimraf" ).sync( "dist" );
});

grunt.registerTask( "authors", function() {
var done = this.async();

grunt.utils.spawn({
cmd: "git",
args: [ "log", "--pretty=%an <%ae>" ]
}, function( err, result ) {
if ( err ) {
grunt.log.error( err );
return done( false );
}

var authors,
tracked = {};
authors = result.split( "\n" ).reverse().filter(function( author ) {
var first = !tracked[ author ];
tracked[ author ] = true;
return first;
}).join( "\n" );
grunt.log.writeln( authors );
done();
});
});

grunt.registerTask( "default", "lint csslint htmllint qunit" );
grunt.registerTask( "sizer", "concat:ui min:dist/jquery-ui.min.js compare_size:all" );
grunt.registerTask( "sizer_all", "concat:ui min compare_size" );
Expand Down

0 comments on commit 6b1fea9

Please sign in to comment.