Update various website source files for 5.19.1
[tails.git] / bin / check-core-pages
blobee4860bb4667de0f42cee691009aaa7c3ebce73f
1 #!/bin/bash
3 set -e
4 set -u
5 set -o pipefail
7 declare -A git_files=()
8 while read -r line; do
9 git_files["$line"]=1
10 done < <( git ls-files )
12 readarray -t core_po_files < <(cut -c 3- ./wiki/src/contribute/l10n_tricks/core_po_files.txt)
13 fail=false
15 for core_po_file in "${core_po_files[@]}"; do
16 mdwn="wiki/src/${core_po_file}.mdwn"
17 html="wiki/src/${core_po_file}.html"
18 if [ -z "${git_files[$mdwn]:=}" ] && [ -z "${git_files[$html]:=}" ]; then
19 echo "Error: missing page listed in core_po_files.txt: ${core_po_file}"
20 fail=true
22 done
24 [ "${fail}" = false ]