Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include version number into report and filename #107

Closed
fairking opened this issue Jun 2, 2023 · 5 comments
Closed

Include version number into report and filename #107

fairking opened this issue Jun 2, 2023 · 5 comments
Labels

Comments

@fairking
Copy link

fairking commented Jun 2, 2023

Hi everyone,

Is the any way to include the version number to the report and filename?

For example the following command:

java -jar "..\..\Utils\SwaggerBrake\swagger-brake-2.3.0-cli.jar" --old-api=schema_old.json --new-api=schema.json --output-formats=HTML --output-path=.\

Would generate the following file: swagger-brake-1.0.1.html. and the version also included into the document itself:
image

The version number is determined by the schema.json (see info.version)

{
  "openapi": "3.0.1",
  "info": {
    "title": "My Project API",
    "description": "Ground breaking software",
    "version": "1.0.1"
  },

It would be also nice to customize the report filename as well (eg. my-project-breaking-changes.html).

Thanks.

@galovics
Copy link
Member

galovics commented Jun 3, 2023

Hi @fairking. Currently you can't customize the report and the name of the report file although it shouldn't be a big deal to implement those things.

Before we do that, would you mind explaining a bit your use-case?
Thanks

@fairking
Copy link
Author

Hi @fairking. Currently you can't customize the report and the name of the report file although it shouldn't be a big deal to implement those things.

Before we do that, would you mind explaining a bit your use-case? Thanks

I am generating a report on every release so I would like to keep a history of all report versions and also I am sharing such reports among third parties. So the version number would be a very useful hint for reference.
I know I can rename the file name but having a version number inside the report would be very beneficial.

@galovics
Copy link
Member

Noted, thanks @fairking for the explanation.

@galovics
Copy link
Member

Will look like this:
image

@galovics
Copy link
Member

Done in #115

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants