Built motion from commit 503e72f.|0.0.143
[motion.git] / public / bower_components / lodash / lib / fp / build-modules.js
index e66b7cd..43902e0 100644 (file)
@@ -5,11 +5,11 @@ var _ = require('lodash'),
     glob = require('glob'),
     path = require('path');
 
-var util = require('../common/util');
+var file = require('../common/file'),
+    mapping = require('../common/mapping');
 
-var mapping = require('../../fp/_mapping'),
-    templatePath = path.join(__dirname, 'template/modules'),
-    template = util.globTemplate(path.join(templatePath, '*.jst'));
+var templatePath = path.join(__dirname, 'template/modules'),
+    template = file.globTemplate(path.join(templatePath, '*.jst'));
 
 var aryMethods = _.union(
   mapping.aryMethod[1],
@@ -35,9 +35,11 @@ var categories = [
 var ignored = [
   '_*.js',
   'core.js',
+  'core.min.js',
   'fp.js',
   'index.js',
-  'lodash.js'
+  'lodash.js',
+  'lodash.min.js'
 ];
 
 function isAlias(funcName) {
@@ -95,8 +97,7 @@ function build(target) {
   _.each([mapping.aliasToReal, mapping.remap], function(data) {
     _.forOwn(data, function(realName, alias) {
       var modulePath = path.join(target, alias + '.js');
-      if (!_.startsWith(alias, '_') &&
-          !_.includes(modulePaths, modulePath)) {
+      if (!_.includes(modulePaths, modulePath)) {
         modulePaths.push(modulePath);
       }
     });
@@ -104,13 +105,14 @@ function build(target) {
 
   var actions = modulePaths.map(function(modulePath) {
     var moduleName = path.basename(modulePath, '.js');
-    return util.writeFile(path.join(fpPath, moduleName + '.js'), getTemplate(moduleName));
+    return file.write(path.join(fpPath, moduleName + '.js'), getTemplate(moduleName));
   });
 
-  actions.unshift(util.copyFile(path.join(__dirname, '../../fp'), fpPath));
-  actions.push(util.writeFile(path.join(target, 'fp.js'), template.fp()));
-  actions.push(util.writeFile(path.join(fpPath, 'convert.js'), template.convert()));
-  actions.push(util.writeFile(path.join(fpPath, '_util.js'), template._util()));
+  actions.unshift(file.copy(path.join(__dirname, '../../fp'), fpPath));
+  actions.push(file.write(path.join(fpPath, '_falseOptions.js'), template._falseOptions()));
+  actions.push(file.write(path.join(fpPath, '_util.js'), template._util()));
+  actions.push(file.write(path.join(target, 'fp.js'), template.fp()));
+  actions.push(file.write(path.join(fpPath, 'convert.js'), template.convert()));
 
   async.series(actions, onComplete);
 }