summary refs log tree commit diff
path: root/src/ci/scripts/install-tidy.sh
blob: fab126453fdc976d99e831029bcf3e91df0d33a1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/bin/bash
# This script downloads and installs the tidy binary from Homebrew.

set -euo pipefail
IFS=$'\n\t'

source "$(cd "$(dirname "$0")" && pwd)/../shared.sh"

# Only the macOS arm64/aarch64 GitHub Actions runner needs to have tidy
# installed; other platforms have it preinstalled.

if isMacOS; then
    platform=$(uname -m)
    case $platform in
        x86_64)
            ;;
        arm64)
            brew install tidy-html5
            ;;
        *)
            echo "unsupported architecture: ${platform}"
            exit 1
    esac
fi