diff --git a/README.md b/README.md index 42608e59..e9164947 100644 --- a/README.md +++ b/README.md @@ -212,7 +212,7 @@ More usage in documentation: [Angular directive usage](https://github.com/nosir/ - [ReactJS component usage](https://github.com/nosir/cleave.js/blob/master/doc/reactjs-component-usage.md) - [AngularJS directive usage](https://github.com/nosir/cleave.js/blob/master/doc/angularjs-directive-usage.md) -## Building & Running tests +## Run tasks ```bash npm install @@ -224,10 +224,22 @@ Build assets gulp build ``` -Run tests and lint +Run tests ```bash -gulp test && gulp eslint +gulp test +``` + +Lint + +```bash +gulp eslint +``` + +Publish (build, tests & lint) + +```bash +gulp publish ``` ## Todo @@ -239,7 +251,7 @@ gulp test && gulp eslint - [x] PhantomJS browser tests - [ ] ReactJS / AngularJS browser tests -> For contributors, please run `gulp build` & `gulp test`, also we have a [not in the plan](https://github.com/nosir/cleave.js/blob/master/doc/not-in-the-plan.md) list you may concern. +> For contributors, please run `gulp publish` to ensure your PR passes tests and lint, also we have a [not in the plan](https://github.com/nosir/cleave.js/blob/master/doc/not-in-the-plan.md) list you may concern. ## Get in touch - Bugs / Suggestions: [open an issue](https://github.com/nosir/cleave.js/issues) diff --git a/doc/not-in-the-plan.md b/doc/not-in-the-plan.md index 87f1d2af..1f3e71f7 100644 --- a/doc/not-in-the-plan.md +++ b/doc/not-in-the-plan.md @@ -6,18 +6,19 @@ As a small and simple project, cleave.js has its own direction, which is somethi At the same time, we want to only focus on things we are able to keep following and updating. -Thus, for now we won't consider adding / merging these features / pull requests, as for the future who knows, let's just be less ambitious: +Thus, at present we won't consider merging these features / pull requests, as for the future who knows, we'd be less ambitious: - LTE IE8 support - RegExp option - Change API to a more OO way +- Angular2 directive - Ember.js component - Vue.js component - React HOC - TypeScript port - CoffeeScript port -This is by no means to say these technologies are not good, just the opposite, they are all brilliant and outstanding, maybe except the first one. +This is by no means say these technologies are not good, just the opposite, they are all brilliant and outstanding, maybe except the first one. Still, feel free to fork cleave.js and play with your favourite tech. diff --git a/gulp-tasks/test.js b/gulp-tasks/test.js index b3c6f2fe..a793f0b6 100644 --- a/gulp-tasks/test.js +++ b/gulp-tasks/test.js @@ -36,6 +36,14 @@ gulp.task('unit', function () { .pipe(mocha({reporter: 'spec'})); }); +gulp.task('browser', function () { + return gulp + .src([ + path.join(paths.test, 'browser/*.html') + ]) + .pipe(mochaPhantomJS()); +}); + gulp.task('eslint', function () { return gulp.src([ path.join(paths.src, '**/*.js'), @@ -46,12 +54,6 @@ gulp.task('eslint', function () { .pipe(eslint.failAfterError()); }); -gulp.task('browser', function () { - return gulp - .src([ - path.join(paths.test, 'browser/*.html') - ]) - .pipe(mochaPhantomJS()); -}); +gulp.task('test', gulpsync.sync(['unit', 'browser'])); -gulp.task('test', gulpsync.sync(['eslint', 'unit', 'browser'])); +gulp.task('publish', gulpsync.sync(['build', 'test', 'eslint']));