@@ -12,8 +12,6 @@ module.exports = function( grunt ) {
1212 const rollup = require ( "rollup" ) ;
1313 const slimBuildFlags = require ( "./lib/slim-build-flags" ) ;
1414 const rollupFileOverrides = require ( "./lib/rollup-plugin-file-overrides" ) ;
15- const Insight = require ( "insight" ) ;
16- const pkg = require ( "../../package.json" ) ;
1715 const srcFolder = path . resolve ( `${ __dirname } /../../src` ) ;
1816 const read = function ( fileName ) {
1917 return grunt . file . read ( `${ srcFolder } /${ fileName } ` ) ;
@@ -339,46 +337,8 @@ module.exports = function( grunt ) {
339337 const modules = args . length ?
340338 args [ 0 ] . split ( "," ) . join ( ":" ) :
341339 "" ;
342- const done = this . async ( ) ;
343- const insight = new Insight ( {
344- trackingCode : "UA-1076265-4" ,
345- pkg : pkg
346- } ) ;
347-
348- function exec ( trackingAllowed ) {
349- let tracks = args . length ? args [ 0 ] . split ( "," ) : [ ] ;
350- const defaultPath = [ "build" , "custom" ] ;
351-
352- tracks = tracks . map ( function ( track ) {
353- return track . replace ( / \/ / g, "+" ) ;
354- } ) ;
355-
356- if ( trackingAllowed ) {
357-
358- // Track individuals
359- tracks . forEach ( function ( module ) {
360- const path = defaultPath . concat ( [ "individual" ] , module ) ;
361-
362- insight . track . apply ( insight , path ) ;
363- } ) ;
364-
365- // Track full command
366- insight . track . apply ( insight , defaultPath . concat ( [ "full" ] , tracks ) ) ;
367- }
368-
369- grunt . task . run ( [ "build:*:*" + ( modules ? ":" + modules : "" ) , "uglify" , "dist" ] ) ;
370- done ( ) ;
371- }
372340
373341 grunt . log . writeln ( "Creating custom build...\n" ) ;
374-
375- // Ask for permission the first time
376- if ( insight . optOut === undefined ) {
377- insight . askPermission ( null , function ( _error , result ) {
378- exec ( result ) ;
379- } ) ;
380- } else {
381- exec ( ! insight . optOut ) ;
382- }
342+ grunt . task . run ( [ "build:*:*" + ( modules ? ":" + modules : "" ) , "uglify" , "dist" ] ) ;
383343 } ) ;
384344} ;
0 commit comments