From 65e1da34faa0abdbd1e2108965fa5063108a3568 Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Fri, 8 Feb 2013 16:57:46 -0800 Subject: [PATCH] Add `custom build` header comment to builds when only using `--output`. Former-commit-id: adef2798bd590c0dc0c14b253f0d450ec5bb5394 --- build.js | 8 +++++--- dist/lodash.compat.js | 3 ++- dist/lodash.compat.min.js | 3 ++- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/build.js b/build.js index 87f81494d..ee2f95329 100755 --- a/build.js +++ b/build.js @@ -2383,9 +2383,11 @@ var outputUsed = false; // flag to specify creating a custom build - var isCustom = isLegacy || isMapped || isMobile || isModern || isStrict || isUnderscore || + var isCustom = ( + isLegacy || isMapped || isModern || isStrict || isUnderscore || outputPath || /(?:category|exclude|exports|iife|include|minus|plus)=/.test(options) || - !_.isEqual(exportsOptions, exportsAll); + !_.isEqual(exportsOptions, exportsAll) + ); // used as the basename of the output path var basename = outputPath @@ -2396,7 +2398,7 @@ dependencyMap = dependencyBackup; // output debug build - if (!isMinify && (isCustom || isDebug || isTemplate || outputPath)) { + if (!isMinify && (isCustom || isDebug || isTemplate)) { if (isCustom) { debugSource = addCommandsToHeader(debugSource, options); } diff --git a/dist/lodash.compat.js b/dist/lodash.compat.js index b388e5636..b16acfc9a 100644 --- a/dist/lodash.compat.js +++ b/dist/lodash.compat.js @@ -1,6 +1,7 @@ /** * @license - * Lo-Dash 1.0.0-rc.3 + * Lo-Dash 1.0.0-rc.3 (Custom Build) + * Build: `lodash -o ./dist/lodash.compat.js` * Copyright 2012-2013 The Dojo Foundation * Based on Underscore.js 1.4.4 * Copyright 2009-2013 Jeremy Ashkenas, DocumentCloud Inc. diff --git a/dist/lodash.compat.min.js b/dist/lodash.compat.min.js index 57c568d36..a085b4f1f 100644 --- a/dist/lodash.compat.min.js +++ b/dist/lodash.compat.min.js @@ -1,6 +1,7 @@ /** * @license - * Lo-Dash 1.0.0-rc.3 lodash.com/license + * Lo-Dash 1.0.0-rc.3 (Custom Build) lodash.com/license + * Build: `lodash -o ./dist/lodash.compat.js` * Underscore.js 1.4.4 underscorejs.org/LICENSE */ ;(function(n,t){function r(n){return n&&typeof n=="object"&&n.__wrapped__?n:this instanceof r?(this.__wrapped__=n,void 0):new r(n)}function e(n,t,r){t||(t=0);var e=n.length,u=e-t>=(r||it);if(u){var o={};for(r=t-1;++rt||typeof n=="undefined")return 1;if(n