diff --git a/gulpfile.js b/gulpfile.js index da4f92090..df5c58481 100755 --- a/gulpfile.js +++ b/gulpfile.js @@ -99,6 +99,9 @@ try { ; } catch(error) { + if(error.code === 'MODULE_NOT_FOUND') { + console.error('No semantic.json config found'); + } var config = false; } @@ -173,7 +176,7 @@ gulp.task('watch', 'Watch for site/theme changes (Default Task)', function(callb console.log('Watching source files for changes'); if(!fs.existsSync(config.files.theme)) { - console.error('Cant compile LESS. Run "grunt install" to create a theme config file'); + console.error('Cant compile LESS. Run "gulp install" to create a theme config file'); return; } @@ -301,7 +304,7 @@ gulp.task('build', 'Builds all files from source', function(callback) { console.info('Building Semantic'); if(!fs.existsSync(config.files.theme)) { - console.error('Cant build LESS. Run "grunt install" to create a theme config file'); + console.error('Cant build LESS. Run "gulp install" to create a theme config file'); return; } diff --git a/tasks/gulp-settings.js b/tasks/gulp-settings.js index f1f153963..351812c51 100755 --- a/tasks/gulp-settings.js +++ b/tasks/gulp-settings.js @@ -1,10 +1,19 @@ var + path = require('path'), fs = require('fs'), - package = (fs.existsSync('../package/.json')) - ? require('../package.json') - : false + package ; +try { + package = require('../package.json') +} +catch(error) { + // fallback + package = { + title : 'Semantic UI', + url : 'git://github.com/Semantic-Org/Semantic-UI.git' + } +} module.exports = { del: {