Skip to content

Commit

Permalink
Merge pull request #1 from linnovate/master
Browse files Browse the repository at this point in the history
Update from the original repo
  • Loading branch information
lvarayut committed Aug 18, 2015
2 parents 02aa972 + d29a672 commit e31b0bf
Show file tree
Hide file tree
Showing 57 changed files with 3,176 additions and 2,074 deletions.
3 changes: 2 additions & 1 deletion .jshintrc
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"noarg" : true, // true: Prohibit use of `arguments.caller` and `arguments.callee`
"noempty" : true, // true: Prohibit use of empty blocks
"nonew" : true, // true: Prohibit use of constructors for side-effects (without assignment)
"plusplus" : true, // true: Prohibit use of `++` & `--`
"plusplus" : false, // true: Prohibit use of `++` & `--`
"quotmark" : "single", // Quotation mark consistency:
// false : do nothing (default)
// true : ensure whatever is used is consistent
Expand Down Expand Up @@ -72,6 +72,7 @@

// Custom Globals
"globals": {
"$" : true,
"angular" : true,
"define" : false,
"jasmine" : false,
Expand Down
3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ notifications:
webhooks:
urls:
- https://webhooks.gitter.im/e/08c84711c36e875930d0
- https://hooks.slack.com/services/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
on_success: change # options: [always|never|change] default: always
on_failure: always # options: [always|never|change] default: always
on_start: false # default: false
on_start: always # default: false


2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Build Status](https://travis-ci.org/linnovate/mean.svg?branch=master)](https://travis-ci.org/linnovate/mean)
[![Build Status](https://travis-ci.org/linnovate/mean.svg)](https://travis-ci.org/linnovate/mean)
[![Dependencies Status](https://david-dm.org/linnovate/mean.svg)](https://david-dm.org/linnovate/mean)
[![Gitter](https://badges.gitter.im/JoinChat.svg)](https://gitter.im/linnovate/mean?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)

Expand Down
4 changes: 3 additions & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@
"bootstrap": "latest",
"angular-bootstrap": "latest",
"angular-ui-router": "#master",
"web-bootstrap": "./node_modules/meanio/resources/web-bootstrap.js"
"web-bootstrap": "./node_modules/meanio/resources/web-bootstrap.js",
"angular-ui-select": "latest",
"angular-sanitize": "latest"
}
}
7 changes: 6 additions & 1 deletion config/assets.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
{
"core": {
"css": {
"bower_components/build/css/dist.min.css": []
"bower_components/build/css/dist.min.css": [
"bower_components/angular/angular-csp.css",
"bower_components/angular-ui-select/dist/select.min.css"
]
},
"js": {
"bower_components/build/js/dist.min.js": [
Expand All @@ -10,9 +13,11 @@
"bower_components/angular-mocks/angular-mocks.js",
"bower_components/angular-cookies/angular-cookies.min.js",
"bower_components/angular-resource/angular-resource.min.js",
"bower_components/angular-sanitize/angular-sanitize.min.js",
"bower_components/angular-ui-router/release/angular-ui-router.min.js",
"bower_components/angular-jwt/dist/angular-jwt.min.js",
"bower_components/angular-bootstrap/ui-bootstrap-tpls.js",
"bower_components/angular-ui-select/dist/select.min.js",
"bower_components/web-bootstrap/index.js"
]
}
Expand Down
1 change: 1 addition & 0 deletions config/env/all.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ module.exports = {
direction: 'rtl',
}],
currentLanguage: 'en',
cssFramework: 'bootstrap',
// The session cookie name
sessionName: 'connect.sid'
};
2 changes: 1 addition & 1 deletion config/express.js
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ module.exports = function(app, db) {

app.use(modRewrite([

'!^/api/.*|\\_getModules|\\.html|\\.js|\\.css|\\.swf|\\.jp(e?)g|\\.png|\\.gif|\\.svg|\\.eot|\\.ttf|\\.woff|\\.pdf$ / [L]'
'!^/api/.*|\\_getModules|\\.html|\\.js|\\.css|\\.swf|\\.jp(e?)g|\\.png|\\.ico|\\.gif|\\.svg|\\.eot|\\.ttf|\\.woff|\\.pdf$ / [L]'

]));

Expand Down
44 changes: 26 additions & 18 deletions gulp/development.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,16 @@ var gulp = require('gulp'),
plugins = gulpLoadPlugins(),
coffee = require('gulp-coffee'),
paths = {
js: ['*.js', 'test/**/*.js', '!test/coverage/**', '!bower_components/**', '!packages/**/node_modules/**', '!packages/contrib/**/*.js', '!packages/contrib/**/node_modules/**', '!packages/core/**/*.js', '!packages/core/public/assets/lib/**/*.js'],
html: ['packages/**/public/**/views/**', 'packages/**/server/views/**'],
css: ['!bower_components/**', 'packages/**/public/**/css/*.css', '!packages/contrib/**/public/**/css/*.css', '!packages/core/**/public/**/css/*.css'],
less: ['**/public/**/css/*.less'],
sass: ['**/public/**/css/*.scss'],
coffee: ['packages/**/public/**/*.coffee','*.coffee'],
coffees: ['packages/**/server/**/*.coffee']
js: ['./*.js', 'config/**/*.js', 'gulp/**/*.js', 'tools/**/*.js', 'packages/**/*.js', '!packages/**/node_modules/**', '!packages/**/assets/**/lib/**'],
html: ['packages/**/*.html', '!packages/**/node_modules/**', '!packages/**/assets/**/lib/**'],
css: ['packages/**/*.css', '!packages/**/node_modules/**', '!packages/**/assets/**/lib/**'],
less: ['packages/**/*.less', '!packages/**/node_modules/**', '!packages/**/assets/**/lib/**'],
sass: ['packages/**/*.scss', '!packages/**/node_modules/**', '!packages/**/assets/**/lib/**'],
coffee: ['packages/**/*.coffee', '!packages/**/node_modules/**', '!packages/**/assets/**/lib/**']
};

/*var defaultTasks = ['clean', 'jshint', 'less', 'csslint', 'devServe', 'watch'];*/
var defaultTasks = ['coffee','clean', 'less', 'csslint', 'devServe', 'watch'];
var defaultTasks = ['coffee','clean', 'less', 'csslint', 'devServe', 'watch'];

gulp.task('env:development', function () {
process.env.NODE_ENV = 'development';
Expand All @@ -27,7 +26,7 @@ gulp.task('jshint', function () {
return gulp.src(paths.js)
.pipe(plugins.jshint())
.pipe(plugins.jshint.reporter('jshint-stylish'))
.pipe(plugins.jshint.reporter('fail'))
// .pipe(plugins.jshint.reporter('fail')) to avoid shutdown gulp by warnings
.pipe(count('jshint', 'files lint free'));
});

Expand All @@ -47,29 +46,38 @@ gulp.task('less', function() {
});

gulp.task('devServe', ['env:development'], function () {

plugins.nodemon({
script: 'server.js',
ext: 'html js',
env: { 'NODE_ENV': 'development' } ,
ignore: ['node_modules/'],
nodeArgs: ['--debug']
ignore: ['node_modules/', 'bower_components/', 'logs/', 'packages/*/*/public/assets/lib/', 'packages/*/*/node_modules/', '.DS_Store', '**/.DS_Store', '.bower-*', '**/.bower-*'],
nodeArgs: ['--debug'],
stdout: false
}).on('readable', function() {
this.stdout.on('data', function(chunk) {
if(/Mean app started/.test(chunk)) {
setTimeout(function() { plugins.livereload.reload(); }, 500);
}
process.stdout.write(chunk);
});
this.stderr.pipe(process.stderr);
});
});

gulp.task('coffee', function() {
gulp.src(paths.coffee)
.pipe(coffee({bare: true}).on('error', gutil.log))
.pipe(gulp.dest('./packages'))
.pipe(gulp.dest('./packages'));
});

gulp.task('watch', function () {
gulp.watch(paths.coffee,['coffee']).on('change', plugins.livereload.changed);
gulp.watch(paths.coffees).on('change',plugins.livereload.changed);
gulp.watch(paths.js, ['jshint']).on('change', plugins.livereload.changed);
gulp.watch(paths.html).on('change', plugins.livereload.changed);
plugins.livereload.listen({interval:500});

gulp.watch(paths.coffee,['coffee']);
gulp.watch(paths.js, ['jshint']);
gulp.watch(paths.css, ['csslint']).on('change', plugins.livereload.changed);
gulp.watch(paths.less, ['less']).on('change', plugins.livereload.changed);
plugins.livereload.listen({interval: 500});
gulp.watch(paths.less, ['less']);
});

function count(taskName, message) {
Expand Down
7 changes: 2 additions & 5 deletions mean.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
{
"dependencies": {},
"anonymizedData": true,
"name": "m2 - 1",
"id": "55881690f366e3a837e9af25"
}
"dependencies": {}
}
Loading

0 comments on commit e31b0bf

Please sign in to comment.