-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit ce951f8
Showing
10 changed files
with
268 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* text=auto |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
node_modules | ||
coverage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
language: node_js | ||
node_js: | ||
- v6 | ||
- v5 | ||
- v4 | ||
- '0.12' | ||
- '0.10' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
The MIT License (MIT) | ||
|
||
Copyright (c) 2016 Monkee-Boy <[email protected]> (https://www.monkee-boy.com) | ||
|
||
Permission is hereby granted, free of charge, to any person obtaining a copy | ||
of this software and associated documentation files (the "Software"), to deal | ||
in the Software without restriction, including without limitation the rights | ||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | ||
copies of the Software, and to permit persons to whom the Software is | ||
furnished to do so, subject to the following conditions: | ||
|
||
The above copyright notice and this permission notice shall be included in | ||
all copies or substantial portions of the Software. | ||
|
||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | ||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | ||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | ||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | ||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | ||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN | ||
THE SOFTWARE. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
 generator-mboy-deploy [](http://badge.fury.io/js/generator-mboy-gulp) [](https://travis-ci.org/Monkee-Boy/generator-mboy-deploy) [](https://coveralls.io/r/Monkee-Boy/generator-mboy-gulp) | ||
|
||
> Generate the Monkee-Boy gulp setup. | ||
## Installation | ||
|
||
First, install [Yeoman](http://yeoman.io) and generator-mboy-gulp using [npm](https://www.npmjs.com/) (we assume you have pre-installed [node.js](https://nodejs.org/)). | ||
|
||
```bash | ||
npm install -g yo | ||
npm install -g generator-mboy-gulp | ||
``` | ||
|
||
Then generate your new project: | ||
|
||
```bash | ||
yo mboy-gulp | ||
``` | ||
|
||
## Getting To Know Yeoman | ||
|
||
* Yeoman has a heart of gold. | ||
* Yeoman is a person with feelings and opinions, but is very easy to work with. | ||
* Yeoman can be too opinionated at times but is easily convinced not to be. | ||
* Feel free to [learn more about Yeoman](http://yeoman.io/). | ||
|
||
## Running Tests | ||
|
||
```bash | ||
npm test | ||
``` | ||
|
||
## The Dev Team | ||
|
||
Handcrafted with ♥ in Austin, Texas by the [Monkee-Boy Troop](http://www.monkee-boy.com/about/the-troop.php). | ||
|
||
[](https://github.com/fleeting) | [](https://github.com/pgautier404) | [](https://github.com/defvayne23) | [](https://github.com/djsaun) | ||
:---:|:---:|:---:|:---:|:---: | ||
[James Fleeting](https://github.com/fleeting) | [Pete Gautier](https://github.com/pgautier404) | [John Hoover](https://github.com/defvayne23) | [David Saunders](https://github.com/djsaun) | ||
|
||
## License | ||
|
||
MIT © [Monkee-Boy](https://www.monkee-boy.com) | ||
|
||
 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
'use strict'; | ||
var yeoman = require('yeoman-generator'); | ||
var chalk = require('chalk'); | ||
var yosay = require('yosay'); | ||
var string = require('underscore.string'); | ||
|
||
module.exports = yeoman.Base.extend({ | ||
prompting: function () { | ||
this.log(['\n', | ||
chalk.yellow(' ## ## ##### ## ## ## ## ####### ####### ##### ##### ## ##'), | ||
chalk.yellow('### ### ####### ### ## ## ## ####### ####### ###### ####### ## ##'), | ||
chalk.yellow('#### ### ## ## ### ## ## ## ## ## ## ## ## ## ## ##'), | ||
chalk.yellow('#### #### ## ## #### ## #### ## ## ## ## ## ## ## ##'), | ||
chalk.yellow('## #### ## ## ## ## ## ## #### ###### ###### #### ###### ## ## ####'), | ||
chalk.yellow('## ## ## ## ## ## ## ## ##### ###### ###### #### ###### ## ## ##'), | ||
chalk.yellow('## ## ## ## ## ## #### ## ### ## ## ## ## ## ## ##'), | ||
chalk.yellow('## ## ## ## ## ### ## ## ## ## ## ## ## ## ##'), | ||
chalk.yellow('## ## ####### ## ### ## ## ####### ####### ####### ####### ##'), | ||
chalk.yellow('## ## ##### ## ## ## ### ####### ####### ###### ##### ##')].join('\n') | ||
); | ||
|
||
// Have Yeoman greet the user. | ||
this.log(yosay( | ||
'Welcome to the ' + chalk.green('MBoy Gulp') + ' v1.0 generator!' | ||
)); | ||
|
||
this.log('I am going to generate the default Monkee-Boy gulp setup. Reference https://github.com/Monkee-Boy/gulpfile for more details.\n\nFirst a couple of quick questions.\n'); | ||
|
||
this.remote('Monkee-Boy', 'gulpfile', function (err, remote) { | ||
remote.directory('.', '.'); | ||
}); | ||
|
||
var prompts = [ | ||
{ | ||
name: 'projectName', | ||
message: 'What would you like to call this project (typically client name)?', | ||
default: 'Project Name' | ||
}, { | ||
name: 'repoUrl', | ||
message: 'What is the git repo url for this project?', | ||
default: '[email protected]:monkeeboy/PROJECTREPONAME.git' | ||
} | ||
]; | ||
|
||
return this.prompt(prompts).then(function (props) { | ||
this.props = props; | ||
this.props.projectName = string.slugify(props.projectName); | ||
}.bind(this)); | ||
}, | ||
|
||
writing: function () { | ||
// this.template('package.json', 'package.json'); | ||
}, | ||
|
||
install: function () { | ||
this.log('\nYour gulp files and structure are ready.\n' + chalk.green('May the code be with you.')); | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
'use strict'; | ||
var path = require('path'); | ||
var gulp = require('gulp'); | ||
var eslint = require('gulp-eslint'); | ||
var excludeGitignore = require('gulp-exclude-gitignore'); | ||
var mocha = require('gulp-mocha'); | ||
var istanbul = require('gulp-istanbul'); | ||
var nsp = require('gulp-nsp'); | ||
var plumber = require('gulp-plumber'); | ||
|
||
gulp.task('static', function () { | ||
return gulp.src('**/*.js') | ||
.pipe(excludeGitignore()) | ||
.pipe(eslint()) | ||
.pipe(eslint.format()) | ||
.pipe(eslint.failAfterError()); | ||
}); | ||
|
||
gulp.task('nsp', function (cb) { | ||
nsp({package: path.resolve('package.json')}, cb); | ||
}); | ||
|
||
gulp.task('pre-test', function () { | ||
return gulp.src('generators/**/*.js') | ||
.pipe(excludeGitignore()) | ||
.pipe(istanbul({ | ||
includeUntested: true | ||
})) | ||
.pipe(istanbul.hookRequire()); | ||
}); | ||
|
||
gulp.task('test', ['pre-test'], function (cb) { | ||
var mochaErr; | ||
|
||
gulp.src('test/**/*.js') | ||
.pipe(plumber()) | ||
.pipe(mocha({reporter: 'spec'})) | ||
.on('error', function (err) { | ||
mochaErr = err; | ||
}) | ||
.pipe(istanbul.writeReports()) | ||
.on('end', function () { | ||
cb(mochaErr); | ||
}); | ||
}); | ||
|
||
gulp.task('watch', function () { | ||
gulp.watch(['generators/**/*.js', 'test/**'], ['test']); | ||
}); | ||
|
||
gulp.task('prepublish', ['nsp']); | ||
gulp.task('default', ['static', 'test']); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,50 @@ | ||
{ | ||
"name": "generator-mboy-gulp", | ||
"version": "1.0.0", | ||
"description": "Generate the Monkee-Boy gulp setup.", | ||
"homepage": "https://github.com/Monkee-Boy/generator-mboy-gulp", | ||
"author": { | ||
"name": "James Fleeting", | ||
"email": "[email protected]", | ||
"url": "https://www.monkee-boy.com" | ||
}, | ||
"files": [ | ||
"generators" | ||
], | ||
"main": "generators/index.js", | ||
"keywords": [ | ||
"", | ||
"yeoman-generator" | ||
], | ||
"dependencies": { | ||
"yeoman-generator": "^0.23.0", | ||
"chalk": "^1.0.0", | ||
"yosay": "^1.0.0" | ||
}, | ||
"devDependencies": { | ||
"yeoman-test": "^1.0.0", | ||
"yeoman-assert": "^2.0.0", | ||
"eslint": "^3.1.1", | ||
"eslint-config-xo-space": "^0.14.0", | ||
"gulp": "^3.9.0", | ||
"gulp-eslint": "^2.0.0", | ||
"gulp-exclude-gitignore": "^1.0.0", | ||
"gulp-line-ending-corrector": "^1.0.1", | ||
"gulp-istanbul": "^1.0.0", | ||
"gulp-mocha": "^2.0.0", | ||
"gulp-plumber": "^1.0.0", | ||
"gulp-nsp": "^2.1.0" | ||
}, | ||
"eslintConfig": { | ||
"extends": "xo-space", | ||
"env": { | ||
"mocha": true | ||
} | ||
}, | ||
"repository": "Monkee-Boy/generator-mboy-gulp", | ||
"scripts": { | ||
"prepublish": "gulp prepublish", | ||
"test": "gulp" | ||
}, | ||
"license": "MIT" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
'use strict'; | ||
var path = require('path'); | ||
var assert = require('yeoman-assert'); | ||
var helpers = require('yeoman-test'); | ||
|
||
var expected = [ | ||
'package.json', | ||
'gulpfile.js' | ||
]; | ||
|
||
describe('generator-mboy-gulp:app', function () { | ||
before(function () { | ||
return helpers.run(path.join(__dirname, '../generators/app')) | ||
.withPrompts({someAnswer: true}) | ||
.toPromise(); | ||
}); | ||
|
||
it('creates files', function () { | ||
assert.file(expected); | ||
}); | ||
}); |