Skip to content

Commit

Permalink
[ci] install Linkchecker only for check-links job (#3893)
Browse files Browse the repository at this point in the history
* Update linkchecker.yml

* Update test.sh
  • Loading branch information
StrikerRUS authored Feb 2, 2021
1 parent 1c18ad3 commit 56fc036
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .ci/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ cd $BUILD_DIRECTORY
if [[ $TASK == "check-docs" ]] || [[ $TASK == "check-links" ]]; then
cd $BUILD_DIRECTORY/docs
conda install -q -y -n $CONDA_ENV -c conda-forge doxygen
pip install --user -r requirements.txt linkchecker rstcheck
pip install --user -r requirements.txt rstcheck
# check reStructuredText formatting
cd $BUILD_DIRECTORY/python-package
rstcheck --report warning `find . -type f -name "*.rst"` || exit -1
Expand All @@ -31,6 +31,7 @@ if [[ $TASK == "check-docs" ]] || [[ $TASK == "check-links" ]]; then
make html || exit -1
if [[ $TASK == "check-links" ]]; then
# check docs for broken links
pip install --user linkchecker
linkchecker --config=.linkcheckerrc ./_build/html/*.html || exit -1
exit 0
fi
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/linkchecker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Link checks
on:
# Run manually by clicking a button in the UI
workflow_dispatch:
# Run every 8 hours
# Run once a day at 8:00am UTC
schedule:
- cron: '0 8 * * *'

Expand Down

0 comments on commit 56fc036

Please sign in to comment.