Skip to content
This repository has been archived by the owner on Nov 28, 2022. It is now read-only.

Move ember build tasks over from main repository #176

Merged
merged 1 commit into from Aug 3, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
51 changes: 44 additions & 7 deletions Gruntfile.js
Expand Up @@ -8,10 +8,7 @@ var _ = require('lodash'),
getTopContribs = require('top-gh-contribs'),
moment = require('moment'),
chalk = require('chalk'),
Promise = require('bluebird'),

escapeChar = process.platform.match(/^win/) ? '^' : '\\',
cwd = process.cwd().replace(/( |\(|\))/g, escapeChar + '$1');
Promise = require('bluebird');

module.exports = function(grunt) {

Expand Down Expand Up @@ -85,21 +82,61 @@ module.exports = function(grunt) {
}
},

// ### grunt-bg-shell
// Used to run ember-cli watch in the background
bgShell: {
ember: {
cmd: 'npm run build -- --watch',
bg: true,
stdout: function (out) {
grunt.log.writeln(chalk.cyan('Ember-cli::') + out);
},
stderror: function (error) {
grunt.log.error(chalk.red('Ember-cli::' + error));
}
}
},

shell: {
'npm-install': {
command: 'npm install'
},

'bower-install': {
command: path.resolve(cwd + '/node_modules/.bin/bower install')
command: 'bower install'

This comment was marked as abuse.

This comment was marked as abuse.

},

ember: {
command: function (mode) {
switch (mode) {
case 'prod':
return 'npm run build -- --environment=production --silent';

case 'dev':
return 'npm run build';
}
},
options: {
execOptions: {
stdout: false
}
}
},

csscombfix: {
command: path.resolve(cwd + '/node_modules/.bin/csscomb -c app/styles/csscomb.json -v app/styles')
command: 'csscomb -c app/styles/csscomb.json -v app/styles'
},

csscomblint: {
command: path.resolve(cwd + '/node_modules/.bin/csscomb -c app/styles/csscomb.json -lv app/styles')
command: 'csscomb -c app/styles/csscomb.json -lv app/styles'
},

test: {
command: 'npm test'
},

options: {
preferLocal: true
}
}
});
Expand Down
1 change: 1 addition & 0 deletions package.json
Expand Up @@ -76,6 +76,7 @@
"fs-extra": "0.30.0",
"glob": "7.0.5",
"grunt": "1.0.1",
"grunt-bg-shell": "2.3.3",
"grunt-contrib-clean": "1.0.0",
"grunt-contrib-jshint": "1.0.0",
"grunt-jscs": "3.0.1",
Expand Down