Skip to content

Commit

Permalink
Update sphinx-autobuild command to disable incremental builds and wat…
Browse files Browse the repository at this point in the history
…ch source directories for changes
  • Loading branch information
JWCook committed Aug 1, 2021
1 parent 25bbffa commit 4e708f0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

LIVE_DOCS_PORT = 8181
LIVE_DOCS_IGNORE = ['*.csv', '**/modules/*']
LIVE_DOCS_WATCH = ['pyinaturalist', 'examples/*.py']
CLEAN_DIRS = ['dist', 'build', join('docs', '_build'), join('docs', 'models'), join('docs', 'modules')]


Expand Down Expand Up @@ -53,7 +54,9 @@ def livedocs(session):
"""Auto-build docs with live reload in browser.
Add `-- open` to also open the browser after starting.
"""
args = [f'--ignore {pattern}' for pattern in LIVE_DOCS_IGNORE]
args = ['-a']
args += [f'--watch {pattern}' for pattern in LIVE_DOCS_WATCH]
args += [f'--ignore {pattern}' for pattern in LIVE_DOCS_IGNORE]
args += [f'--port {LIVE_DOCS_PORT}', '-j auto']
if session.posargs == ['open']:
args.append('--open-browser')
Expand Down

0 comments on commit 4e708f0

Please sign in to comment.