Skip to content
This repository has been archived by the owner on Jun 13, 2024. It is now read-only.

Commit

Permalink
init
Browse files Browse the repository at this point in the history
  • Loading branch information
jhotadhari committed Jan 4, 2017
0 parents commit 20ef938
Show file tree
Hide file tree
Showing 10 changed files with 190 additions and 0 deletions.
11 changes: 11 additions & 0 deletions .editorconfig
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
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* text=auto
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
coverage
7 changes: 7 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
language: node_js
node_js:
- v7
- v6
- v5
- v4
- '0.12'
13 changes: 13 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Copyright 2017 jhotadhari <tellme@waterproof-webdesign.info> (http://waterproof-webdesign.info/)

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
36 changes: 36 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# generator-pluginboilerplate [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-image]][daviddm-url]
> desc ???
## Installation

First, install [Yeoman](http://yeoman.io) and generator-pluginboilerplate 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-pluginboilerplate
```

Then generate your new project:

```bash
yo pluginboilerplate
```

## 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/).

## License

Apache-2.0 © [jhotadhari](http://waterproof-webdesign.info/)


[npm-image]: https://badge.fury.io/js/generator-pluginboilerplate.svg
[npm-url]: https://npmjs.org/package/generator-pluginboilerplate
[travis-image]: https://travis-ci.org//generator-pluginboilerplate.svg?branch=master
[travis-url]: https://travis-ci.org//generator-pluginboilerplate
[daviddm-image]: https://david-dm.org//generator-pluginboilerplate.svg?theme=shields.io
[daviddm-url]: https://david-dm.org//generator-pluginboilerplate
Empty file added generators/app/index.js
Empty file.
52 changes: 52 additions & 0 deletions gulpfile.js
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']);
50 changes: 50 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
{
"name": "generator-pluginboilerplate",
"version": "0.0.0",
"description": "desc ???",
"homepage": "http://waterproof-webdesign.info/",
"author": {
"name": "jhotadhari",
"email": "tellme@waterproof-webdesign.info",
"url": "http://waterproof-webdesign.info/"
},
"files": [
"generators"
],
"main": "generators/index.js",
"keywords": [
"",
"yeoman-generator"
],
"dependencies": {
"chalk": "^1.1.3",
"yeoman-generator": "^1.0.0",
"yosay": "^1.2.1"
},
"devDependencies": {
"eslint": "^3.1.1",
"eslint-config-xo-space": "^0.15.0",
"gulp": "^3.9.0",
"gulp-eslint": "^3.0.1",
"gulp-exclude-gitignore": "^1.0.0",
"gulp-istanbul": "^1.0.0",
"gulp-line-ending-corrector": "^1.0.1",
"gulp-mocha": "^3.0.1",
"gulp-nsp": "^2.1.0",
"gulp-plumber": "^1.0.0",
"yeoman-assert": "^2.2.1",
"yeoman-test": "^1.6.0"
},
"eslintConfig": {
"extends": "xo-space",
"env": {
"mocha": true
}
},
"repository": "/generator-pluginboilerplate",
"scripts": {
"prepublish": "gulp prepublish",
"test": "gulp"
},
"license": "Apache-2.0"
}
18 changes: 18 additions & 0 deletions test/app.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
'use strict';
var path = require('path');
var assert = require('yeoman-assert');
var helpers = require('yeoman-test');

describe('generator-pluginboilerplate:app', function () {
before(function () {
return helpers.run(path.join(__dirname, '../generators/app'))
.withPrompts({someAnswer: true})
.toPromise();
});

it('creates files', function () {
assert.file([
'dummyfile.txt'
]);
});
});

0 comments on commit 20ef938

Please sign in to comment.