Skip to content

Commit

Permalink
fix(gruntfile): grunt tasks should run if no local config exists
Browse files Browse the repository at this point in the history
  • Loading branch information
DaftMonk committed Jul 28, 2014
1 parent 0581ed0 commit 422d6bc
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion app/templates/Gruntfile.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
'use strict';

module.exports = function (grunt) {
var localConfig;
try {
localConfig = require('./server/config/local.env');
} catch(e) {
localConfig = {};
}

// Load grunt tasks automatically, when needed
require('jit-grunt')(grunt, {
Expand Down Expand Up @@ -471,7 +477,7 @@ module.exports = function (grunt) {
prod: {
NODE_ENV: 'production'
},
all: require('./server/config/local.env')
all: localConfig
},<% if(filters.jade) { %>

// Compiles Jade to html
Expand Down

4 comments on commit 422d6bc

@meeDamian
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was just filling a bug on that, when I noticed it's fixed! Good job!

@meeDamian
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oups, CI is still broken if SASS is used

Warning: Running "sass:server" (sass) task
Warning:
You need to have Ruby and Sass installed and in your PATH for this task to work.
More info: https://github.com/gruntjs/grunt-contrib-sass
� Use --force to continue.

Aborted due to warnings.

I will PR in a few mins

@meeDamian
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually... Is there any particular reason why we're testing against nodejs@0.8 as well? It's like 2 years old now.

Wouldn't it be better to add 0.11 instead, so we can see already what may break there?

@meeDamian
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sent #409

Please sign in to comment.