parent
600a8e1f12
commit
1cda6ef109
2 changed files with 28 additions and 1 deletions
@ -0,0 +1,27 @@ |
||||
# Streamlink documentation preview config for pull requests via netlify.com |
||||
# Some settings like PR statuses for example can only be configured via the netlify website |
||||
|
||||
# https://docs.netlify.com/configure-builds/file-based-configuration/#build-settings |
||||
[build] |
||||
command = "pip install -U pip setuptools && pip install -e . && pip install -U -r docs-requirements.txt && make --directory=docs clean html" |
||||
publish = "docs/_build/html" |
||||
# Since production builds can't be disabled without disabling PRs as well, pushes to the master branch need to be ignored. |
||||
# Also ignore pull requests which don't include any changes that would alter the docs: |
||||
# - docs/ |
||||
# - docs-requirements.txt |
||||
# - src/streamlink_cli/argparser.py |
||||
# https://docs.netlify.com/configure-builds/file-based-configuration/#ignore-builds |
||||
ignore = "[ $(git rev-parse --abbrev-ref HEAD) = master ] || git diff --quiet master HEAD docs/ docs-requirements.txt src/streamlink_cli/argparser.py" |
||||
|
||||
[build.environment] |
||||
# Set the latest natively available Python version in the Ubuntu env (currently 16.04 / Xenial) |
||||
# https://docs.netlify.com/configure-builds/manage-dependencies/#python |
||||
# https://github.com/netlify/build-image/blob/xenial/included_software.md |
||||
PYTHON_VERSION = "3.7" |
||||
|
||||
# Builds on untagged commits are always "latest", but since it's built on the root docs dir, actual "latest" links will cause 404 errors |
||||
# https://docs.netlify.com/configure-builds/file-based-configuration/#redirects |
||||
[[redirects]] |
||||
from = "/latest/*" |
||||
to = "/:splat" |
||||
status = 301 |
Loading…
Reference in new issue