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

Needs to copy yaml files manually if openapi.yaml is not placed at the repository root #483

Open
watanabe-pfr opened this issue Jul 22, 2024 · 1 comment

Comments

@watanabe-pfr
Copy link

Thank you for providing a great tool.

Please support the relative path based on the position of openapi.yaml .

If the openapi.yaml is not placed at the repository root, like below,
the deployed pages cannot access to the parts directory with relative path.

.
├── interface
│   ├── README.md
│   └── v1
│       ├── openapi.yaml
│       └── parts
│           ├── part1.yaml
│           ├── part2.yaml
│           └── part3.yaml
└── README.md

It can be resolved with manual copy:

- name: Copy OpenAPI files
        run: |
          mkdir -p swagger-ui/parts
          cp interface/v1/openapi.yaml swagger-ui/
          cp interface/v1/parts/*.yaml swagger-ui/parts/

It'll be more intuitive if the build output is generated based on the path of openapi.yaml
Thank you.

@Legion2
Copy link
Owner

Legion2 commented Jul 22, 2024

I think the problem here is that currently only the openapi.yaml file is copied automatically. Other files must be manually copied to the correct place in the generated swagger ui output.

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

No branches or pull requests

2 participants