#!/bin/bash
LINKCHECKER=/opt/link-scanner/venv/bin/linkchecker
SITE="devenia.com"

echo "=== Testing  ==="

# Broken links
echo "Checking broken links..."
OUTPUT=
BROKEN=0
echo "  Broken: "

# Sitemap
echo "Fetching sitemap..."
SITEMAP_URLS=
SITEMAP_COUNT=0
0
echo "  Pages in sitemap: "

# Linked URLs
echo "Crawling for internal links..."
LINKED_URLS=
LINKED_COUNT=0
0
echo "  Pages found via crawl: "

# Orphans
ORPHAN_COUNT=0
while IFS= read -r url; do
    if [ -n "" ] && ! echo "" | grep -qF ""; then
        if [[ "" != *"/wp-"* ]] && [[ "" != *"/feed"* ]] && [[ "" != *"/author/"* ]]; then
            ORPHAN_COUNT=1
        fi
    fi
done <<< ""
echo "  Orphaned pages: "
echo "Done!"
