Skip to content

Commit 020bfaa

Browse files
committed
Merge pull request #1253 from kingcody/fix/generator-options
fix(gen): expose `skip-install` option and improve usage docs
2 parents e9e8c9f + 49c6a26 commit 020bfaa

File tree

3 files changed

+57
-3
lines changed

3 files changed

+57
-3
lines changed

Diff for: app/USAGE

+21-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,24 @@
11
Description:
2-
Creates an full-stack AngularJS + Node app
2+
Creates a Full-Stack AngularJS + Node app
33

44
Example:
5-
yo angular-fullstack
5+
yo angular-fullstack
6+
7+
Sub Generators:
8+
9+
Server Side:
10+
angular-fullstack:endpoint
11+
12+
Client Side:
13+
angular-fullstack:route
14+
angular-fullstack:controller
15+
angular-fullstack:filter
16+
angular-fullstack:directive
17+
angular-fullstack:service
18+
angular-fullstack:provider
19+
angular-fullstack:factory
20+
angular-fullstack:decorator
21+
22+
Deployment:
23+
angular-fullstack:openshift
24+
angular-fullstack:heroku

Diff for: app/generator.js

+6-1
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,15 @@ export default class Generator extends Base {
1313

1414
this.argument('name', { type: String, required: false });
1515

16+
this.option('skip-install', {
17+
desc: 'Do not install dependencies',
18+
type: Boolean,
19+
defaults: false
20+
});
21+
1622
this.option('app-suffix', {
1723
desc: 'Allow a custom suffix to be added to the module name',
1824
type: String,
19-
required: 'false',
2025
defaults: 'App'
2126
});
2227
}

Diff for: readme.md

+30
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,21 @@ Available generators:
8484
### App
8585
Sets up a new AngularJS + Express app, generating all the boilerplate you need to get started.
8686

87+
Usage:
88+
```bash
89+
Usage:
90+
yo angular-fullstack:app [options] [<name>]
91+
92+
Options:
93+
-h, --help # Print the generator's options and usage
94+
--skip-cache # Do not remember prompt answers Default: false
95+
--skip-install # Do not install dependencies Default: false
96+
--app-suffix # Allow a custom suffix to be added to the module name Default: App
97+
98+
Arguments:
99+
name Type: String Required: false
100+
```
101+
87102
Example:
88103
```bash
89104
yo angular-fullstack
@@ -92,6 +107,21 @@ yo angular-fullstack
92107
### Endpoint
93108
Generates a new API endpoint.
94109

110+
Usage:
111+
```bash
112+
Usage:
113+
yo angular-fullstack:endpoint [options] <name>
114+
115+
Options:
116+
-h, --help # Print the generator's options and usage
117+
--skip-cache # Do not remember prompt answers Default: false
118+
--route # URL for the endpoint
119+
--models # Specify which model(s) to use
120+
--endpointDirectory # Parent directory for enpoints
121+
122+
Arguments:
123+
name Type: String Required: true
124+
```
95125

96126
Example:
97127
```bash

0 commit comments

Comments
 (0)