Skip to content

Commit 6a4aed9

Browse files
authored
[javascript][client] Add gitignore to template (#7438)
* [javascript][client] add gitignore template file * [javascript][client] update samples
1 parent 6909c88 commit 6a4aed9

File tree

5 files changed

+72
-2
lines changed

5 files changed

+72
-2
lines changed

modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/JavascriptClientCodegen.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,8 @@ public class JavascriptClientCodegen extends DefaultCodegen implements CodegenCo
5858
new String[]{"git_push.sh.mustache", "git_push.sh"},
5959
new String[]{"README.mustache", "README.md"},
6060
new String[]{"mocha.opts", "mocha.opts"},
61-
new String[]{"travis.yml", ".travis.yml"}
61+
new String[]{"travis.yml", ".travis.yml"},
62+
new String[]{"gitignore.mustache", ".gitignore"}
6263
};
6364

6465
final String[][] JAVASCRIPT_ES6_SUPPORTING_FILES = new String[][]{
@@ -69,7 +70,8 @@ public class JavascriptClientCodegen extends DefaultCodegen implements CodegenCo
6970
new String[]{"README.mustache", "README.md"},
7071
new String[]{"mocha.opts", "mocha.opts"},
7172
new String[]{"travis.yml", ".travis.yml"},
72-
new String[]{".babelrc.mustache", ".babelrc"}
73+
new String[]{".babelrc.mustache", ".babelrc"},
74+
new String[]{"gitignore.mustache", ".gitignore"}
7375
};
7476

7577
protected String projectName;
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
6+
# Runtime data
7+
pids
8+
*.pid
9+
*.seed
10+
11+
# Directory for instrumented libs generated by jscoverage/JSCover
12+
lib-cov
13+
14+
# Coverage directory used by tools like istanbul
15+
coverage
16+
17+
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
18+
.grunt
19+
20+
# node-waf configuration
21+
.lock-wscript
22+
23+
# Compiled binary addons (http://nodejs.org/api/addons.html)
24+
build/Release
25+
26+
# Dependency directory
27+
node_modules
28+
29+
# Optional npm cache directory
30+
.npm
31+
32+
# Optional REPL history
33+
.node_repl_history

samples/client/petstore/javascript-es6/.openapi-generator/FILES

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
.babelrc
2+
.gitignore
23
.travis.yml
34
README.md
45
docs/AdditionalPropertiesClass.md
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
# Logs
2+
logs
3+
*.log
4+
npm-debug.log*
5+
6+
# Runtime data
7+
pids
8+
*.pid
9+
*.seed
10+
11+
# Directory for instrumented libs generated by jscoverage/JSCover
12+
lib-cov
13+
14+
# Coverage directory used by tools like istanbul
15+
coverage
16+
17+
# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
18+
.grunt
19+
20+
# node-waf configuration
21+
.lock-wscript
22+
23+
# Compiled binary addons (http://nodejs.org/api/addons.html)
24+
build/Release
25+
26+
# Dependency directory
27+
node_modules
28+
29+
# Optional npm cache directory
30+
.npm
31+
32+
# Optional REPL history
33+
.node_repl_history

samples/client/petstore/javascript-promise-es6/.openapi-generator/FILES

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
.babelrc
2+
.gitignore
23
.travis.yml
34
README.md
45
docs/AdditionalPropertiesClass.md

0 commit comments

Comments
 (0)