Skip to content

Commit 9f388b0

Browse files
committed
Merge branch 'release/0.0.1'
2 parents c5f9e80 + 085e11b commit 9f388b0

File tree

14 files changed

+523
-1
lines changed

14 files changed

+523
-1
lines changed

.editorconfig

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
root = true
2+
3+
[*]
4+
indent_style = space
5+
indent_size = 2
6+
charset = utf-8
7+
trim_trailing_whitespace = true
8+
insert_final_newline = true
9+
10+
[*.md]
11+
trim_trailing_whitespace = false

.eslintrc

Lines changed: 131 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,131 @@
1+
{
2+
"extends": "eslint:recommended",
3+
"env": {
4+
"node": true,
5+
"mocha": true
6+
},
7+
"rules": {
8+
"array-bracket-spacing": [
9+
2,
10+
"never"
11+
],
12+
"brace-style": [
13+
2,
14+
"1tbs"
15+
],
16+
"consistent-return": 0,
17+
"indent": [
18+
2,
19+
2
20+
],
21+
"no-multiple-empty-lines": [
22+
2,
23+
{
24+
"max": 2
25+
}
26+
],
27+
"no-use-before-define": [
28+
2,
29+
"nofunc"
30+
],
31+
"one-var": [
32+
2,
33+
"never"
34+
],
35+
"quote-props": [
36+
2,
37+
"as-needed"
38+
],
39+
"quotes": [
40+
2,
41+
"single"
42+
],
43+
"space-after-keywords": [
44+
2,
45+
"always"
46+
],
47+
"space-before-function-paren": [
48+
2,
49+
{
50+
"anonymous": "always",
51+
"named": "never"
52+
}
53+
],
54+
"space-in-parens": [
55+
2,
56+
"never"
57+
],
58+
"strict": [
59+
2,
60+
"global"
61+
],
62+
"curly": [
63+
2,
64+
"all"
65+
],
66+
"eol-last": 2,
67+
"key-spacing": [
68+
2,
69+
{
70+
"beforeColon": false,
71+
"afterColon": true
72+
}
73+
],
74+
"no-eval": 2,
75+
"no-with": 2,
76+
"space-infix-ops": 2,
77+
"dot-notation": [
78+
2,
79+
{
80+
"allowKeywords": true
81+
}
82+
],
83+
"eqeqeq": 2,
84+
"no-alert": 2,
85+
"no-caller": 2,
86+
"no-empty-label": 2,
87+
"no-extend-native": 2,
88+
"no-extra-bind": 2,
89+
"no-implied-eval": 2,
90+
"no-iterator": 2,
91+
"no-label-var": 2,
92+
"no-labels": 2,
93+
"no-lone-blocks": 2,
94+
"no-loop-func": 2,
95+
"no-multi-spaces": 2,
96+
"no-multi-str": 2,
97+
"no-native-reassign": 2,
98+
"no-new": 2,
99+
"no-new-func": 2,
100+
"no-new-wrappers": 2,
101+
"no-octal-escape": 2,
102+
"no-proto": 2,
103+
"no-return-assign": 2,
104+
"no-script-url": 2,
105+
"no-sequences": 2,
106+
"no-unused-expressions": 2,
107+
"yoda": 2,
108+
"no-shadow": 2,
109+
"no-shadow-restricted-names": 2,
110+
"no-undef-init": 2,
111+
"camelcase": 2,
112+
"comma-spacing": 2,
113+
"new-cap": 2,
114+
"new-parens": 2,
115+
"no-array-constructor": 2,
116+
"no-extra-parens": 2,
117+
"no-new-object": 2,
118+
"no-spaced-func": 2,
119+
"no-trailing-spaces": 2,
120+
"no-underscore-dangle": 2,
121+
"semi": 2,
122+
"semi-spacing": [
123+
2,
124+
{
125+
"before": false,
126+
"after": true
127+
}
128+
],
129+
"space-return-throw-case": 2
130+
}
131+
}

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* text=auto

.gitignore

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
node_modules
2+
coverage
3+
.idea
4+
*.iml
5+
atlassian-ide-plugin.xml
6+
/.project
7+
test/temp/
8+
npm-debug.log

.travis.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
os:
2+
- linux
3+
language: node_js
4+
node_js:
5+
- "4.5.0"
6+
before_install:
7+
- npm install -g npm
8+
install:
9+
- npm install
10+
- npm link
11+
- npm test

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
<a name="0.0.1"></a>
2+
## 0.0.1 (2017-01-02)
3+
4+
Initial release

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2016 Vincent Ogloblinsky
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 64 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,65 @@
1+
<p align="center">
2+
<a href="https://github.com/compodoc/compodoc" target="_blank"><img src="https://avatars3.githubusercontent.com/u/23202313" alt="Compodoc: The missing documentation tool for your Angular application" width="226"></a>
3+
</p>
4+
15
# generator-jhipster-compodoc
2-
:notebook_with_decorative_cover: JHipster module, additional compodoc support in your JHipster application
6+
[![NPM version][npm-image]][npm-url]
7+
[![Dependency Status][daviddm-image]][daviddm-url]
8+
> JHipster module, additional [compodoc](https://github.com/compodoc/compodoc) support in your JHipster application
9+
10+
<p align="center">
11+
<img src="https://raw.githubusercontent.com/compodoc/generator-jhipster-compodoc/master/screenshots/main-view.png" alt="Compodoc: The missing documentation tool for your Angular application">
12+
</p>
13+
14+
# Introduction
15+
16+
This is a [JHipster](http://jhipster.github.io/) module, that is meant to be used in a JHipster application.
17+
18+
# Prerequisites
19+
20+
This module requires Jhipster version greater than 3.0.0 in order to work.
21+
22+
As this is a [JHipster](http://jhipster.github.io/) module, we expect you have JHipster and its related tools already installed:
23+
24+
- [Installing JHipster](https://jhipster.github.io/installation.html)
25+
26+
# Installation
27+
28+
To install this module :
29+
30+
```bash
31+
npm install -g generator-jhipster-compodoc
32+
```
33+
34+
# Usage
35+
36+
Run the module on your JHipster generated application :
37+
38+
```bash
39+
yo jhipster-compodoc
40+
```
41+
42+
Due to a limitation of yeoman about file override, you will have to accept the overwrite question.
43+
44+
```bash
45+
conflict package.json
46+
? Overwrite package.json? (Ynaxdh)
47+
```
48+
49+
Enjoy compodoc in your Angular application
50+
51+
```bash
52+
npm run doc
53+
```
54+
55+
# License
56+
57+
MIT © [Vincent Ogloblinsky]
58+
59+
60+
[npm-image]: https://img.shields.io/npm/v/generator-jhipster-compodoc.svg
61+
[npm-url]: https://npmjs.org/package/generator-jhipster-compodoc
62+
[travis-image]: https://travis-ci.org/compodoc/generator-jhipster-compodoc.svg?branch=master
63+
[travis-url]: https://travis-ci.org/compodoc/generator-jhipster-compodoc
64+
[daviddm-image]: https://david-dm.org/compodoc/generator-jhipster-compodoc.svg?theme=shields.io
65+
[daviddm-url]: https://david-dm.org/compodoc/generator-jhipster-module

generators/app/index.js

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
'use strict';
2+
var yeoman = require('yeoman-generator');
3+
var chalk = require('chalk');
4+
var packagejs = require(__dirname + '/../../package.json');
5+
6+
// Stores JHipster variables
7+
var jhipsterVar = {moduleName: 'compodoc'};
8+
9+
// Stores JHipster functions
10+
var jhipsterFunc = {};
11+
12+
module.exports = yeoman.Base.extend({
13+
14+
initializing: {
15+
compose: function (args) {
16+
this.composeWith('jhipster:modules',
17+
{
18+
options: {
19+
jhipsterVar: jhipsterVar,
20+
jhipsterFunc: jhipsterFunc
21+
}
22+
},
23+
this.options.testmode ? {local: require.resolve('generator-jhipster/generators/modules')} : null
24+
);
25+
},
26+
displayLogo: function () {
27+
// Have Yeoman greet the user.
28+
this.log('Welcome to the JHipster compodoc generator! ' + chalk.blue('v' + packagejs.version + '\n'));
29+
}
30+
},
31+
32+
writing: {
33+
writeTemplates : function () {
34+
jhipsterFunc.addNpmDevDependency('compodoc', '0.0.26');
35+
jhipsterFunc.addNpmScript('doc', './node_modules/.bin/compodoc -p src/tsconfig.json');
36+
},
37+
38+
registering: function () {
39+
try {
40+
jhipsterFunc.registerModule("generator-jhipster-compodoc", "entity", "post", "app", "JHipster module, additional compodoc support in your JHipster application");
41+
} catch (err) {
42+
this.log(chalk.red.bold('WARN!') + ' Could not register as a jhipster entity post creation hook...\n');
43+
}
44+
}
45+
},
46+
47+
install: function () {
48+
this.npmInstall();
49+
},
50+
51+
end: function () {
52+
this.log('End of JHipster compodoc generator');
53+
this.log(' Run compodoc using npm scripts :');
54+
this.log(' > npm run doc');
55+
}
56+
});

0 commit comments

Comments
 (0)