example/Gruntfile.js
function(fileName) {
            //Grab the path package here locally for clarity
            var _path = require('path');
            
            //'yada/yada/multi1.html' -> 'multi1'
            var name = _path
              .basename(
                fileName, 
                _path.extname(fileName));
                
            //'multi1' -> 'name_1'
            return 'name_'+name[5];
          }
function(fileName) {
            //Grab the path package here locally for clarity
            var _path = require('path');
            
            //'yada/yada/multi1.html' -> 'multi1'
            var name = _path
              .basename(
                fileName, 
                _path.extname(fileName));
                
            //'multi1' -> 'name_1'
            return 'name_'+name[5];
          }
function ( fileName ) { //Grab the path package here locally for clarity var _path = require ( 'path' ) ; //'yada/yada/multi1.html' -> 'multi1' var name = _path . basename ( fileName , _path . extname ( fileName ) ) ; //'multi1' -> 'name_1' return 'name_' + name [ 5 ] ; }
Specify a custom name function
Specify a custom name function