Comments (2)
I'm also on this!
My scenario: I'm writing a swagger for different enviroments (local, test, production) so with different url.
Problem: because I'm not able to find a proper way to specify which enviroment generator plugin should generate for, I'm using gradle profiles to search for file with host reference and update them, for example:
on build.gradle:
// apply enviroment properties, used on command line with gradle -PbuildProfile=test clean build
if (!hasProperty('buildProfile')) ext.buildProfile = 'default'
apply from: "profile-${buildProfile}.gradle"
my test profile file:
// Test enviroment properties (for deploy on AWS test machine)
war {
// apply on swagger-ui to change localhost:8080 to host:port
rootSpec.eachFile {
if (it.name == 'swagger-spec.js') {
filter { line ->
line.replace('localhost:8080', "testhost.com")
}
}
}
}
Request: there is a proper way to override host, port and basepath like @radai-rosenblatt requested, directly in this plugin ?
from gradle-swagger-generator-plugin.
You can override index.html as https://github.com/int128/gradle-swagger-generator-plugin#configure-swagger-ui since version 2.10.0.
from gradle-swagger-generator-plugin.
Related Issues (20)
- Unexpected Char รขโฌโน
- A Release hasn't been made since Feb 2020. Missing OAS3 verification which is in master HOT 1
- Android Studio 2020.3.1 (latest stable) requires Gradle 7 + tweaks to plugin HOT 1
- Dependency Dashboard
- Action Required: Fix Renovate Configuration
- The latest release no longer supports Java 11 HOT 3
- JAVA 8 support for the plugin HOT 3
- False usage of gradle cache on new code generator version HOT 1
- No duplicate handling strategy has been set for task resolveSwaggerTemplate HOT 2
- Plugin generates new files despite the inputFiles are not changed since the last generation
- Can't generate SwaggerUI with plugin version 2.19.2 HOT 2
- New versions are not compatible with gradle 6.x
- Problem generating Java code with schema property "oneOf"
- Move to latest Gradle API and best practices HOT 5
- Response for Controller with type of "Map of Map" is not properly generated.
- oneOf Polymorphism Broken
- Using `resttemplate` and `useBeanValidation` does not include `validation-api` HOT 1
- Support jakarta imports HOT 1
- Question: Please could you indicate how to generate the client code? HOT 1
- Configuration cache HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gradle-swagger-generator-plugin.