Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
5976 commits
Select commit Hold shift + click to select a range
3ac1c2e
[TypeScript] fix array enum (#3538)
wing328 Aug 9, 2016
7805448
Amending Path annotation (#3553)
rynger Aug 9, 2016
760feef
Merge pull request #3550 from jimschubert/aspnet/models-casing
wing328 Aug 9, 2016
139437a
Merge branch 'patch-1' of https://github.com/kartenkarsten/swagger-co…
wing328 Aug 9, 2016
5f72d85
minor indentation fix for java enum models
wing328 Aug 9, 2016
51576cc
update sampel for spring petstore
wing328 Aug 9, 2016
1880120
Merge branch 'beingcoder-top-enum-error-securityscope-newline-error'
wing328 Aug 9, 2016
df57f4a
Merge branch 'master' of https://github.com/swagger-api/swagger-codegen
wing328 Aug 9, 2016
e4003ea
Fix unknown parameter on api_client's update_params_for_auth method.
cliffano Aug 9, 2016
8bff0d3
Merge pull request #3559 from wing328/java_jersey_indent
wing328 Aug 9, 2016
ce0f78d
add new java client files
wing328 Aug 9, 2016
7ff9ab0
fix form enum parameters for spring generator, add more test cases
wing328 Aug 9, 2016
d5ad1cf
typo
kartenkarsten Aug 9, 2016
c965b43
sample update
kartenkarsten Aug 9, 2016
2450f67
Merge pull request #3564 from cliffano/fix-incorrect-param-update-par…
wing328 Aug 9, 2016
9df4689
Merge pull request #3562 from wing328/add_enum_endpoint
wing328 Aug 9, 2016
884dfdd
[Go] Fix CI tests (#3569)
wing328 Aug 10, 2016
e728b84
[Go] prefix go local var with localVar (#3570)
wing328 Aug 10, 2016
7403f5b
[htmlDoc2] curl sample - conditionally add 'apiKey'. (#3561)
Aug 10, 2016
90f596e
Go: Replace `.Username` with `.UserName` in generated API methods.
ivucica Aug 9, 2016
098c7dc
Merge pull request #3573 from ivucica/ivucica_go_fix-username-capital…
wing328 Aug 11, 2016
b46b0c2
[Go] Add more test cases and fix numeric form/header parameters (#3574)
wing328 Aug 11, 2016
484d989
Merge pull request #1 from swagger-api/master
andylowry Aug 11, 2016
8da96db
Issue 3572 Remove dupe options in jaxrs-spec
andylowry Aug 11, 2016
f37e142
Fix Javascript types
arikon Aug 11, 2016
979c5d2
Merge branch 'feature/jack/update-swift-alamofire' of https://github.…
wing328 Aug 12, 2016
14447e6
Merge branch 'JackWink-feature/jack/update-swift-alamofire'
wing328 Aug 12, 2016
db6b873
Merge branch 'feature/js-fix-types' of https://github.com/arikon/swag…
wing328 Aug 12, 2016
bdd9c2b
update JS test cases
wing328 Aug 12, 2016
4718903
Merge branch 'arikon-feature/js-fix-types'
wing328 Aug 12, 2016
3bd16c0
Merge pull request #3576 from ModelSolv/issue-3572
wing328 Aug 12, 2016
d7a55fe
Merge branch 'csharp/INotifyPropertyChanged' of https://github.com/ji…
wing328 Aug 12, 2016
b154e66
Merge branch 'patch-1' of https://github.com/kartenkarsten/swagger-co…
wing328 Aug 12, 2016
88580c4
update java jersey1 sample
wing328 Aug 12, 2016
c618b81
Merge branch 'kartenkarsten-patch-1'
wing328 Aug 12, 2016
7c203fe
Merge branch 'master' of https://github.com/swagger-api/swagger-codegen
wing328 Aug 12, 2016
b599d54
add symbolic enum support to csharp
wing328 Aug 12, 2016
d6ef2bb
Adding support for JMustache compiler customization
Aug 12, 2016
f7e4e3c
Fix resteasy offsetdatetime provier (#3332)
chameleon82 Aug 15, 2016
67f4227
Create setter for models inline with Issue 3210
scottrw93 Aug 15, 2016
28d57f5
Merge pull request #3582 from regga-ws/compiler-customization
wing328 Aug 16, 2016
b22ac87
Merge pull request #3591 from scottrw93/read-only-fix
wing328 Aug 16, 2016
3819873
Fix typo, descripton -> description
MikeRalphson Aug 16, 2016
ff36a3d
added configuration for swagger-yaml output file, #3597
fehguy Aug 16, 2016
641fd14
Merge pull request #3598 from swagger-api/issue-3597
fehguy Aug 16, 2016
9919159
Don't escape path in generated okhttp-gson client code
ggood Aug 17, 2016
6fa160e
Merge pull request #3595 from MikeRalphson/patch-1
wing328 Aug 17, 2016
90ef281
update to version 2.2.2
michalyao Aug 17, 2016
9ef3c60
Merge pull request #3599 from ggood/okhttp-gson-template-path-fix
wing328 Aug 17, 2016
6ac4c58
Modify the url of the swagger-codegen-cli.jar (#3600)
michalyao Aug 17, 2016
2f10277
Merge branch 'issue-3461-configurable-transport' of https://github.co…
wing328 Aug 17, 2016
bca4bda
update go petstore sample
wing328 Aug 17, 2016
b738ceb
Merge branch 'neilotoole-issue-3461-configurable-transport'
wing328 Aug 17, 2016
db8f54a
Merge branch 'master' of https://github.com/swagger-api/swagger-codegen
wing328 Aug 17, 2016
f1cde03
update to version 2.2.2
michalyao Aug 18, 2016
1e9c53d
[Java][Inflector] Fix enum issue with java inflector (#3606)
wing328 Aug 18, 2016
6dd96b0
Merge pull request #3602 from michalyao/patch-2
wing328 Aug 18, 2016
cfc6859
Merge pull request #3610 from michalyao/master
wing328 Aug 18, 2016
4aa0fc0
Uses this.{{name}} to scope instance
Aug 19, 2016
1385e1c
[Spring Boot] use port defined in spec file for server.port value (#3…
kevinchabreck Aug 19, 2016
88b19ea
[Java][Spring][Inflector][Jax-RS] To fix various enum issues (#3615)
wing328 Aug 20, 2016
0895a33
update wording
wing328 Aug 21, 2016
d7d1424
Allowing generators to be aware of original inputSpec path (#3592)
regga-ws Aug 22, 2016
a12b9e3
add function to handle missing delimiter in regex
wing328 Aug 22, 2016
6023460
Merge pull request #3623 from wing328/ruby_better_pattern
wing328 Aug 22, 2016
7914b03
For Qt5 server generator, add BaseIntegerProperty to default values (…
YetAnotherMinion Aug 22, 2016
c196701
inject base_path opaque token for typescript angular2 (#3514)
damienpontifex Aug 22, 2016
fdda72f
[Swift] Include HTTP status code and body data in response errors
Jul 12, 2016
9c412c9
Adds flattener for ComposedModel
Aug 22, 2016
4d07232
[Swift] Handle Void responses
jgavris Aug 23, 2016
20c523d
[Swift] Handle String responses
jgavris Aug 23, 2016
080cb58
add http://www.plexxi.com/
wing328 Aug 24, 2016
886eba1
Merge pull request #3624 from ButterflyNetwork/swift-better-errors
wing328 Aug 24, 2016
612252d
fix #3477, add RxSwift support for Swift (#3490)
wwwjfy Aug 25, 2016
699b841
Merge pull request #3626 from medallia/flatten-composed-model
wing328 Aug 25, 2016
7d6aef8
Merge branch 'mikesol-patch-android-classVarName' of https://github.c…
wing328 Aug 25, 2016
0083b6a
update android petstore sample, add this to volley's model
wing328 Aug 25, 2016
e4493ff
Merge branch 'mikesol-mikesol-patch-android-classVarName'
wing328 Aug 25, 2016
702b18a
Merge branch 'master' of https://github.com/swagger-api/swagger-codegen
wing328 Aug 25, 2016
04c9b38
add emc
wing328 Aug 25, 2016
5ab2b5a
add QuantiModo
wing328 Aug 26, 2016
7c6ab82
[Go] fixing code gen not recognizing 'object' type issue
guohuang Aug 26, 2016
c322a64
Spelling fixes
scop Aug 26, 2016
14be018
Merge pull request #3649 from scop/spelling
wing328 Aug 27, 2016
48a6f00
java: Fix model package import in example
scop Aug 27, 2016
593b0ea
Perl example fixes (#3652)
scop Aug 28, 2016
7bb1154
update petl sample
wing328 Aug 28, 2016
3a2edc1
add new perl petstore files
wing328 Aug 28, 2016
7d842ff
Merge pull request #3653 from scop/java
wing328 Aug 28, 2016
b8dc6de
Angular2 rc5 (#3603)
sebastianhaas Aug 28, 2016
960308b
perl: Sync default user agent with other languages
scop Aug 28, 2016
4a9ee78
Merge pull request #3655 from scop/perl-user-agent
wing328 Aug 28, 2016
22879ca
Spelling fixes
scop Aug 28, 2016
a677271
Merge pull request #3656 from scop/spelling
wing328 Aug 28, 2016
0430faa
Fix to case of propertyClass which pukes on most checkstyle rules in …
brentryan Aug 29, 2016
5c7f412
Merge pull request #3657 from cvent/cvent-fixes
wing328 Aug 29, 2016
7369204
Merge pull request #3645 from guohuang/compile_issue2
wing328 Aug 29, 2016
90ca44b
[android] volley socket timeout configurable (#3646)
sidhantgoyal Aug 29, 2016
de82c33
Fix empty model object serialization in python client
zbiro Aug 29, 2016
752eab4
regenerate petstore sample
zbiro Aug 29, 2016
fc17fc1
fixing python code formatting issue
zbiro Aug 29, 2016
97e6a94
add PR template (#3669)
wing328 Aug 29, 2016
43774f0
Various python cleanups (#3650)
scop Aug 30, 2016
8762aa1
Make connection failures visible with generated Ruby SDKs (#3640)
DanGe42 Aug 30, 2016
0039846
php: Do not HTML escape patterns
scop Aug 29, 2016
350d0f8
php: Update petstore
scop Aug 29, 2016
7ceacd6
lumen: Do not HTML escape pattern
scop Aug 29, 2016
cf792f5
lumen: Update petstore
scop Aug 29, 2016
b4348f4
python: Fix escaping of quote in patterns
scop Aug 29, 2016
db1f5dd
python: Do not HTML escape patterns
scop Aug 29, 2016
7445756
python: Update petstore
scop Aug 30, 2016
e08d497
Merge branch 'issue-3647' of https://github.com/zbiro/swagger-codegen…
wing328 Aug 30, 2016
6723ff2
Merge branch 'zbiro-issue-3647'
wing328 Aug 30, 2016
1021bd9
clearer wording
wing328 Aug 31, 2016
bfa84b6
Merge branch 'python-patterns' of https://github.com/scop/swagger-cod…
wing328 Aug 31, 2016
9d4bc22
Merge branch 'scop-python-patterns'
wing328 Aug 31, 2016
866185d
Don't HTML escape PHP pattern output (#3672)
wing328 Aug 31, 2016
d885c5c
remove unnecessary changes for python codegen
wing328 Aug 31, 2016
f7823ed
remove unnecessary change for ruby codegen
wing328 Aug 31, 2016
c27462f
remove unnecessary changes for php codegen
wing328 Aug 31, 2016
ad8f321
add hided timestamp option to swfit codegen
wing328 Aug 31, 2016
ddc1bbb
remove unnecesary change in JS codegen
wing328 Aug 31, 2016
8530580
remove unnecessary change in JS closure codegen
wing328 Aug 31, 2016
b6b2ceb
remove unnecessary change for c# codegen
wing328 Aug 31, 2016
5406de5
fix JS auth issue due to missig comma
wing328 Aug 31, 2016
7ed27b7
Remove unnecessary change when generating API clients (#3684)
wing328 Aug 31, 2016
aa04882
Python fixes (#3689)
scop Sep 1, 2016
8e07e42
Added functionality to handle optional parameters for Scala (#3683)
Sep 1, 2016
2092434
Added 'modelPropertyNaming' option for Scala (#3685)
Sep 1, 2016
cb8a189
Spelling fixes
scop Sep 1, 2016
24c64a6
java: Javadoc fixes
scop Sep 1, 2016
8f6c559
Merge pull request #3698 from scop/spelling
wing328 Sep 1, 2016
3f3e043
[Scalatra] replace {} with : in scalatra path (#3694)
wing328 Sep 1, 2016
59eeda5
Merge pull request #3699 from scop/java
wing328 Sep 1, 2016
bf4553c
ruby: Fix syntax error when pattern contains a single quote
scop Sep 1, 2016
2afe783
php: Fix syntax error when pattern contains a single quote
scop Sep 1, 2016
5d1109b
Python collection formatting fixes/support (#3697)
scop Sep 2, 2016
b676d39
Merge pull request #3702 from scop/ruby
wing328 Sep 2, 2016
a7682d2
#3690 adding RequestURL, Method, Operation and Payload fields to APIR…
neilotoole Sep 2, 2016
bdeed20
[PHP] Corrected PHPDoc type declarations (#3710)
Sep 3, 2016
c242aad
Merge pull request #3700 from scop/php
wing328 Sep 3, 2016
3a7fb60
[Ruby] Fix ambiguous regex (#3716)
camelmasa Sep 5, 2016
66e179c
update ruby regular expression to use \A
wing328 Sep 5, 2016
1e4e1b5
Merge pull request #3721 from wing328/update_ruby_re
wing328 Sep 5, 2016
f43fdfb
Issue #3687 silence resty logging [Go] (#3705)
neilotoole Sep 5, 2016
ff421ef
fix map usage in api generation #3694 (#3714)
ataraxus Sep 6, 2016
df42bd4
[Lumen, PHP, Python, Ruby] Implement exclusiveMinimum/Maximum (#3717)
scop Sep 6, 2016
7db70a4
add back test cases for java jersey1 client
wing328 Sep 6, 2016
2a0ad89
Merge pull request #3728 from wing328/java_default_test
wing328 Sep 6, 2016
4ba3aa5
Spelling fixes
scop Sep 6, 2016
2751799
python: Fix model maxLength validation error message
scop Sep 6, 2016
8a5db9a
[ruby] Add gemspec required_ruby_version setting. (#3718)
cliffano Sep 6, 2016
d823077
Merge pull request #3729 from scop/spelling
wing328 Sep 7, 2016
c9977fe
Various code cleanups (#3709)
scop Sep 7, 2016
d44574b
Merge pull request #3730 from scop/python-maxlength-msg
wing328 Sep 7, 2016
bfc913e
fix property name 'result' for android using "this"
wing328 Sep 7, 2016
b176d9e
Merge pull request #3740 from wing328/android_fix_result
wing328 Sep 7, 2016
4db288c
fix enum value issue for jaxrs cxf
wing328 Sep 8, 2016
7bc002a
[Python, Ruby, PHP] Validate min/maxItems (#3734)
scop Sep 8, 2016
3dd047c
Merge pull request #3750 from wing328/fix_jaxrs_cxf_model
wing328 Sep 8, 2016
d4d3f51
Issue #3738: regenerate Scala samples (no code changes).
ePaul Sep 8, 2016
a7dddc5
Merge pull request #3752 from ePaul/feature/#3738-regenerate-scala-sa…
wing328 Sep 8, 2016
03d53e6
Added anchor tag in README.mustache issue #3748.
lunat Sep 8, 2016
e0814e7
[Erlang] Add Erlang server generator (#3758)
galaxie Sep 9, 2016
e917e65
add Erlang Server | @galaxie
wing328 Sep 9, 2016
6435eb2
rearrange erlang server
wing328 Sep 9, 2016
f62b1c6
erlang update readme, add petstore samples
wing328 Sep 9, 2016
429df38
Merge pull request #3763 from wing328/erlang_server_improve
wing328 Sep 9, 2016
818f6cd
Merge pull request #3756 from lunat/csharp_documentation_relative_anchor
wing328 Sep 9, 2016
7758433
add tips for filing better PR
wing328 Sep 9, 2016
c4c4fdc
Update CONTRIBUTING.md
wing328 Sep 9, 2016
9f68be4
Fix appveyor maven environment variable (#3769)
wing328 Sep 11, 2016
cb6fbb2
Feature/#3738 extract abstract scala codegen (#3755)
ePaul Sep 11, 2016
96a65aa
better format of model properties
wing328 Sep 11, 2016
6e48e21
Fix for issue #3743 (#3744)
ataraxus Sep 11, 2016
377a20b
Issue #3738: introduce the sourceFolder property for all Scala "langu…
ePaul Sep 8, 2016
27092ff
Feature/remove unused variables in html codegens (#3739)
ePaul Sep 12, 2016
9d004ee
Fix for #3712 - invalid enum array validation in Python client mustac…
bkryza Sep 12, 2016
bc10e58
Merge pull request #3757 from ePaul/feature/#3738-add-sourceFolder-pr…
wing328 Sep 12, 2016
7a433a7
Merge pull request #3772 from wing328/scala_model_indent
wing328 Sep 12, 2016
5ca099a
apiInvoker : in getInstance, if instance is null initialize instance …
Richou Sep 12, 2016
91bbb23
Make InlineModelResolver resolve vendorExtensions correctly for Schem…
zhengcan Sep 12, 2016
d045487
Add last response code and headers (#3760)
Sep 12, 2016
a45f441
update typescript-angular2 petstore sample
wing328 Sep 12, 2016
fbd6ac6
Merge pull request #3778 from wing328/update_ts_angular2_petstore
wing328 Sep 12, 2016
be6c0ea
[Scala] enhancement to indention and null check (#3775)
wing328 Sep 13, 2016
154a73a
Merge branch 'jimschubert-csharp/INotifyPropertyChanged'
wing328 Sep 13, 2016
a13eac3
Merge branch 'csharp_fix_enum' of https://github.com/wing328/swagger-…
wing328 Sep 13, 2016
e11290e
Merge branch 'wing328-csharp_fix_enum'
wing328 Sep 13, 2016
18c7ba0
[C#] fix the location of FodyWeavers.xml (#3782)
wing328 Sep 13, 2016
475c249
[C#] Add CI tests to cover C# Petstore client with "PropertyChanged" …
wing328 Sep 14, 2016
423f5ec
Added !is_null condition in setter conditions for non-required proper…
xaviapa Sep 14, 2016
e53b052
Merge pull request #3797 from xaviapa/bugfix/issue-3783
wing328 Sep 14, 2016
aeda12c
[jmeter] #3800 Fixing testCases and paramName
richardfriedman Sep 14, 2016
2a0b7a5
add authentication to typescript-angular2 (#3781)
timadamson Sep 14, 2016
763c0f5
Fixed bug for handling optional header parameters (#3776)
geetikagupta16 Sep 15, 2016
9c2e067
Fix NullPointerException if there are no other properties
Sep 16, 2016
f1238a9
[typescript-angular2] npm publish missing files (#3791)
savcha Sep 19, 2016
b7e8f7c
Merge pull request #3809 from j4velin/master
wing328 Sep 19, 2016
d2300ec
Merge pull request #3801 from richardfriedman/issue-3800
wing328 Sep 19, 2016
fb27fd4
add petstore jmeter sample
wing328 Sep 19, 2016
46bcc17
Merge branch 'csharp/property-validations' of https://github.com/jims…
wing328 Sep 19, 2016
0533b1b
Merge pull request #3822 from wing328/jmeter_bin
wing328 Sep 19, 2016
c2f2d09
fix copmile for C# model annotation
wing328 Sep 19, 2016
f05fed1
Merge branch 'master' of https://github.com/swagger-api/swagger-codegen
wing328 Sep 19, 2016
a2d969f
Use triple mustache for vendorExtensions.extraAnnotation
wienczny Sep 19, 2016
533dc8d
Add a new language generator for undertow-server framework (#3820)
stevehu Sep 19, 2016
84457c9
add gotransverse
wing328 Sep 20, 2016
c28c0dc
Fixed typo in Readme
vkotovv Sep 20, 2016
a2ff168
[Python][Flask] use tags to organize Python Flask controllers (#3767)
wing328 Sep 20, 2016
ac4b71c
Merge pull request #3834 from vkotovv/readme-typo-fix
wing328 Sep 20, 2016
0c60216
Merge pull request #3825 from wienczny/tripleMustacheExtraAnnotation
wing328 Sep 20, 2016
20d9981
Fix NullPointerException when the oauth flow is missing
0xced Sep 20, 2016
9f56310
Merge pull request #3840 from 0xced/fix-oauth-flow-npe
wing328 Sep 21, 2016
d04fef4
fix typescript angular2 model - optional/required
wing328 Sep 21, 2016
592cf8c
Merge pull request #3843 from wing328/fix_ts_angular2_model_optional
wing328 Sep 21, 2016
af09447
add default value to swift podspec
wing328 Sep 22, 2016
027f183
[PHP] Correct Composer license identifier (#3848)
kimsondrup Sep 22, 2016
f467a7e
Merge pull request #3850 from wing328/fix_swift_pod_file
wing328 Sep 22, 2016
c486a3b
Fix custom generator execution example
Sep 22, 2016
797b2e8
Update README.md
jvosantos Sep 23, 2016
6418033
Merge pull request #3854 from jvosantos/patch-1
wing328 Sep 23, 2016
4ae5cb3
Merge pull request #3853 from mattalexx/proposed
wing328 Sep 23, 2016
be40d71
Support cpprest on Linux (#3847)
rustamserg Sep 23, 2016
26d5226
redundant quotation mark (#3837)
Sep 23, 2016
6effa4f
fix typescript-fetch base path by removing ending slash
wing328 Sep 23, 2016
49abdeb
Merge pull request #3855 from wing328/ts_fetch_basepath_fix
wing328 Sep 23, 2016
e8b7934
Merge branch 'issue-3690-additional-fields' of https://github.com/nei…
wing328 Sep 23, 2016
128d7a6
Merge branch 'neilotoole-issue-3690-additional-fields'
wing328 Sep 23, 2016
6e28109
Merge branch 'master' of https://github.com/swagger-api/swagger-codegen
wing328 Sep 23, 2016
8002a0a
fix trailing comma in go api client
wing328 Sep 23, 2016
f3902a5
Merge pull request #3857 from wing328/go_fix_trailing_comma
wing328 Sep 23, 2016
11efd2b
add title, description to HTML output (#3860)
Sep 24, 2016
c727e31
[JaxRS]Show correct default value on CLI option description (#3862)
y-higuchi Sep 24, 2016
3513c35
[swfit] fix url param with base name
wing328 Sep 26, 2016
b1607b0
Merge pull request #3868 from wing328/swift_fix_url_param
wing328 Sep 26, 2016
e6a1e18
Replace ^M with new line (\r) in mustache template (#3865)
wing328 Sep 26, 2016
bec7c48
[Swift] Use thread safe manager dictionary
jgavris Sep 23, 2016
d435448
Mention security script in pull request template
arnested Sep 26, 2016
0cbfa04
Merge pull request #3873 from ButterflyNetwork/swift-thread-safe-manager
wing328 Sep 26, 2016
72d6afc
[PHP] Better PSR2 compatibility (#3863)
dkarlovi Sep 27, 2016
87708d7
Merge pull request #3875 from arnested/mention-security-script-in-pul…
wing328 Sep 28, 2016
00110e9
[Java] Remove duplicated model description in Spring, JAX-RS models (…
wing328 Sep 28, 2016
5bd1069
[PHP] fix PHPUnit invocation, add basic phpunit.xml.dist (#3864)
dkarlovi Sep 28, 2016
1d14780
Excluding all nbactions.xml files.
MiguelGL Sep 28, 2016
93db4de
Add a command line action to print the program version.
MiguelGL Sep 28, 2016
5506f3b
Make CLI description include version information.
MiguelGL Sep 28, 2016
b78ad29
Merge remote-tracking branch 'upstream/master' into version-cli-command.
MiguelGL Sep 29, 2016
eb60c8c
Merge remote-tracking branch 'upstream/master'.
MiguelGL Sep 29, 2016
6301079
Merge branch 'master' into version-cli-command
MiguelGL Sep 29, 2016
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ out/
*.iws
classpath.txt
version.properties
!modules/swagger-codegen-cli/src/main/resources/version.properties
.project
.classpath
lib/*
Expand Down Expand Up @@ -33,7 +34,7 @@ packages/

/target
/generated-files
/nbactions.xml
nbactions.xml

# scalatra
samples/server-generator/scalatra/output
Expand Down
1 change: 1 addition & 0 deletions modules/swagger-codegen-cli/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
<resources>
<resource>
<directory>src/main/resources</directory>
<filtering>true</filtering>
<excludes>
<exclude>logback.xml</exclude>
</excludes>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
package io.swagger.codegen;

import static io.swagger.codegen.cmd.Version.UNKNOWN_VERSION;

import io.airlift.airline.Cli;
import io.airlift.airline.Help;
import io.swagger.codegen.cmd.ConfigHelp;
import io.swagger.codegen.cmd.Generate;
import io.swagger.codegen.cmd.Langs;
import io.swagger.codegen.cmd.Meta;
import io.swagger.codegen.cmd.Version;

/**
* User: lanwen
Expand All @@ -21,16 +24,20 @@ public class SwaggerCodegen {


public static void main(String[] args) {
String version = Version.readVersionFromResources().or(UNKNOWN_VERSION);
@SuppressWarnings("unchecked")
Cli.CliBuilder<Runnable> builder = Cli.<Runnable>builder("swagger-codegen-cli")
.withDescription("Swagger code generator CLI. More info on swagger.io")
.withDescription(String.format(
"Swagger code generator CLI (version %s). More info on swagger.io",
version))
.withDefaultCommand(Langs.class)
.withCommands(
Generate.class,
Meta.class,
Langs.class,
Help.class,
ConfigHelp.class
ConfigHelp.class,
Version.class
);

builder.build().parse(args).run();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import ch.lambdaj.function.convert.Converter;
import com.google.common.base.CaseFormat;
import com.google.common.base.Optional;
import com.google.common.collect.ImmutableList;
import com.google.common.collect.ImmutableMap;
import com.samskivert.mustache.Mustache;
Expand All @@ -21,6 +22,7 @@

import static ch.lambdaj.collection.LambdaCollections.with;
import static com.google.common.base.Joiner.on;
import static io.swagger.codegen.cmd.Version.UNKNOWN_VERSION;

/**
* User: lanwen
Expand Down Expand Up @@ -68,18 +70,14 @@ public void run() {
"src/main/resources/META-INF/services", "io.swagger.codegen.CodegenConfig")
);

String swaggerVersion = this.getClass().getPackage().getImplementationVersion();
// if the code is running outside of the jar (i.e. from the IDE), it will not have the version available.
// let's default it with something.
if (swaggerVersion==null) {
swaggerVersion = "2.1.3";
}
Optional<String> swaggerVersion = Version.readVersionFromResources();

Map<String, Object> data = new ImmutableMap.Builder<String, Object>()
.put("generatorPackage", targetPackage)
.put("generatorClass", mainClass)
.put("name", name)
.put("fullyQualifiedGeneratorClass", targetPackage + "." + mainClass)
.put("swaggerCodegenVersion", swaggerVersion).build();
.put("swaggerCodegenVersion", swaggerVersion.or(UNKNOWN_VERSION)).build();


with(supportingFiles).convert(processFiles(targetDir, data));
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
package io.swagger.codegen.cmd;

import java.io.IOException;
import java.io.InputStream;
import java.util.Properties;

import com.google.common.base.Optional;
import com.google.common.base.Preconditions;
import io.airlift.airline.Command;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

@Command(name = "version", description = "Show version information")
public class Version implements Runnable {

private static final Logger LOGGER = LoggerFactory.getLogger(Meta.class);

public static final String UNKNOWN_VERSION = "unknown";

public static Optional<String> readVersionFromResources() {
Properties versionProperties = new Properties();
try (InputStream is = Version.class.getResourceAsStream("/version.properties")) {
versionProperties.load(is);
} catch (IOException ex) {
LOGGER.error("Error loading version properties", ex);
return Optional.absent();
}
String version = versionProperties.getProperty("version");
return Optional.fromNullable(version);
}

@Override
public void run() {
Optional<String> version = readVersionFromResources();
Preconditions.checkState(version.isPresent(), "Version properties missing 'version' entry");
System.out.println(version.get());
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
version = ${project.version}
4 changes: 2 additions & 2 deletions samples/html/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -665,9 +665,9 @@ <h3 class="field-label">Return type</h3>
<h3 class="field-label">Example data</h3>
<div class="example-data-content-type">Content-Type: application/json</div>
<pre class="example"><code>{
"message" : "aeiou",
"code" : 123,
"type" : "aeiou"
"type" : "aeiou",
"message" : "aeiou"
}</code></pre>

<h3 class="field-label">Produces</h3>
Expand Down