Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Adds --noext option to build.js.

  • Loading branch information...
commit fea46fc1a7fc9dc946e2804dfc99688402bc1b03 1 parent 4d73b95
Jeremy Kahn jeremyckahn authored

Showing 1 changed file with 28 additions and 14 deletions. Show diff stats Hide diff stats

  1. +28 14 build.js
42 build.js
@@ -10,18 +10,21 @@ var
10 10 'version' : null,
11 11 'build_date' : (new Date()).toGMTString()
12 12 },
13   - FILE_LIST = [
14   - 'src/rekapi.license.js'
15   - ,'src/rekapi.intro.js'
16   - ,'src/rekapi.core.js'
17   - ,'src/rekapi.actor.js'
18   - ,'src/rekapi.keyframeprops.js'
19   - ,'ext/canvas/rekapi.canvas.context.js'
20   - ,'ext/canvas/rekapi.canvas.actor.js'
21   - ,'ext/dom/rekapi.dom.actor.js'
22   - ,'ext/to-css/rekapi.to-css.js'
23   - ,'src/rekapi.init.js'
24   - ,'src/rekapi.outro.js'];
  13 + HEAD_FILE_LIST = [
  14 + 'src/rekapi.license.js',
  15 + 'src/rekapi.intro.js'],
  16 + CORE_FILE_LIST = [
  17 + 'src/rekapi.core.js',
  18 + 'src/rekapi.actor.js',
  19 + 'src/rekapi.keyframeprops.js'],
  20 + TAIL_FILE_LIST = [
  21 + 'src/rekapi.init.js',
  22 + 'src/rekapi.outro.js'],
  23 + EXTENSION_FILE_LIST = [
  24 + 'ext/canvas/rekapi.canvas.context.js',
  25 + 'ext/canvas/rekapi.canvas.actor.js',
  26 + 'ext/dom/rekapi.dom.actor.js',
  27 + 'ext/to-css/rekapi.to-css.js'];
25 28
26 29
27 30 // --- SETUP --- //
@@ -37,9 +40,11 @@ var
37 40 _distBundleName = _distBaseName + '.bundle.min.js';
38 41
39 42 _cli
40   - .version('0.1.1')
  43 + .version('0.1.2')
41 44 .option('--ver <build version>',
42 45 'A string representing the semver build version to record in the source (eg. 5.0.2)')
  46 + .option('--noext',
  47 + 'Don\'t include optional extensions (such as DOM and Canvas renderers)')
43 48 .parse(process.argv);
44 49
45 50
@@ -83,7 +88,16 @@ function echoFileSize(filename, explanatoryString) {
83 88 // --- CONCAT --- //
84 89
85 90 function getFileList() {
86   - return FILE_LIST;
  91 + var files = HEAD_FILE_LIST.slice(0);
  92 + files = files.concat(CORE_FILE_LIST);
  93 +
  94 + if (!_cli.noext) {
  95 + files = files.concat(EXTENSION_FILE_LIST);
  96 + }
  97 +
  98 + files = files.concat(TAIL_FILE_LIST);
  99 +
  100 + return files;
87 101 }
88 102
89 103 function concatFiles(fileList) {

0 comments on commit fea46fc

Please sign in to comment.
Something went wrong with that request. Please try again.