-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathember-cli-build.js
40 lines (36 loc) · 1.12 KB
/
ember-cli-build.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/* global require, module */
var EmberApp = require('ember-cli/lib/broccoli/ember-app');
module.exports = function(defaults) {
var env = EmberApp.env();
var isProductionLikeBuild = ['production', 'staging'].indexOf(env) > -1;
var app = new EmberApp(defaults, {
dotEnv: {
clientAllowedKeys: [
'AWS_KEY',
'AWS_SECRET',
'AWS_BUCKET',
'AWS_REGION',
'REDIS_URL',
'ASSETS_URL'
]
},
fingerprint: {
enabled: isProductionLikeBuild,
prepend: process.env.ASSETS_URL
},
sourcemaps: {
enabled: !isProductionLikeBuild,
},
minifyCSS: { enabled: isProductionLikeBuild },
minifyJS: { enabled: isProductionLikeBuild },
tests: process.env.EMBER_CLI_TEST_COMMAND || !isProductionLikeBuild,
hinting: process.env.EMBER_CLI_TEST_COMMAND || !isProductionLikeBuild
});
//bootstrap
app.import('bower_components/bootstrap/dist/css/bootstrap.css');
app.import('bower_components/bootstrap/dist/js/bootstrap.js');
app.import('bower_components/bootstrap/dist/css/bootstrap.css.map', {
destDir: 'assets'
});
return app.toTree();
};