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

Add include and exclude options. #16

Closed
wants to merge 1 commit into from

Conversation

jmbarbier
Copy link

@jmbarbier jmbarbier commented Dec 20, 2017

For more control over openapi directive than the rather restrictive pathsoption, this PR adds include and exclude options that allow specifying paths to include / exclude using regular expressions.

.. openapi:: api.yaml
   :include:  /person.*

to render /person, /person/{pk}, /person/{pk}/changepw ... This allows splitting a big api specs file into small logical parts within the docs.

It also adds a local cache for deserialized specs to speedup openapi directive reuse.

Add local cache for specs file to speedup processing of multiple openapi directives using same spec file.
@ikalnytskyi
Copy link
Member

Hey @jmbarbier! Thanks for the pull request.

  • Can you please rebase this on top on master in order to pass the tests?
  • Can you please split the PR into 2: one that implements include/exclude, one that implements caching?

@stephenfin stephenfin mentioned this pull request Dec 7, 2018
tuffnatty added a commit to tuffnatty/sphinxcontrib-openapi that referenced this pull request Sep 3, 2019
tuffnatty added a commit to tuffnatty/sphinxcontrib-openapi that referenced this pull request Sep 3, 2019
ikalnytskyi added a commit that referenced this pull request Oct 5, 2019
Cache deserialized specs to speedup openapi directive reuse (rework #16)
ikalnytskyi added a commit that referenced this pull request Oct 5, 2019
Add include and exclude options (reworked #16)
@ikalnytskyi ikalnytskyi closed this Oct 5, 2019
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

Successfully merging this pull request may close these issues.

2 participants