Skip to content

Commit 6923173

Browse files
committed
Fix script for github action
1 parent 36fdb3e commit 6923173

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

check-links.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ echo "Checking internal links in markdown files..."
2020

2121
set +e
2222
#Using custom python script for internal link checking:
23-
"$VENV_BIN/python" "$PROJECT_ROOT/check-internal-links.py" "$DOCS_DIR"
23+
python "$PROJECT_ROOT/check-internal-links.py" "$DOCS_DIR"
2424
RESULT_INTERNAL=$?
2525

2626
set -e
@@ -33,8 +33,8 @@ fi
3333
echo "Internal linkcheck passed!"
3434

3535
# Check if linkchecker exists
36-
if [ ! -x "$VENV_BIN/linkchecker" ]; then
37-
echo "Error: linkchecker executable not found in $VENV_BIN"
36+
if ! command -v linkchecker >/dev/null 2>&1; then
37+
echo "Error: linkchecker executable not found in PATH"
3838
exit 1
3939
fi
4040

@@ -43,12 +43,12 @@ rm -rf "$TMP_BUILD_DIR"
4343

4444
# Build MkDocs into temporary directory
4545
echo "Building MkDocs locally into $TMP_BUILD_DIR..."
46-
"$VENV_BIN/python" -m mkdocs build -d "$TMP_BUILD_DIR"
46+
python -m mkdocs build -d "$TMP_BUILD_DIR"
4747

4848
echo "Running LinkChecker on external links against local build..."
4949
set +e
5050
# Only report broken links
51-
"$VENV_BIN/linkchecker" "file://$TMP_BUILD_DIR/index.html" \
51+
linkchecker "file://$TMP_BUILD_DIR/index.html" \
5252
--no-status \
5353
--check-extern \
5454
--recursion-level=2 \

0 commit comments

Comments
 (0)